Forum Discussion
Matt_Mueller_10
Nimbostratus
Dec 03, 2008.net app losing correct pool assignment
Hello everyone,
I have the following irule which is working perfectly on a couple of tomcat sites, but then for the .net application, it's being rerouted to the else destination pool. The initial page comes up fine for this .net app, which has a login button on it, however when the user clicks on the login button something with the URL in the background must be getting mixed up as they are then rerouted from that site to the default pool specified in the else statement at the end of this irule.
Here is the irule I'm using:
when HTTP_REQUEST {
Checks the URI and forces to all lowercase for the check first for tomcat1.domain.com
switch [string tolower [HTTP::host]] {
"tomcat1.domain.com" {
if { [HTTP::path] eq "/"}{
Matched tomcat1.domain.com with URI of /. Redirecting to http
HTTP::redirect "http://tomcat1.domain.com/virtualdir/"
return
} else {
Matched tomcat1.domain.com with URI not /. Using pool tomcat1pool"
pool tomcat1pool
return
}
}
"tomcat2.domain.com" {
if { [HTTP::path] eq "/"}{
Matched tomcat2.domain.com with URI of /. Redirecting to http
HTTP::redirect "http://tomcat2.domain.com/virtualdir/"
return
} else {
Matched tomcat2.domain.com with URI not /. Using pool tomcat2pool"
pool tomcat2pool
return
}
}
"dotnet.domain.com" {
if { [HTTP::path] eq "/"}{
Matched dotnet.domain.com with URI not /. Using pool dotnetpool"
pool dotnetpool
return
}
}
}
If we got here, no condition was matched, so use default pool of tomcat1
pool tomcat1pool
No match. Using default pool for tomcat1"
}
Is there something I should be doing differently with this irule, or what is a common way that someone in their .net app can code to accomodate this functionality? The programmer I was speaking with said that there is an application URL variable in visual studio that they can code for, would that accomodate this issue?
Thanks!
No RepliesBe the first to reply
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