Axon using a proxy

Hi. A problem has arisen on the horizon: Imagine that part of the micro services is running on machine A and another part on machine B. The Axon server is running on machine B (or A, doesn’t matter).
Machines A and B have to communicate through a proxy!

How does one have to configure the micro services and Axon server to communicate through the proxy with the processes on the other machine and without proxy on the same machine?

Best regards,

Hi Erik,

that could be a challenge indeed. The connector receives a hostname from one of the nodes that it should connect to. That does mean that the machine needs to be addressable using that hostname from whichever application tries to connect to it.

We have a similar challenge in our Axon Cloud, where we use a specialized proxy to translate hostnames from internal to external once a connection is “beyond the loadbalancer”. Basically, it just acts as a proxy for the “GetPlatformServer” request (see Instead of returning the response as-is, it does a little hostname translation to make it suitable for interaction with the outside world.

Kind regards,

Hi Allard,

wouldn’t it be enough to configure http.proxyHost / http.proxyPort? As far as I understand Axon uses gRPC, and gRPC is based on standard Java.
So maybe using a customized ProxySelector could do the trick.
Or is my point of view too naive?

Kind regards,

Hi Erik,

according to the gRPC documentation, you should be able to use -Dhttps.proxyHost=HOST and -Dhttps.proxyPort=PORT to configure a proxy for connections.
All connections are initiated by clients. AxonServer will never attempt to connect to a client itself.