Request mapping takes an inbound request into the gateway and maps it to the microservice that can handle that request. Mapping should take place as follows:
- Inbound URL: http://localhost:8080/api/gateway/microservice/items
- Mapping removes the /api/gateway/ string
- microservice is the name of the client microservice that can handle the request
- The host and port of the registered microservice is used and the remainder of the URL is passed to the microservice, so the URL becomes http://host:port/items
- The request is sent to the microservice
- The response is then sent back to the client through the gateway
Interception should take place before and after mapping
Request mapping takes an inbound request into the gateway and maps it to the microservice that can handle that request. Mapping should take place as follows:
Interception should take place before and after mapping