Target servers on custom port(on-prem)

Basic question(sometimes its good to ask).

We want to configure target servers on custom port (eg: server1 on port 5000 & server2 on port 5000) to route the traffic? Does it work only on 80 & 443?

I tested and see the traffic would go as port http- 80 and doesn't honor custom port configured at target servers.Am I missing something here?

This is on onprem instance.

Thanks.

0 4 116
4 REPLIES 4

@Vinay, can you share the trace and the Target server configuration

Created target servers using UI..

devserver1 dev-xx-xxxx.xxx.xxx.com 8080

devserver2 dev-yy-yyyy.yyy.yyy.com 8080

Created a sample pass thru proxy and when we test we see the request goes to only with the host and doesn't take port into account..

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ProxyEndpoint name="default">
<Description/>
<PreFlow name="PreFlow">
<Request/>
<Response/>
</PreFlow>
<Flows/>
<PostFlow name="PostFlow">
<Request/>
<Response/>
</PostFlow>
<HTTPProxyConnection>
<BasePath>/passthru</BasePath>
<VirtualHost>internal</VirtualHost>
</HTTPProxyConnection>
<RouteRule name="default">
<TargetEndpoint>default</TargetEndpoint>
</RouteRule>
</ProxyEndpoint> <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <TargetEndpoint name="default"> <FaultRules/> <HTTPTargetConnection> <LoadBalancer> <Server name="devserver1"/> <Server name="devserver2"/> </LoadBalancer> </HTTPTargetConnection> </TargetEndpoint>

sidd-harth
Participant V

Custom/Random port should work.

What error do you see, provide configs, screenshots if possible?

In some cases, you need to whitelist the Apigee IP range on your server side.

It's no error but port is not getting populated/considered when proxy calls the target servers.