Forum Discussion
What to do after HTTP::respond ?
Connection Close header instructs customer's browser to close the old TCP connection. It's much more kosher than just bluntly doing TCP::close which will only tear down the connection in BigIP, but not in customer's browser. Also note that you will never need to use TCP::close and Connection Close in the same conditional routine. The return function has no functional value in your use-cases, but it does no harm to keep it for readability (some admins might prefer). The event disable all function can be safely replaced by just event disable.
I've adjusted one of your conditional routines. That's how you can provide the same functions while using less lines of code.
if { [HTTP::uri] eq "/bip-company-logo.gif" }{
HTTP::respond 200 content [ifile get "company-logo"] noserver Content-Type image/gif Connection Close
event disable
}
No, you don't need to use return to stop iRule processing. It serves no use.
'event disable' stops processing of the event (HTTP_REQUEST) in this, and all other iRules attached to VS. Unlike with 'event disable all', it does not stop processing of other events in this, or any other iRule.
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