Custom Load Balancing algorithm

Hi everyone,

I've the nive diagram with the different stages: router, service, middleware.

I understood that only middleware is exposed to the plugin api. Did I understood correctly or creating a plugin at service level is totally possible.

I want to create a custom load balancer, to redirect request according to query parameters(regexp won't work).
I've hacked a quick test with lua using HAP, but development effort will to big compared to golang.
Thanks in advance for your comments.

According to doc you can create middleware and provider plugin. I don’t think any plugin has influence on the service that follows in the chain (which service/URL).

You could try to hack the system by doing the request to target service within the middleware and then "return early", not delegating to service down the chain.

Thanks the pointer but I am not sure if this might be enough. Will try anyway.
Regards