0

Once an endpoint is invoked by Sprint/Tomcat, can that endpoint code determine its own URL template? Consider this verb and URL:

GET /my_resource/123/

The HTTP verb and 'template' looks something like this:

GET /my_resource/{id}/

I want to send a message to a rabbitMQ exchange, and I want the exchange to be deterministically derivable from the template. For example:

get|my_resource.id.

(I don't actually know if that's a valid queue. But you can see how I got there.) This allows me to make the endpoints very thin and removes an annoying dependency.

Tony Ennis
  • 12,000
  • 7
  • 52
  • 73

0 Answers0