Forum Discussion
Therap_Ops_1222
Nimbostratus
May 04, 2015iRule for pool selection based on HTTP::URI
Hello
We have 2 pools with different sets of application servers. Pool_1 contains few WebLogic servers and Pool_2 contains few Tomcat servers. We want to redirect clients to specific pool based on...
Therap_Ops_1222
Nimbostratus
May 05, 2015Hi
Turned out there isn't an easy way to configure SSL offloading for Tomcat or at least I don't know any. So I updated the iRule as follows.
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/foo" } {
pool foo
} else {
pool bar
}
}
when HTTP_RESPONSE {
if { [HTTP::status] contains "302" && [HTTP::header Location] contains "http://" && [HTTP::header Location] contains "/foo" }{
HTTP::header replace Location [string map -nocase {"http://" "https://"} [HTTP::header Location]]
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects