How to pass the Service Manager host and servlet port in the webtier URL

  • KM547732
  • 12-Feb-2009
  • 29-Sep-2015

Summary

By default, a Webtier client request is sent to the server (host) and port specified in the web.xml file. It is possible to specify a different server and port directly in the URL. This functionality is typically used when troubleshooting an issue or testing different configurations/servers.

Question

The webtier client request - by default - is sent to the Service Manager Server (host) and servlet port specified in the web.xml file. However, it is possible to specify a different server and port directly in the webtier URL. This allows the browser to access and 'login' to a different Service Manager Server instance. This functionality is typically used when troubleshooting or testing different configurations/servers.

Answer

In order for the Service Manager host and port parameters to be recognized, it is first necessary to change some parameters in the web.xml file.

1. Access the web.xml file for the deployed ServiceCenter WAR file
2. Locate the parameter named: sc.honorUrlHost
3. Set the associated parameter value to: true
4. Locate the parameter named: <param-name>honorUrlHost</param-name>
5. Set the associated parameter value to: true
6. Save changes to the web.xml file
7. Restart Application server(s) deploying the Webtier

To temporarily redirect the Webtier client connection, use the following syntax (examples shown below)

Original URL:
http://localhost/index.do

Redirected URL:
http://localhost/index.do?host=server_name&port=12345

where:
server_name represents the name of the ServiceCenter server
12345 represents a port used by a listener/servlet on the ServiceCenter server