ltm rule command ROUTE expirationΒΆ

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

ROUTE::expiration
       Returns the remaining time for a route or congestion metrics cache entry.

SYNOPSIS
       ROUTE::expiration DESTINATION_IP_ADDRESS (GATEWAY_IP_ADDRESS)?

DESCRIPTION
       Returns the remaining time in seconds. The lifetime of an entry may have been set by the route.metrics.timeout
       sys db variable, the cmetrics-cache-timeout TCP profile attribute, or a TCP::rt_metrics_timeout iRule.

       The return value only applies to the TMM executing the command. It does not consider cache entries on other
       TMMs.

RETURN VALUE
VALID DURING
EXAMPLES
	when CLIENT_CLOSED {
	    # If the entry almost timed out, keep it a little longer next time.
	    set time_remaining [ROUTE::expiration [IP::remote_addr]]
	    if { $time_remaining > 0 && $time_remaining < 100 } {
		 # Default value is 600
		 TCP::rt_metrics_timeout 700
	    }
	}

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

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