The example file proxyrules_example1.xml file routes requests based on the hostname specified in the request. The example file proxyrules_example10.xml file also routes SPS requests based on the hostname specified in the request, SPS uses the PID in the proxy rule to count of the number of times the proxy rule has been triggered. If you configured CA Wily Introscope to monitor SPS, the count is displayed in CA Wily Introscope data metrics.
In this file, a simple set of proxy rules routes user requests based on the virtual host specified in the requested resource. All requests to the bondtrading.company.com server are forwarded to server2, all requests to banking.company.com are forwarded to server1, and all other requests are forwarded to the companies home server, which is the default for requests that do not match the criteria in any other nete:cond element.
Note: The nete:case elements must specify a port, since the port number is considered as part of the virtual host requested by the user. Use the beginswith criteria to avoid needing port numbers.
The following table illustrates the results of requests using the proxy rules based on virtual hosts.
|
Requested URL |
Forwarded URL |
|---|---|
|
http://banking.company.com/index.html |
http://server1.company.com/index.html |
|
http://bondtrading.company.com/index.html |
http://server2.company.com/index.html |
|
http://www.company.com/index.html |
http://home.company.com/index.html |
| Copyright © 2012 CA. All rights reserved. |
|