Help on irule for V11

Iam migrating a service from v9 to v11, while migrating I getting a error on irule. I suspect some syntax mismatch when I copy a irule from v9 to v11. Kindly advice

below is the irule what I used. I have used xxxx to hide information.

when HTTP_REQUEST { if {[string tolower [HTTP::uri]] contains “/advantage” } { pool XXXX_http-pool } elseif {[matchclass [string tolower [HTTP::uri]] starts_with $::XXXXX_uri] } { pool qa-pool } elseif { [HTTP::host] equals “XXXXXX.com” } { HTTP::redirect “” } else { pool XXXXX1_http-pool } }

matchclass

was deprecated some versions ago. Use

class match

instead.

In addition, instead of

$::abc

you should now use

abc

.

Documentation: https://devcentral.f5.com/wiki/iRules.class.ashx

Thank you for your response, it tried, but not working do we need to use like this “abc” instead of abc.

any other changes required on irule?

Thank you, this is working

Would you mind marking the entry as the answer?