I am new to APISIX. Want to understand, is it feasible that I can create an API definition in APISIX, in which based on some param or different URL path, same API can route to different backend services?
I am currently using APIGEE, where I keep backend information in KVMs post extracting the mapping from our home grown service.
For instance, myapi.company.com/v1/people?tenantId=abc will redirect to backend serving abc tenantId whereas myapi.company.com/v1/people?tenantId=xyz will redirect to another backend serving xyz tenantId.
Does APISIX provide such mechanism where I can call another service to find this mapping at runtime (and cache it for consequent calls for same tenantId). And use this information to route the request to appropriate backend.
Thanks & Regards Amit
Seems possible using an advance Router config.
In Route API
uriparameter it says that:In the Router page, it says you can use
radixtree_uri_with_parameterfor URL with parameters.Here's how you can configure an advance Router. https://apisix.apache.org/docs/apisix/router-radixtree/#how-to-use-libradixtree-in-apisix#5-parameter-match