ADAPT

Description

iRules commands and events for working with content adaption. The ADAPT events can take any ADAPT, HTTP, SSL, or TCP commands, except:
  • The ADAPT commands (except ADAPT::result) can be used only in HTTP_REQUEST and HTTP_RESPONSE events.
  • The ADAPT::result command can only be used in ADAPT* events.

Note: iRules for Dynamic Contexts - Added in v12 Dynamic contexts allow multiple content adaptations to be chained in sequence, and for the chain to be dynamically constructed (a new context added based on the result of a previous adaptation). There are some restrictions. Each context contains most of the profile configuration options which can be set dynamically for that context. All dynamic contexts inherit from the static context which is configured by the profile, so the profile provides the defaults, and iRules can modify individual contexts from there. Whenever a dynamic context exists on a side of virtual server, the static context is never executed and serves only as a template for initial configuration of new dynamic contexts. Existing ADAPT iRules have a new optional context-handle argument (if omitted, the commands operate the same as before). The argument is an opaque handle returned by the new ADAPT::context_create command, and intended to be stored in a variable and used with commands that are to operate on that context.

Commands


Events

  • ADAPT_REQUEST_HEADERS - raised as soon as any HTTP request headers have been returned from the IVS
  • ADAPT_REQUEST_RESULT - raised after the internal virtual server returns the result of the request modification but before the potentially modified request or the original request is passed on for other processing.
  • ADAPT_RESPONSE_HEADERS - raised as soon as any HTTP response headers have been returned from the IVS
  • ADAPT_RESPONSE_RESULT - raised after the internal virtual server returns the result of the response modification but before the potentially modified response or the original response is passed on for other processing.

Solutions

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.