Get a quote price the JAX-RS way

The endpoint we saw previously has been deployed on /<application_context>/api/quote/{quoteId} with the context of the web application, application_context. If you used the previous setup, it is, most likely, the artifact ID of the Maven project. Let's consider from now on that it is quote-manager.

Here is what it returns for one of the quotes:

$ curl -v http://localhost:9090/quote-manager/api/quote/8* Trying 127.0.0.1...* TCP_NODELAY set* Connected to localhost (127.0.0.1) port 9090 (#0)> GET /quote-manager/api/quote/8 HTTP/1.1> Host: localhost:9090> User-Agent: curl/7.52.1> Accept: */*> < HTTP/1.1 200 OK< Server: Undefined Product Name - define product and version info in config/branding 0.0.0 < X-Powered-By: ...

Get Java EE 8 High Performance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.