Hille_de_Graaf_
Mar 25, 2008Nimbostratus
Simplify iRule
I have an iRule which would look at the content of the HTTP-header and loadbalance on behalve of that content.
Is there a more efficient way to build an iRule with the same results as the example below?
when HTTP_REQUEST {
if { [HTTP::uri] ends_with "ACCBPMv1" } {
pool xml-fw
} elseif { [HTTP::uri] ends_with "ACCTVIv1" } {
pool xml-fw
} elseif { [HTTP::uri] ends_with "ACCDVSv1" } {
pool xml-fw
} elseif { [HTTP::uri] ends_with "BPMv1" } {
pool xml-fw
} elseif { [HTTP::uri] ends_with "TVIv1" } {
pool xml-fw
} elseif { [HTTP::uri] ends_with "DVSv1" } {
pool xml-fw
} else {
pool ws-accxml
}
}
Regards,
Hille