juaby opened a new issue, #10398:
URL: https://github.com/apache/apisix/issues/10398

   ### Description
   
   upstream configuration item service_name, how to support dynamic fetching 
instead of fixed. For example, parsing from the tcp private protocol, or 
through http headers, or through http parameters
   $ curl http://127.0.0.1:9180/apisix/admin/routes/1 -H 'X-API-KEY: 
edd1c9f034335f136f87ad84b625c8f1' -X PUT -i -d '
   {
       "uri": "/a/*",
       "plugins": {
           "proxy-rewrite" : {
               "regex_uri": ["^/a/(.*)", "/${1}"]
           }
       },
       "upstream": {
           "service_name": "A-SERVICE",
           "type": "roundrobin",
           "discovery_type": "eureka"
       }
   }'
   
   $ curl http://127.0.0.1:9180/apisix/admin/routes/2 -H 'X-API-KEY: 
edd1c9f034335f136f87ad84b625c8f1' -X PUT -i -d '
   {
       "uri": "/b/*",
       "plugins": {
           "proxy-rewrite" : {
               "regex_uri": ["^/b/(.*)", "/${1}"]
           }
       },
       "upstream": {
           "service_name": "B-SERVICE",
           "type": "roundrobin",
           "discovery_type": "eureka"
       }
   }'
   
   ### Environment
   
   - APISIX version (run `apisix version`):360
   - Operating system (run `uname -a`):macos
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl 
http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to