ILXStream¶
new ILXStream()
- Since:
- BIP-IP TMOS 13.0
An ILXStream is an extended instance of the net.Socket object. A client and server stream are created for each ` <ILXFlow.html>`__
ILXFlow
. All data that goes through the socket goes through the Big IP TMM and not the Linux TCP stack. A plugin may also use ` <#connect>`__
ILXStream.connect()
to initiate outbound connections that go directly through the TMM.
Properties:
Name | Type | Description |
---|---|---|
remoteAddress
|
string | Is client address on clientside stream. Is server destination address on serverside stream. |
remotePort
|
number | Is client source port on clientside. Is server destination port on serverside. |
remoteFamily
|
string | IPV4 or IPV6 on respective stream. |
localAddress
|
string | Is VS address on clientside. Is source address on severside. |
localPort
|
number | Is VS port on clientside. Is source port on serverside. |
Example:
plugin.on('connect', function(flow) {
// Received HTTP request headers from client
flow.client.on('requestStart', function(request) {
request.setHeader('X-F5-ILX', 'Success');
});
});
Methods¶
allow()¶
(ILXFlow.client object only) Allows the client connection to proceed to the server. ` <ILXPluginOptions.html>`__
ILXPluginOptions.handleClientOpen
must be set to
true
and no data may have been sent to the server before ILXStream.allow is called.
connect(options)¶
Establish a TCP connection to the specified host or Virtual Server. A host or virtualServer must be specified, but not both.
Note: This method overides the default
net.Socket.connect
method and does not do DNS lookups of the hostname.
Parameters:¶
Name | Type | Description | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options
|
object | Propertie
1
|
setTraceLevel(level)¶
Parameters:¶
Name | Type | Description |
---|---|---|
level
|
number | See ` <ILXPlugin.html#~tr aceLevel>`__ ILXPlugin~traceLev
el |
Events¶
connect¶
(ILXFlow.server object only) The
connect
event is emitted when the connection to the server is established. Note: Because some of the parameters are unique to F5 the ILXStream.connect signature does not match the Node.js net.Socket connect signature.
error¶
Parameters:¶
Name | Type | Description |
---|---|---|
errorText
|
string | Description of the error |
requestComplete¶
Parameters:¶
Name | Type | Description |
---|---|---|
request
|
ILXTransaction | ILXTransaction instance object |
Listeners of This Event:¶
requestStart¶
Parameters:¶
Name | Type | Description |
---|---|---|
request
|
ILXTransaction | ILXTransaction instance object |
Listeners of This Event:¶
responseComplete¶
Parameters:¶
Name | Type | Description |
---|---|---|
response
|
ILXTransaction | ILXTransaction instance object |
Listeners of This Event:¶
responseStart¶
Parameters:¶
Name | Type | Description |
---|---|---|
response
|
ILXTransaction | ILXTransaction instance object |
Listeners of This Event:¶
The BIG-IP API Reference documentation contains community-contributed content. F5 does not monitor or control community code contributions. We make no guarantees or warranties regarding the available code, and it may contain errors, defects, bugs, inaccuracies, or security vulnerabilities. Your access to and use of any code available in the BIG-IP API reference guides is solely at your own risk.