Forum Discussion
Al-Mutlaq_21911
Nimbostratus
Aug 26, 2015direct traffic based on information from the XML request
Dear All,
I need a solution on IRULE for example to solve the following scenario:
I have 10 servers that will receive XML requests. the unique ID in each XML request will be a number such ...
Kevin_Stewart
Employee
Aug 26, 2015If you can send an example of the XML request that'd help in building an actual iRule. Otherwise,
when HTTP_REQUEST {
some function to parse out the digits from the xml request
switch -glob $digit {
"*0" {
if { [LB::status node 10.10.10.1] eq "up" } {
node 10.10.10.1 80
} else {
node 10.10.10.2 80
}
}
"*1" {
if { [LB::status node 10.10.10.2] eq "up" } {
node 10.10.10.2 80
} else {
node 10.10.10.3 80
}
}
"*2" {
if { [LB::status node 10.10.10.3] eq "up" } {
node 10.10.10.3 80
} else {
node 10.10.10.4 80
}
}
default {
send to a default pool or node
}
}
}
Of course this doesn't deal with any type of persistence and what happens if the failover node is also down.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
