ltm rule command ADAPT context currentΒΆ

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



ADAPT::context_current
       Gets the current context.

SYNOPSIS
       ADAPT::context_current

DESCRIPTION
       Obtains a handle for the current context. The current context is
       usually that in which the event occurred from which this command was
       issued.

       Syntax:

       ADAPT::context_current

RETURN VALUE
       Returns the handle of the current context.

VALID DURING
       HTTP_REQUEST, HTTP_RESPONSE, HTTP_PROXY_REQUEST, ADAPT_REQUEST_RESULT,
       ADAPT_RESPONSE_RESULT

EXAMPLES
	when ADAPT_REQUEST_RESULT {
	    set ctx [ADAPT::context_current]
	    if {$ctx == $req_ctx2 && $need_another_ctx} {
		set req_ctx3 [ADAPT::context_create my_req_ctx3]
		ADAPT::select $req_ctx3 ivs-icap-req3
	    }
	}

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



BIG-IP				  2017-01-31			      iRule(1)