skbartl_85400
Mar 26, 2008Nimbostratus
Determine URI after setting with HTTP::uri
I have an iRule that uses HTTP::uri to rewrite part of the original URI. For debugging purposes, I would like to write out the value of the new URI to the log. Below is the basic gist of my iRule:
------------------------------------------
log local.0 "URI before: [HTTP::uri]"
HTTP::uri $new_uri
log local.0 "URI after: [HTTP::uri]"
------------------------------------------
The log entries for before and after both have the original URI, not the new URI. Is there any way to get the value of the new URI after changing it with HTTP::uri (in the context of HTTP_REQUEST)? I did find a workaround with the following code, but I was hoping to find a more elegant solution.
------------------------------------------
when HTTP_REQUEST_SEND {
clientside { log local0. "New URI: [HTTP::uri]" }
}
------------------------------------------
Any ideas?
Thanks!
Steve