Bruno_102975
Dec 23, 2008Nimbostratus
HTTP Redirect after LB_Select
Hello,
I need to do a HTTP Redirect of the client request to the 'elected' node of a set of pools.
The selection of the Pool based on the client source IP works fine
The selection in the pool and redirection work fine
The one after the other cannot work "LB_SELECTED is not valid in current event context"
Could you pls suggest another way to do it?...
when HTTP_REQUEST {
if { [IP::addr [IP::client_addr] equals 10.75.0.0/16 ] }
{ pool Pool_AutoconfUK
}
else
{ pool Pool_AutoconfEUA
}
}
when LB_SELECTED {
if {[LB::server addr] equals "10.64.21.157"} {
HTTP::redirect http://10.64.21.157
} else {
HTTP::redirect http://10.64.17.123
}
}
}