-
Notifications
You must be signed in to change notification settings - Fork 13
API Gateway Configuration
This guideline present how to configure the CROSSMINER Gateway in order to integrate a new remote REST API.
The CROSSMINER Gateway can be configured by the intermediary of an external property file (application.properties) to place in the execution directory of the CROSSMINER Gateway component. This file allow to configure the routing of requests send to the gateway an some security parameters.
To reference a new remote REST API in the gateway, you have to add 2 new properties in the application.properties configuration file : the relative path of services which will be integrated to this route and the redirection URL.All requests sent to the gateway which start by this relatice path will be redirected to the output url after the authentication process.
Examples :
- api gateway url = http://85.36.10.13:8080
- path = /administration/**
- url = http://85.36.10.12:8082/administration
The request http://85.36.10.13:8080/administration/project/create will be redirected to http://85.36.10.12:8082/administration/project/create
id : zuul.routes.**servicename**.path | default : NA | |
Relative path of the incoming service which will be redirected. Example : /test1/** |
id : zuul.routes.**servicename**.url | default : NA | |
Redirection URL of the route. Example : http://127.0.0.1:8082/test1 |
# Rooting Configuration : Test1 Service
zuul.routes.test1.path=/test1/**
zuul.routes.test1.url=http://127.0.0.1:8082/test1
# Rooting Configuration : Test2 Service
zuul.routes.test2.path=/test2/**
zuul.routes.test2.url=http://127.0.0.1:8083/test2
More information about API Gateway configuration : API Gateway Component