slb template http¶
HTTP
http Specification¶
Type Collection Object Key(s) name Collection Name http-list Collection URI /axapi/v3/slb/template/http Element Name http Element URI /axapi/v3/slb/template/http/{name} Element Attributes http_attributes Schema http schema
Operations Allowed:
Operation | Method | URI | Payload | |
---|---|---|---|---|
Create Object | POST | /axapi/v3/slb/template/http | ||
Create List | POST | /axapi/v3/slb/template/http | ||
Get Object | GET | /axapi/v3/slb/template/http/{name} | ||
Get List | GET | /axapi/v3/slb/template/http | ||
Modify Object | POST | /axapi/v3/slb/template/http/{name} | ||
Replace Object | PUT | /axapi/v3/slb/template/http/{name} | ||
Replace List | PUT | /axapi/v3/slb/template/http | ||
Delete Object | DELETE | /axapi/v3/slb/template/http/{name} |
http-list¶
http-list is JSON List of http attributes
http-list : [
]
http attributes¶
100-cont-wait-for-req-complete
Description When REQ has Expect 100 and response is not 100, then wait for whole request to be sent
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
bypass-sg
Description Select service group for non-http traffic (Service Group Name)
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
Reference Object: /axapi/v3/slb/service-group
client-ip-hdr-replace
Description Replace the existing header
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
client-port-hdr-replace
Description Replace the existing header
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
compression-auto-disable-on-high-cpu
Description Auto-disable software compression on high cpu usage (Disable compression if cpu usage is above threshold. Default is off.)
Type: number
Range: 1-100
compression-content-type
Type: Listcompression-enable
Description Enable Compression
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
compression-exclude-content-type
Type: Listcompression-exclude-uri
Type: Listcompression-keep-accept-encoding
Description Keep accept encoding
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
compression-keep-accept-encoding-enable
Description Enable Server Accept Encoding
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
compression-level
Description compression level, default 1 (compression level value, default is 1)
Type: number
Range: 1-9
Default: 1
compression-minimum-content-length
Description Minimum Content Length (Minimum content length for compression in bytes. Default is 120.)
Type: number
Range: 1-2147483647
Default: 120
cookie-format
Description ‘rfc6265’: Follow rfc6265;
Type: string
Supported Values: rfc6265
cookie-samesite
Description ‘none’: none; ‘lax’: lax; ‘strict’: strict;
Type: string
Supported Values: none, lax, strict
default-charset
Description ‘iso-8859-1’: Use ISO-8859-1 as the default charset; ‘utf-8’: Use UTF-8 as the default charset; ‘us-ascii’: Use US-ASCII as the default charset;
Type: string
Supported Values: iso-8859-1, utf-8, us-ascii
Default: utf-8
failover-url
Description Failover to this URL (Failover URL Name)
Type: string
Format: string-rlx
Maximum Length: 255 characters
Maximum Length: 1 characters
frame-limit
Description Limit the number of CONTINUATION, PING, PRIORITY, RESET, SETTINGS and empty frames in one HTTP2 connection, default 10000
Type: number
Range: 0-65535
Default: 10000
host-switching
Type: Listhttp-protocol-check
Description: http-protocol-check is a JSON Block. Please see below for http-protocol-check
Type: Object
Reference Object: /axapi/v3/slb/template/http/{name}/http-protocol-check
insert-client-ip
Description Insert Client IP address into HTTP header
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
insert-client-ip-header-name
Description HTTP Header Name for inserting Client IP
Type: string
Maximum Length: 63 characters
Maximum Length: 1 characters
insert-client-port
Description Insert Client Port address into HTTP header
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
insert-client-port-header-name
Description HTTP Header Name for inserting Client Port
Type: string
Maximum Length: 63 characters
Maximum Length: 1 characters
keep-client-alive
Description Keep client alive
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
log-retry
Description log when HTTP request retry
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
max-concurrent-streams
Description (http2 only) Max concurrent streams, default 100
Type: number
Range: 1-1000
Default: 100
name
Description HTTP Template Name
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
non-http-bypass
Description Bypass non-http traffic instead of dropping
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
persist-on-401
Description Persist to the same server if the response code is 401
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
prefix
Description ‘host’: the cookie will have been set with a Secure attribute, a Path attribute with a value of /, and no Domain attribute; ‘secure’: the cookie will have been set with a Secure attribute; ‘check’: check server prefix and enforce prefix format;
Type: string
Supported Values: host, secure, check
rd-port
Description Port (Port Number)
Type: number
Range: 1-65535
Mutual Exclusion: rd-port and rd-simple-loc are mutually exclusive
rd-resp-code
Description ‘301’: Moved Permanently; ‘302’: Found; ‘303’: See Other; ‘307’: Temporary Redirect;
Type: string
Supported Values: 301, 302, 303, 307
rd-secure
Description Use HTTPS
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
Mutual Exclusion: rd-secure and rd-simple-loc are mutually exclusive
rd-simple-loc
Description Redirect location tag absolute URI string
Type: string
Format: string-rlx
Maximum Length: 255 characters
Maximum Length: 1 characters
Mutual Exclusion: rd-simple-loc rd-secure and rd-port are mutually exclusive
redirect
Description Automatically send a redirect response
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
redirect-rewrite
Description: redirect-rewrite is a JSON Block. Please see below for redirect-rewrite
Type: Object
req-hdr-wait-time
Description HTTP request header wait time before abort connection
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
req-hdr-wait-time-val
Description Number of seconds wait for client request header (default is 7)
Type: number
Range: 1-31
Default: 7
request-header-erase-list
Type: Listrequest-header-insert-list
Type: Listrequest-line-case-insensitive
Description Parse http request line as case insensitive
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
request-timeout
Description Request timeout if response not received (timeout in seconds)
Type: number
Range: 1-120
response-content-replace-list
Type: Listresponse-header-erase-list
Type: Listresponse-header-insert-list
Type: Listretry-on-5xx
Description Retry http request on HTTP 5xx code and request timeout
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
Mutual Exclusion: retry-on-5xx and retry-on-5xx-per-req are mutually exclusive
retry-on-5xx-per-req
Description Retry http request on HTTP 5xx code for each request
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
Mutual Exclusion: retry-on-5xx-per-req and retry-on-5xx are mutually exclusive
retry-on-5xx-per-req-val
Description Number of times to retry (default is 3)
Type: number
Range: 1-3
Default: 3
retry-on-5xx-val
Description Number of times to retry (default is 3)
Type: number
Range: 1-3
Default: 3
strict-transaction-switch
Description Force server selection on every HTTP request
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
template
Description: template is a JSON Block. Please see below for template
Type: Object
term-11client-hdr-conn-close
Description Terminate HTTP 1.1 client when req has Connection: close
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
url-hash-first
Description Use the begining part of URL to calculate hash value (URL string length to calculate hash value)
Type: number
Range: 4-128
Mutual Exclusion: url-hash-first and url-hash-last are mutually exclusive
url-hash-last
Description Use the end part of URL to calculate hash value (URL string length to calculate hash value)
Type: number
Range: 4-128
Mutual Exclusion: url-hash-last and url-hash-first are mutually exclusive
url-hash-offset
Description Skip part of URL to calculate hash value (Offset of the URL string)
Type: number
Range: 0-255
url-hash-persist
Description Use URL’s hash value to select server
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
url-switching
Type: Listuse-server-status
Description Use Server-Status header to do URL hashing
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
user-tag
Description Customized tag
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
uuid
Description uuid of the object
Type: string
Maximum Length: 64 characters
Maximum Length: 1 characters
request-header-erase-list¶
Specification Type list Block object keys request-header-erase
Description Erase a header from HTTP request (Header Name)
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
redirect-rewrite¶
Specification Type object match-list
Type: Listredirect-secure
Description Use HTTPS
Type: boolean
Supported Values: true, false, 1, 0
Default: 0
redirect-secure-port
Description Port (Port Number)
Type: number
Range: 1-65535
Default: 443
redirect-rewrite_match-list¶
Specification Type list Block object keys redirect-match
Description URL Matching (Pattern URL String)
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
rewrite-to
Description Rewrite to Destination URL String
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
response-header-insert-list¶
Specification Type list Block object keys response-header-insert
Description Insert a header into HTTP response (Header Content (Format: “[name]:[value]”))
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
response-header-insert-type
Description ‘insert-if-not-exist’: Only insert the header when it does not exist; ‘insert-always’: Always insert the header even when there is a header with the same name;
Type: string
Supported Values: insert-if-not-exist, insert-always
response-header-erase-list¶
Specification Type list Block object keys response-header-erase
Description Erase a header from HTTP response (Header Name)
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
template¶
Specification Type object logging
Description Logging template (Logging Config name)
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
Reference Object: /axapi/v3/slb/template/logging
url-switching¶
Specification Type list Block object keys url-match-string
Description URL String
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
url-service-group
Description Create a Service Group comprising Servers (Service Group Name)
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
Reference Object: /axapi/v3/slb/service-group
url-switching-type
Description ‘contains’: Select service group if URL string contains another string; ‘ends-with’: Select service group if URL string ends with another string; ‘equals’: Select service group if URL string equals another string; ‘starts-with’: Select service group if URL string starts with another string; ‘regex-match’: Select service group if URL string matches with regular expression; ‘url-case-insensitive’: Case insensitive URL switching; ‘url-hits-enable’: Enables URL Hits;
Type: string
Supported Values: contains, ends-with, equals, starts-with, regex-match, url-case-insensitive, url-hits-enable
response-content-replace-list¶
Specification Type list Block object keys response-content-replace
Description replace the data from HTTP response content (String in the http content need to be replaced)
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
response-new-string
Description String will be in the http content
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
http-protocol-check¶
Specification Type object get-and-payload
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
h2up-content-length-alias
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
h2up-with-host-and-auth
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
h2up-with-transfer-encoding
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
malformed-h2up-header-value
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
malformed-h2up-scheme-value
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
multiple-content-length
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
multiple-transfer-encoding
Description ‘drop’: Drop the request and send 400 to the client side;
Type: string
Supported Values: drop
transfer-encoding-and-content-length
Description ‘drop’: Drop the request and Send 400 to the client side;
Type: string
Supported Values: drop
uuid
Description uuid of the object
Type: string
Maximum Length: 64 characters
Maximum Length: 1 characters
request-header-insert-list¶
Specification Type list Block object keys request-header-insert
Description Insert a header into HTTP request (Header Content (Format: “[name]:[value]”))
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
request-header-insert-type
Description ‘insert-if-not-exist’: Only insert the header when it does not exist; ‘insert-always’: Always insert the header even when there is a header with the same name;
Type: string
Supported Values: insert-if-not-exist, insert-always
host-switching¶
Specification Type list Block object keys host-match-string
Description Hostname String
Type: string
Format: string-rlx
Maximum Length: 63 characters
Maximum Length: 1 characters
host-service-group
Description Create a Service Group comprising Servers (Service Group Name)
Type: string
Format: string-rlx
Maximum Length: 127 characters
Maximum Length: 1 characters
Reference Object: /axapi/v3/slb/service-group
host-switching-type
Description ‘contains’: Select service group if hostname contains another string; ‘ends-with’: Select service group if hostname ends with another string; ‘equals’: Select service group if hostname equals another string; ‘starts-with’: Select service group if hostname starts with another string; ‘regex-match’: Select service group if URL string matches with regular expression; ‘host-hits-enable’: Enables Host Hits counters;
Type: string
Supported Values: contains, ends-with, equals, starts-with, regex-match, host-hits-enable
compression-content-type¶
Specification Type list Block object keys content-type
Description Compression content-type
Type: string
Format: string-rlx
Maximum Length: 31 characters
Maximum Length: 1 characters
compression-exclude-uri¶
Specification Type list Block object keys exclude-uri
Description Compression exclude uri
Type: string
Format: string-rlx
Maximum Length: 31 characters
Maximum Length: 1 characters
compression-exclude-content-type¶
Specification Type list Block object keys exclude-content-type
Description Compression exclude content-type (Compression exclude content type)
Type: string
Format: string-rlx
Maximum Length: 31 characters
Maximum Length: 1 characters