Forum Discussion
darragh_19954
Nimbostratus
Nov 14, 2007Can global variables be used to carry information between events?
I'd like to use a global variable set up in the RULE_INIT event to carry some client-specific conditional information between the HTTP_REQUEST and HTTP_RESPONSE events. Is this possibe>
Here...
hoolio
Cirrostratus
Nov 14, 2007Global variables are accessible across all TCP connections and all events. Local variables are accessible across all events of a single TCP connection.
If don't want the values to be trampled by different connections/clients, you should only use a local variable. A local variable set in one event will be available for that connection across all other events. You can set the default value for a local variable when the TCP connection is established in the CLIENT_ACCEPTED event.
Aaron
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
