ltm rule command FLOW idle durationΒΆ

iRule(1)					  BIG-IP TMSH Manual					     iRule(1)

FLOW::idle_duration
       Returns the time in seconds when the flow was last used.

SYNOPSIS
       FLOW::idle_duration ANY_CHARS

DESCRIPTION
       Returns the time in seconds when the flow was last used.

RETURN VALUE
       Returns the time in seconds when the flow was last used.

VALID DURING
       FLOW_INIT, CLIENT_ACCEPTED, SA_PICKED, LB_SELECTED, CLIENT_DATA, SERVER_DATA, SERVER_CONNECTED

EXAMPLES
	when SERVER_CONNECTED {
		if {[catch { FLOW::create_related {
				    proto 6
				    clientflow [IP::remote_addr] 1221 [LINK::vlan_id]
				    serverflow [clientside {IP::remote_addr}] 1221 [clientside {LINK::vlan_id}]
				} } result] } {
		    log local0. "Couldn't create the connection, error:$result"
		} else {
		    log local0. "Connection: $result TO [FLOW::peer $result]"
		}
		clientside {TCP::collect}
		TCP::collect
	    }

	    when CLIENT_DATA {
		# Log and refresh the related flow whenever the client sends data.
		log local0. "Flow idle duration before refresh [FLOW::idle_duration $result]"
		FLOW::refresh $result
		log local0. "Flow idle duration after refresh [FLOW::idle_duration $result]"
		TCP::release
		TCP::collect

	    }
	    when SERVER_DATA {
		# Log and refresh the related flow whenever the server sends data.
		log local0. "Flow idle duration before refresh [FLOW::idle_duration $result]"
		FLOW::refresh $result
		log local0. "Flow idle duration after refresh [FLOW::idle_duration $result]"
		TCP::release
		TCP::collect

	    }

HINTS
SEE ALSO
CHANGE LOG
       @BIGIP-14.1.0 --First introduced the command.

BIG-IP						      2020-06-23					     iRule(1)