https://github.com/lreimer/packtpub-building-javaee8-webservices-section.6
Building Webservices with Java EE 8 - Packt Publishing Video Course Section 6
https://github.com/lreimer/packtpub-building-javaee8-webservices-section.6
javaee8 microservice packt packtpub payara payara-micro webservice
Last synced: 3 months ago
JSON representation
Building Webservices with Java EE 8 - Packt Publishing Video Course Section 6
- Host: GitHub
- URL: https://github.com/lreimer/packtpub-building-javaee8-webservices-section.6
- Owner: lreimer
- License: mit
- Created: 2018-03-29T19:55:03.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-03-29T21:37:23.000Z (over 7 years ago)
- Last Synced: 2025-05-26T20:52:54.486Z (7 months ago)
- Topics: javaee8, microservice, packt, packtpub, payara, payara-micro, webservice
- Language: Java
- Homepage: https://www.packtpub.com/application-development/building-web-services-java-ee-8-video
- Size: 67.4 KB
- Stars: 1
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Building Web Services with Java EE 8
Section 6: Advanced REST APIs
## Videos
### Video 6.1: Apply Design by Contract: Adding validation.
In this video we are implementing validation for the inputs of a REST resource.
| Method | URI | Status | Description |
|---------|-----|--------|-------------|
| GET | /api/validation/books | 200 | List of books |
| GET | /api/validation/books/{ISBN} | 200 or 400 | A book by ISBN or invalid request |
| POST | /api/validation/books | 201 or 400 | Create a book new book or invalid request|
### Video 6.2: Using JSON Web Token (JWT) for Authentication
In this video we are implementing a JWT based authentication for a REST resource.
| Method | URI | Status | Description |
|---------|-----|--------|-------------|
| GET | /api/jwt/authentication | 200 or 401 | Get authentication details or unauthorized response |
### Video 6.3: Diagnosability: Logging, Tracing and Metrics
In this video is showing how to subscribe and broadcast SSE events to all registered clients.
| Method | URI | Status | Description |
|--------|-----|--------|-------------|
| GET | /metrics | 200 | Get the current metrics registry as JSON |
| POST | /api/metrics/timed | 204 | Do a timed POST request, will be recorded in the metrics registry |
| POST | /api/metrics/counted | 204 | Do a counted POST request, will be recorded in the metrics registry |
| GET | /health | 200 | Perform a healtcheck and return response |
## Building and Running
```bash
$ mvn clean verify
$ docker build -t advanced-service:1.0 .
$ docker run -it -p 8080:8080 advanced-service:1.0
```