Forum Discussion
17 Replies
Sort By
- adrian_1812Nimbostratusanyone know if you can use standard tcl geturl?
- JRahmAdminI don't think so... I get an undefined procedure on that one when checking syntax. The url can be constructed, however, with HTTP::host and HTTP::uri.
- JRahmAdminThe iRules are event driven, so when a request/response arrives, do this... HTTP::host and HTTP::uri will give you the information from within a request, but I'm not sure what you are looking to do is possible within the context of iRules.
- JRahmAdminYou could build a class up front for each country and put as grand a summarization of those spaces as possible, or you could sub-optimally route the first request from each range, log any new range request, which could kick off an event to an iControl app that can build the class for you for future requests from that range.
- adrian_1812Nimbostratusthe tables for a country would be huge!!
- JRahmAdminYes. In fact, if you sent the initial request to server X, you could have it check the country and forward it back in the response, then you could resend the request to the appropriate pool.
- adrian_1812NimbostratusHi
- Deb_Allen_18Historic F5 AccountHi Adrian --
when HTTP_REQUEST { save original request set req [HTTP::request] flag as new request needing lookup set lookup 1 inject lookup URI in place of original request HTTP::uri "/page.aspx?ip=[IP::client_addr]" set pool to lookup server pool pool lookup_server } when HTTP_RESPONSE { if {$lookup == 1 }{ collect first response (from lookup server) only HTTP::collect } } when HTTP_RESPONSE_DATA { Get poolname from server response Response would ideally be in the form of a pool name only. Otherwise parse or derive the poolname here set myPool [HTTP::payload] verify pool exists and has members if { ![catch [pool $myPool]] }{ HTTP::retry $req } else { insert dead/non-existent pool logic here } re-set flag so that subsequent response to re-tried request from real server is not processed as a lookup set lookup 0 }
- Jon_Strabala_46NimbostratusI would like to get this example to work, but all my requests go
- hooleylistCirrostratusHi Jon,