Forum Discussion
Brian_Herr_1028
Nimbostratus
Nov 20, 2009Manipulate a HTTP:path then continue to parse iRule
We are trying modify an existing iRule where we currently rewrite the HTTP:path to a new one. We would like to do the rewrite and then continue to evaluate the rest of the iRule with the new path. My understanding is that once the path is rewritten it would stop executing the iRule as it has matched a condition. My current idea is to have another iRule that would execute in the same event but with a higher priority to change the path first. The eval the current iRule as is with the new path set. If anyone can shed some light on a way to do it within one iRule it would be appreciated.
- hoolio
Cirrostratus
For the most part, multiple iRules on the same VIP are all executed regardless of what happens in previous ones. The obvious exceptions to this I can think of are HTTP_RESPONSE not running if the request is responded to in HTTP_REQUEST or if you explicitly disable events using 'event disable'.This demonstrates the caching of the HTTP::path value when HTTP_REQUEST { log local0. "(priority 500) Current \[HTTP::path\] value [HTTP::path]" HTTP::path "/new_path" log local0. "(priority 500) Current \[HTTP::path\] value [HTTP::path]" } when HTTP_REQUEST priority 501 { log local0. "(priority 501) Current \[HTTP::path\] value [HTTP::path]" }
when HTTP_REQUEST { set path [HTTP::path] log local0. "Current \$path value $path" set path "/new_path" HTTP::path $path log local0. "Current \$path value $path" }
- The_Bhattman
Nimbostratus
Hi Brian,
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