public class HealthCheck extends AbstractModel
Constructor and Description |
---|
HealthCheck() |
Modifier and Type | Method and Description |
---|---|
Long |
getCheckPort()
Get Health check port (a custom check parameter), which is the port of the real server by default.
|
String |
getCheckType()
Get Health check protocol (a custom check parameter).
|
String |
getContextType()
Get Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
Long |
getHealthNum()
Get Health threshold.
|
Long |
getHealthSwitch()
Get Whether to enable health check.
|
String |
getHttpCheckDomain()
Get Health check domain name (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
String |
getHttpCheckMethod()
Get Health check method (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
String |
getHttpCheckPath()
Get Health check path (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
Long |
getHttpCode()
Get Health check status code (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
String |
getHttpVersion()
Get Health check protocol (a custom check parameter), which is required if the value of CheckType is HTTP.
|
Long |
getIntervalTime()
Get Health check interval in seconds.
|
String |
getRecvContext()
Get Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
String |
getSendContext()
Get Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
Long |
getTimeOut()
Get Health check response timeout period in seconds (applicable only to layer-4 listeners).
|
Long |
getUnHealthNum()
Get Unhealthy threshold.
|
void |
setCheckPort(Long CheckPort)
Set Health check port (a custom check parameter), which is the port of the real server by default.
|
void |
setCheckType(String CheckType)
Set Health check protocol (a custom check parameter).
|
void |
setContextType(String ContextType)
Set Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
void |
setHealthNum(Long HealthNum)
Set Health threshold.
|
void |
setHealthSwitch(Long HealthSwitch)
Set Whether to enable health check.
|
void |
setHttpCheckDomain(String HttpCheckDomain)
Set Health check domain name (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
void |
setHttpCheckMethod(String HttpCheckMethod)
Set Health check method (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
void |
setHttpCheckPath(String HttpCheckPath)
Set Health check path (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
void |
setHttpCode(Long HttpCode)
Set Health check status code (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
|
void |
setHttpVersion(String HttpVersion)
Set Health check protocol (a custom check parameter), which is required if the value of CheckType is HTTP.
|
void |
setIntervalTime(Long IntervalTime)
Set Health check interval in seconds.
|
void |
setRecvContext(String RecvContext)
Set Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
void |
setSendContext(String SendContext)
Set Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM.
|
void |
setTimeOut(Long TimeOut)
Set Health check response timeout period in seconds (applicable only to layer-4 listeners).
|
void |
setUnHealthNum(Long UnHealthNum)
Set Unhealthy threshold.
|
void |
toMap(HashMap<String,String> map,
String prefix)
Internal implementation, normal users should not use it.
|
any, fromJsonString, getBinaryParams, getMultipartRequestParams, set, setParamArrayObj, setParamArraySimple, setParamObj, setParamSimple, toJsonString
public Long getHealthSwitch()
public void setHealthSwitch(Long HealthSwitch)
HealthSwitch
- Whether to enable health check. 1: enable; 0: disable.public Long getTimeOut()
public void setTimeOut(Long TimeOut)
TimeOut
- Health check response timeout period in seconds (applicable only to layer-4 listeners). Value range: 2-60. Default value: 2. This parameter should be less than the check interval.
Note: This field may return null, indicating that no valid values can be obtained.public Long getIntervalTime()
public void setIntervalTime(Long IntervalTime)
IntervalTime
- Health check interval in seconds. Value range: 5-300. Default value: 5.
Note: This field may return null, indicating that no valid values can be obtained.public Long getHealthNum()
public void setHealthNum(Long HealthNum)
HealthNum
- Health threshold. Default value: 3, indicating that if a forward is found healthy three consecutive times, it is considered to be normal. Value range: 2-10
Note: This field may return null, indicating that no valid values can be obtained.public Long getUnHealthNum()
public void setUnHealthNum(Long UnHealthNum)
UnHealthNum
- Unhealthy threshold. Default value: 3, indicating that if a forward is found unhealthy three consecutive times, it is considered to be exceptional. Value range: 2-10
Note: This field may return null, indicating that no valid values can be obtained.public Long getHttpCode()
public void setHttpCode(Long HttpCode)
HttpCode
- Health check status code (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners). Value range: 1-31. Default value: 31.
1 means that the return value of 1xx after detection means healthy, 2 for returning 2xx for healthy, 4 for returning 3xx for healthy, 8 for returning 4xx for healthy, and 16 for returning 5xx for healthy. If you want multiple return codes to represent healthy, sum up the corresponding values. Note: The HTTP health check mode of TCP listeners only supports specifying one kind of health check status code.
Note: This field may return null, indicating that no valid values can be obtained.public String getHttpCheckPath()
public void setHttpCheckPath(String HttpCheckPath)
HttpCheckPath
- Health check path (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
Note: This field may return null, indicating that no valid values can be obtained.public String getHttpCheckDomain()
public void setHttpCheckDomain(String HttpCheckDomain)
HttpCheckDomain
- Health check domain name (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners).
Note: This field may return null, indicating that no valid values can be obtained.public String getHttpCheckMethod()
public void setHttpCheckMethod(String HttpCheckMethod)
HttpCheckMethod
- Health check method (applicable only to HTTP/HTTPS forwarding rules and HTTP health checks of TCP listeners). Value range: HEAD, GET. Default value: HEAD.
Note: This field may return null, indicating that no valid values can be obtained.public Long getCheckPort()
public void setCheckPort(Long CheckPort)
CheckPort
- Health check port (a custom check parameter), which is the port of the real server by default. Unless you want to specify a port, it is recommended to leave it empty. (Applicable only to TCP/UDP listeners.)
Note: This field may return null, indicating that no valid values can be obtained.public String getContextType()
public void setContextType(String ContextType)
ContextType
- Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM. This parameter represents the input format of the health check. Value range: HEX, TEXT. If the value is HEX, the characters of SendContext and RecvContext can only be selected from 0123456789ABCDEF and the length must be an even number. (Applicable only to TCP/UDP listeners.)
Note: This field may return null, indicating that no valid values can be obtained.public String getSendContext()
public void setSendContext(String SendContext)
SendContext
- Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM. This parameter represents the content of the request sent by the health check. Only ASCII visible characters are allowed, and the maximum length is 500. (Applicable only to TCP/UDP listeners.)
Note: This field may return null, indicating that no valid values can be obtained.public String getRecvContext()
public void setRecvContext(String RecvContext)
RecvContext
- Health check protocol (a custom check parameter), which is required if the value of CheckType is CUSTOM. This parameter represents the result returned by the health check. Only ASCII visible characters are allowed, and the maximum length is 500. (Applicable only to TCP/UDP listeners.)
Note: This field may return null, indicating that no valid values can be obtained.public String getCheckType()
public void setCheckType(String CheckType)
CheckType
- Health check protocol (a custom check parameter). Value range: TCP, HTTP, CUSTOM (applicable only to TCP/UDP listeners, where UDP listeners only support CUSTOM. If custom health check is used, this parameter is required).
Note: This field may return null, indicating that no valid values can be obtained.public String getHttpVersion()
public void setHttpVersion(String HttpVersion)
HttpVersion
- Health check protocol (a custom check parameter), which is required if the value of CheckType is HTTP. This parameter represents the HTTP version of the real server. Value range: HTTP/1.0, HTTP/1.1. (Applicable only to TCP listeners.)
Note: This field may return null, indicating that no valid values can be obtained.Copyright © 2020. All rights reserved.