Forum Discussion
Luke_56105
Nimbostratus
May 21, 2010pool set in irule overidden by httpclass
Hello,
I am try in catch a particular uri and send it to a pool via irule:
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/myurl/" } {
pool mypool
}
}
However a later httpclass is catching /* and sending it to a different pool.
I am finding that the pool set in the irule is ignored and the request gets sent to the pool in my catchall httpclass.
Is there a way I can make my irule send the request direct to the pool and stop processing of the following irules and httpclasses?
Cheers,
Luke
- Michael_Yates
Nimbostratus
My initial thought was to use the Return command, but that won't work. - spark_86682Historic F5 AccountYou could use the HTTP::class disable command to prevent HTTP class matching from happening, and event disable to prevent any further iRules from firing; you could also specify the HTTP_REQUEST event with that last command to prevent only that event from proceeding further. Note that both of those commands operate on a per-connection basis, not per-request. If you wanted the next HTTP request on the same connection to be treated normally, then you'd need to reenable both of those later in the transaction, perhaps in HTTP_RESPONSE.
- hoolio
Cirrostratus
You could also override the pool selection done by an HTTP class if you set the pool in the HTTP_CLASS_SELECTED event. - Colin_Walker_12Historic F5 AccountThe problem he's running into though is that the class IS catching the URL and forwarding incorrectly. I think spark's idea of shutting off class matching for this request and then re-enabling as necessary is the best approach.
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