Os_tcp::dst, Return values, Example – Brocade Virtual ADX OpenScript API Guide (Supporting ADX v03.1.00) User Manual
Page 30: Description, Context, Usage, Input parameters
Advertising
18
Brocade Virtual ADX OpenScript API Guide
53-1003243-01
Methods
3
Return Values
The following table contains the return values.
Example
OS_TCP::dst
Description
Returns the destination port number of the current packet.
Context
Called in context of TCP and HTTP.
Usage
Can be used to perform load-balancing based on destination port number.
Input Parameters
None.
Return Values
The following table contains the return values.
TABLE 11
Return Values
Name
Type
Description
Source
port
number.
TABLE 12
Return Values
Name
Type
Description
Destination
port
number.
use OS_TCP;
use OS_SLB;
use OS_HTTP_REQUEST;
sub HTTP_REQUEST{
$port = OS_TCP::src;
if($port == 1000){
OS_SLB::reset_client;
} else {
OS_SLB::forward(4);
}
}
Advertising