Does HTTP stub server stubby4j support request proxying with additional query params setting?

163 Views Asked by At

TL;DR:

Does stubby4j request proxying functionality support the setting of additional query params with the request which is being proxied?

Details:

I am using stubby4j HTTP stub server, the latest version (i.e.: v7.3.3) to proxy requests to another real live service when my request did not match any of the configured stubs.

I am interested to know if it is possible to pass in additional query params to the live service with the request which is being proxied?

In the official docs of the stubby4j request proxying behavior (https://stubby4j.com/docs/request_proxying.html) there is nothing mentioned about it and from what I see in my own testing, I do not think this is supported. But, I still wanted to ask on SO to check if I am simply doing something wrong.

1

There are 1 best solutions below

0
On

You are correct, the the setting of additional query params on the request being proxied is not supported currently.

As per the aforementioned docs, the additive strategy only supports the setting of additional HTTP headers, which are specified in the headers property on the proxy-config object in your YAML.

But, it is pretty straightforward to add the addition of query params behavior. Feel free to raise a feature request at https://github.com/azagniotov/stubby4j/issues/new/choose