Forum Discussion
Scenarios where Service Policy should be used over iRule and Vice versa
can anyone help me with some examples where service policy should be used instead of using an iRule and vice versa but remember example should be where requirement can be acheived using both service policy and irule but wanted to know where service policy is best fit over irule and example where iRule is best fit over service policy
8 Replies
- Injeyan_Kostas
Cirrostratus
This largely comes down to what you're used to.
Some people prefer using Policies for straightforward logic, turning to iRules only when more complex behavior is required.
Others, however, will use iRules regardless of the situation.Policies are generally easier to configure and maintain, especially for those with less experience—which can be a key factor in long-term maintainability.
On the other hand, iRules offer nearly limitless flexibility, making them ideal for advanced use cases. - Meer
Cirrus
Got it but if we have configured multiple service policy rules which one takes precedence. In irules lower priority takes precedence but I want to know the execution order of service policies
- Injeyan_Kostas
Cirrostratus
If you have both Policy and iRule, Policy comes first.
If you have multiple policies with confilcting controls you will not be able even to apply them
check https://my.f5.com/manage/s/article/K55864758#ai-recommendations-42- Meer
Cirrus
Perfect thanks
- Meer
Cirrus
Injeyan one more question can you please assist with the request evaluation process how does big ip enforce its security modules when a request comes to it if both ltm and asm all modules are implemented i mean complete security check like Distributed Cloud has mentioned in the attached snapshot
- Injeyan_Kostas
Cirrostratus
There is a great article explaining what you are asking, have a look
Knowledge sharing: An example of the general order of precedence for the BIG-IP modules. Also, the F5 ASM DDOS Protection or Bot Protection order of precedence explained. | DevCentral- Meer
Cirrus
thanks for your prompt response
Appreciated 😍
- Meer
Cirrus
It is written ASM DDoS is going to be executed first then Bot Defense and after that ASM Policy.
With respect to LTM and ASM like we have service polices, irules etc etcIs it the order would be like ASM DDos > Bot Defense > Service Policies > Irule (if configured) > then rest of the settings configured at layer 7 security in ASM
Recent Discussions
Related Content
* 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