Forum Discussion
Robert_47833
Jul 09, 2011Altostratus
difference between set ::domain ".cjj.com" and $::domain
Hi,all
I am confused by global variable
see below
set :: domain "cjj.com"
set $::domain "cjj.com"
set static::domain "cjj.com"
I am confused by the type of global variabl...
hooleylist
Jul 11, 2011Cirrostratus
Any variable set in RULE_INIT will be global in scope. So 'set ::domain "cjj.com"' and 'set domain "cjj.com"' if run in RULE_INIT will be equivalent. Both will demote the VS from CMP.
As Colin suggested, for variables which don't need to be changed over the course of a connection, you can use the static:: namespace. This gives you a variable which is global in scope but preserves CMP compatibility. You can get more info on CMP here:
http://devcentral.f5.com/wiki/default.aspx/iRules/CMPCompatibility.html
http://devcentral.f5.com/wiki/default.aspx/iRules/static
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