This chapter covers:
- the construction of a edge-service and a public API,
- the Vert.x web client,
- JSON web tokens and cross-origin resource sharing,
- serving and integrating a Vue.js reactive application with Vert.x,
- testing an HTTP API with REST Assured.
The Vert.x web stack provides many tools to build web application backends. This includes advanced routing, authentication, a HTTP client, and more. This chapter will guide you through exposing a HTTP API with JSON web tokens (JWT) for access control, making HTTP requests to other services, and building a reactive single-page application that connects to the HTTP API.
Note
This book does not cover the following noteworthy elements from the Vert.x web stack that are not needed to build the application in part 2: routing with regular expressions, cookies, server-side sessions, server-side template rendering and cross-site request forgery protection. You can get more details in the official documentation at vertx.io/.
Let us start with a reminder of what the public API service does, as illustrated in figure 8.1.