Technical data
Brocade ServerIron ADX Advanced Server Load Balancing Guide 91
53-1003441-01
Cache persistence using URL hashing
2
Parsing the entire URL
Parsing the entire URL string allows you to select a portion of a URL to perform hashing on. The URL
is searched to find a pattern string. This pattern string is combined with a configured offset value to
identify a starting point. From this starting point in the URL, a string that will be used for hashing is
derived by a method that is specified by the options you select for the hash-persist url search-url
command. These options are described in the following.
Parsing using the “pattern string” only – With this option, the ServerIron ADX begins at the starting
point in the URL and includes all of the characters up-to the end of the URL to form the string used
for hashing.
Search URL string by starting at a “pattern string” and ending at a delimiter – With this option, the
ServerIron ADX begins at the starting point in the URL and includes all of the characters up-to a
specified delimiter character in the URL to form the string used for hashing.
Search URL string by starting at a “pattern string” and continuing for a specified length – With this
option, the ServerIron ADX begins at the starting point in the URL and includes the number of
characters specified to form the string used for hashing.
Parsing using the “pattern string” only
The following example identifies a pattern string to perform hashing on with an offset of “0”.
NOTE
Because hash-persist action is a secondary action, you must add a forward action as shown in the
following example, before adding a hash-persist action.
ServerIronADX(config)#csw-policy p1
ServerIronADX(config-csw-p1)#match r1 forward 1
ServerIronADX(config-csw-p1)#match r1 hash-persist url search-url “v=” offset 0
Syntax: [no] hash-persist url search-url pattern-string offset offset-value
The contents of the pattern-string variable are used to define the starting place on the URL string. If
the URL string has multiple such pattern strings, only the first one will be used. If the pattern string
is not found, the system will abort the rest of the searching steps, and choose the default hashing
method. If the pattern string is found, the system will start the second step after skipping the
length of the pattern string. The second step in the process is to adjust the starting place on the
URL string by moving it by the number of characters defined by a value specified in the offset-value
variable. If the pattern string is empty, the system will not search the pattern part, and use the
beginning of URL string as the start point of the third step.
The offset-value variable is used to define how many characters will be skipped after the start point
that is defined by the pattern-string. Normally this value is 0 (zero) which places the start point
directly after the pattern string. A negative value can be used to move the starting place to the left
in the URL string. If the offset-value is greater than the length of the rest of the URL string, the
system will abort the rest of the searching steps, and start the next search (if configured). If
another search isn’t configured, the default hashing method is used. If the value of the offset-value
variable is within the length of the rest of the URL string, the system will skip to the offset place,
and start the third step.
With this command, the third step is for the system to look to the end of the URL to define the string
used for hashing.










