HTTP:persist(cal_server_from_hash)
Calculates the real server from the hash.
Syntax
HTTP:persist(t);
Arguments
| Name | Description |
|---|---|
|
t |
A table specifies the operation and hash value. |
Events
Applicable in the following events:
-
PERSISTENCE
-
HTTP_REQUEST (supported since version 7.2.x)
Example
when PERSISTENCE{
debug("-----cal_server_from_hash-----\n")
t={}
t["operation"] = "cal_server_from_hash"
t["hash_value"] = "246810"
ret = HTTP:persist(t)
if ret then
debug("hash 246810, server %s\n",ret)
end
}
Output:
Return the real server name according to the hash value using our algorithm or False if failed
Supported Version
FortiADC version 5.4.x and later. In 7.2.x, function extended to HTTP_REQUEST events.