backends
Creates, updates, deletes, gets or lists a backends resource.
Overview​
| Name | backends |
| Type | Resource |
| Id | oci.load_balancer.backends |
Fields​
The following fields are returned by SELECT queries:
- get
- list
The backend server information is being retrieved.
| Name | Datatype | Description |
|---|---|---|
name | string | A read-only field showing the IP address and port that uniquely identify this backend server in the backend set. Example: 10.0.0.3:8080 |
backup | boolean | Whether the load balancer should treat this server as a backup unit. If true, the load balancer forwards no ingress traffic to this backend server unless all other backend servers not marked as "backup" fail the health check policy. Note: You cannot add a backend server marked as backup to a backend set that uses the IP Hash policy. Example: false |
drain | boolean | Whether the load balancer should drain this server. Servers marked "drain" receive no new incoming traffic. Example: false |
ipAddress | string | The IP address of the backend server. Example: 10.0.0.3 |
maxConnections | integer (int32) | The maximum number of simultaneous connections the load balancer can make to the backend. If this is not set or set to 0 then the maximum number of simultaneous connections the load balancer can make to the backend is unlimited. Example: 300 |
offline | boolean | Whether the load balancer should treat this server as offline. Offline servers receive no incoming traffic. Example: false |
port | integer (int32) | The communication port for the backend server. Example: 8080 |
weight | integer (int32) | The load balancing policy weight assigned to the server. Backend servers with a higher weight receive a larger proportion of incoming traffic. For example, a server weighted '3' receives 3 times the number of new connections as a server weighted '1'. For more information on load balancing policies, see [How Load Balancing Policies Work](/Content/Balance/Reference/lbpolicies.htm). Example: 3 |
The configuration of a backend server that is a member of a load balancer backend set.<br />For more information, see [Managing Backend Servers](/Content/Balance/Tasks/managingbackendservers.htm).<br />
| Name | Datatype | Description |
|---|---|---|
name | string | A read-only field showing the IP address and port that uniquely identify this backend server in the backend set. Example: 10.0.0.3:8080 |
backup | boolean | Whether the load balancer should treat this server as a backup unit. If true, the load balancer forwards no ingress traffic to this backend server unless all other backend servers not marked as "backup" fail the health check policy. Note: You cannot add a backend server marked as backup to a backend set that uses the IP Hash policy. Example: false |
drain | boolean | Whether the load balancer should drain this server. Servers marked "drain" receive no new incoming traffic. Example: false |
ipAddress | string | The IP address of the backend server. Example: 10.0.0.3 |
maxConnections | integer (int32) | The maximum number of simultaneous connections the load balancer can make to the backend. If this is not set or set to 0 then the maximum number of simultaneous connections the load balancer can make to the backend is unlimited. Example: 300 |
offline | boolean | Whether the load balancer should treat this server as offline. Offline servers receive no incoming traffic. Example: false |
port | integer (int32) | The communication port for the backend server. Example: 8080 |
weight | integer (int32) | The load balancing policy weight assigned to the server. Backend servers with a higher weight receive a larger proportion of incoming traffic. For example, a server weighted '3' receives 3 times the number of new connections as a server weighted '1'. For more information on load balancing policies, see [How Load Balancing Policies Work](/Content/Balance/Reference/lbpolicies.htm). Example: 3 |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | loadBalancerId, backendSetName, backendName, region | opc-request-id | Gets the specified backend server's configuration information. |
list | select | loadBalancerId, backendSetName, region | opc-request-id | Lists the backend servers for a given load balancer and backend set. |
create | insert | loadBalancerId, backendSetName, region, ipAddress, port | opc-request-id, opc-retry-token | Adds a backend server to a backend set. |
update | update | loadBalancerId, backendSetName, backendName, region, weight, backup, drain, offline | opc-request-id, opc-retry-token | Updates the configuration of a backend server within the specified backend set. |
delete | delete | loadBalancerId, backendSetName, backendName, region | opc-request-id | Removes a backend server from a given load balancer and backend set. |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
backendName | string | The IP address and port of the backend server to remove. Example: 10.0.0.3:8080 |
backendSetName | string | The name of the backend set associated with the backend server. Example: example_backend_set |
loadBalancerId | string | The [OCID](/Content/General/Concepts/identifiers.htm) of the load balancer associated with the backend set and server. |
region | string | OCI region identifier (e.g. us-ashburn-1, ap-sydney-1); resolves from OCI_REGION when not supplied in the query. (default: us-ashburn-1, x-stackQL-envVar: OCI_REGION) |
opc-request-id | string | The unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID. |
opc-retry-token | string | A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations (e.g., if a resource has been deleted and purged from the system, then a retry of the original creation request may be rejected). |
SELECT examples​
- get
- list
Gets the specified backend server's configuration information.
SELECT
name,
backup,
drain,
ipAddress,
maxConnections,
offline,
port,
weight
FROM oci.load_balancer.backends
WHERE loadBalancerId = '{{ loadBalancerId }}' -- required
AND backendSetName = '{{ backendSetName }}' -- required
AND backendName = '{{ backendName }}' -- required
AND region = '{{ region }}' -- required
AND opc-request-id = '{{ opc-request-id }}'
;
Lists the backend servers for a given load balancer and backend set.
SELECT
name,
backup,
drain,
ipAddress,
maxConnections,
offline,
port,
weight
FROM oci.load_balancer.backends
WHERE loadBalancerId = '{{ loadBalancerId }}' -- required
AND backendSetName = '{{ backendSetName }}' -- required
AND region = '{{ region }}' -- required
AND opc-request-id = '{{ opc-request-id }}'
;
INSERT examples​
- create
- Manifest
Adds a backend server to a backend set.
INSERT INTO oci.load_balancer.backends (
backup,
drain,
ipAddress,
maxConnections,
offline,
port,
weight,
loadBalancerId,
backendSetName,
region,
opc-request-id,
opc-retry-token
)
SELECT
{{ backup }},
{{ drain }},
'{{ ipAddress }}' /* required */,
{{ maxConnections }},
{{ offline }},
{{ port }} /* required */,
{{ weight }},
'{{ loadBalancerId }}',
'{{ backendSetName }}',
'{{ region }}',
'{{ opc-request-id }}',
'{{ opc-retry-token }}'
;
# Description fields are for documentation purposes
- name: backends
props:
- name: loadBalancerId
value: "{{ loadBalancerId }}"
description: Required parameter for the backends resource.
- name: backendSetName
value: "{{ backendSetName }}"
description: Required parameter for the backends resource.
- name: region
value: "{{ region }}"
description: Required parameter for the backends resource.
- name: backup
value: {{ backup }}
description: |
Whether the load balancer should treat this server as a backup unit. If `true`, the load balancer forwards no ingress
traffic to this backend server unless all other backend servers not marked as "backup" fail the health check policy.
**Note:** You cannot add a backend server marked as `backup` to a backend set that uses the IP Hash policy.
Example: `false`
default: false
- name: drain
value: {{ drain }}
description: |
Whether the load balancer should drain this server. Servers marked "drain" receive no new
incoming traffic.
Example: `false`
default: false
- name: ipAddress
value: "{{ ipAddress }}"
description: |
The IP address of the backend server.
Example: `10.0.0.3`
- name: maxConnections
value: {{ maxConnections }}
description: |
The maximum number of simultaneous connections the load balancer can make to the backend.
If this is not set or set to 0 then the maximum number of simultaneous connections the
load balancer can make to the backend is unlimited.
If setting maxConnections to some value other than 0 then that value must be greater
or equal to 256.
Example: `300`
- name: offline
value: {{ offline }}
description: |
Whether the load balancer should treat this server as offline. Offline servers receive no incoming
traffic.
Example: `false`
default: false
- name: port
value: {{ port }}
description: |
The communication port for the backend server.
Example: `8080`
- name: weight
value: {{ weight }}
description: |
The load balancing policy weight assigned to the server. Backend servers with a higher weight receive a larger
proportion of incoming traffic. For example, a server weighted '3' receives 3 times the number of new connections
as a server weighted '1'.
For more information on load balancing policies, see
[How Load Balancing Policies Work](/Content/Balance/Reference/lbpolicies.htm).
Example: `3`
- name: opc-request-id
value: "{{ opc-request-id }}"
description: The unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
description: The unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
- name: opc-retry-token
value: "{{ opc-retry-token }}"
description: A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations (e.g., if a resource has been deleted and purged from the system, then a retry of the original creation request may be rejected).
description: A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations (e.g., if a resource has been deleted and purged from the system, then a retry of the original creation request may be rejected).
UPDATE examples​
- update
Updates the configuration of a backend server within the specified backend set.
UPDATE oci.load_balancer.backends
SET
backup = {{ backup }},
drain = {{ drain }},
maxConnections = {{ maxConnections }},
offline = {{ offline }},
weight = {{ weight }}
WHERE
loadBalancerId = '{{ loadBalancerId }}' --required
AND backendSetName = '{{ backendSetName }}' --required
AND backendName = '{{ backendName }}' --required
AND region = '{{ region }}' --required
AND weight = '{{ weight }}' --required
AND backup = {{ backup }} --required
AND drain = {{ drain }} --required
AND offline = {{ offline }} --required
AND opc-request-id = '{{ opc-request-id}}'
AND opc-retry-token = '{{ opc-retry-token}}';
DELETE examples​
- delete
Removes a backend server from a given load balancer and backend set.
DELETE FROM oci.load_balancer.backends
WHERE loadBalancerId = '{{ loadBalancerId }}' --required
AND backendSetName = '{{ backendSetName }}' --required
AND backendName = '{{ backendName }}' --required
AND region = '{{ region }}' --required
AND opc-request-id = '{{ opc-request-id }}'
;