AnsweredAssumed Answered

PI Web API Layer 7 Load Balancing Issue

Question asked by nix87 on Mar 7, 2019
Latest reply on Apr 23, 2019 by nix87

Hi,

 

I am trying to configure an Azure Application Gateway layer 7 load balancer between two PI Web API instances.

 

When making the request through the load balancer, the links returned in the request are pointing to the internal server IPs.

 

 

This makes sense when looking at the request received on the PWA servers:

 

GET /piwebapi/

Upgrade-Insecure-Requests: 1

X-FORWARDED-PROTO: https

X-FORWARDED-PORT: 8443

X-ORIGINAL-HOST: loadbalancer.fqdn.com:8881

X-Original-URL: /piwebapi/

X-Forwarded-For: myip:57449

X-ARR-SSL: ssl cert info

Cache-Control: max-age=0

Connection: Keep-Alive

Accept: text/html, application/xhtml+xml, application/xml; q=0.9, image/webp, image/apng, */*; q=0.8

Accept-Encoding: gzip, deflate, br

Accept-Language: en-US, en; q=0.9

Authorization: Negotiate [Redacted]

Host: 10.1.26.36

Max-Forwards: 10

User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36

 

Is it possible to override this behavior by having PWA return relative link URLs? Is it possible to specify the hostname PWA uses to generate the URLs?

 

Thanks,

Nick

Outcomes