1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. LoadBalancer
  5. getBackendSetHealth
Oracle Cloud Infrastructure v1.32.0 published on Thursday, Apr 18, 2024 by Pulumi

oci.LoadBalancer.getBackendSetHealth

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.32.0 published on Thursday, Apr 18, 2024 by Pulumi

    This data source provides details about a specific Backend Set Health resource in Oracle Cloud Infrastructure Load Balancer service.

    Gets the health status for the specified backend set.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testBackendSetHealth = oci.LoadBalancer.getBackendSetHealth({
        backendSetName: oci_load_balancer_backend_set.test_backend_set.name,
        loadBalancerId: oci_load_balancer_load_balancer.test_load_balancer.id,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_backend_set_health = oci.LoadBalancer.get_backend_set_health(backend_set_name=oci_load_balancer_backend_set["test_backend_set"]["name"],
        load_balancer_id=oci_load_balancer_load_balancer["test_load_balancer"]["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/LoadBalancer"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := LoadBalancer.GetBackendSetHealth(ctx, &loadbalancer.GetBackendSetHealthArgs{
    			BackendSetName: oci_load_balancer_backend_set.Test_backend_set.Name,
    			LoadBalancerId: oci_load_balancer_load_balancer.Test_load_balancer.Id,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testBackendSetHealth = Oci.LoadBalancer.GetBackendSetHealth.Invoke(new()
        {
            BackendSetName = oci_load_balancer_backend_set.Test_backend_set.Name,
            LoadBalancerId = oci_load_balancer_load_balancer.Test_load_balancer.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.LoadBalancer.LoadBalancerFunctions;
    import com.pulumi.oci.LoadBalancer.inputs.GetBackendSetHealthArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var testBackendSetHealth = LoadBalancerFunctions.getBackendSetHealth(GetBackendSetHealthArgs.builder()
                .backendSetName(oci_load_balancer_backend_set.test_backend_set().name())
                .loadBalancerId(oci_load_balancer_load_balancer.test_load_balancer().id())
                .build());
    
        }
    }
    
    variables:
      testBackendSetHealth:
        fn::invoke:
          Function: oci:LoadBalancer:getBackendSetHealth
          Arguments:
            backendSetName: ${oci_load_balancer_backend_set.test_backend_set.name}
            loadBalancerId: ${oci_load_balancer_load_balancer.test_load_balancer.id}
    

    Using getBackendSetHealth

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getBackendSetHealth(args: GetBackendSetHealthArgs, opts?: InvokeOptions): Promise<GetBackendSetHealthResult>
    function getBackendSetHealthOutput(args: GetBackendSetHealthOutputArgs, opts?: InvokeOptions): Output<GetBackendSetHealthResult>
    def get_backend_set_health(backend_set_name: Optional[str] = None,
                               load_balancer_id: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetBackendSetHealthResult
    def get_backend_set_health_output(backend_set_name: Optional[pulumi.Input[str]] = None,
                               load_balancer_id: Optional[pulumi.Input[str]] = None,
                               opts: Optional[InvokeOptions] = None) -> Output[GetBackendSetHealthResult]
    func GetBackendSetHealth(ctx *Context, args *GetBackendSetHealthArgs, opts ...InvokeOption) (*GetBackendSetHealthResult, error)
    func GetBackendSetHealthOutput(ctx *Context, args *GetBackendSetHealthOutputArgs, opts ...InvokeOption) GetBackendSetHealthResultOutput

    > Note: This function is named GetBackendSetHealth in the Go SDK.

    public static class GetBackendSetHealth 
    {
        public static Task<GetBackendSetHealthResult> InvokeAsync(GetBackendSetHealthArgs args, InvokeOptions? opts = null)
        public static Output<GetBackendSetHealthResult> Invoke(GetBackendSetHealthInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetBackendSetHealthResult> getBackendSetHealth(GetBackendSetHealthArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:LoadBalancer/getBackendSetHealth:getBackendSetHealth
      arguments:
        # arguments dictionary

    The following arguments are supported:

    BackendSetName string
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    LoadBalancerId string
    The OCID of the load balancer associated with the backend set health status to be retrieved.
    BackendSetName string
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    LoadBalancerId string
    The OCID of the load balancer associated with the backend set health status to be retrieved.
    backendSetName String
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    loadBalancerId String
    The OCID of the load balancer associated with the backend set health status to be retrieved.
    backendSetName string
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    loadBalancerId string
    The OCID of the load balancer associated with the backend set health status to be retrieved.
    backend_set_name str
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    load_balancer_id str
    The OCID of the load balancer associated with the backend set health status to be retrieved.
    backendSetName String
    The name of the backend set to retrieve the health status for. Example: example_backend_set
    loadBalancerId String
    The OCID of the load balancer associated with the backend set health status to be retrieved.

    getBackendSetHealth Result

    The following output properties are available:

    BackendSetName string
    CriticalStateBackendNames List<string>
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    Id string
    The provider-assigned unique ID for this managed resource.
    LoadBalancerId string
    Status string
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    TotalBackendCount int
    The total number of backend servers in this backend set. Example: 7
    UnknownStateBackendNames List<string>
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    WarningStateBackendNames List<string>
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080
    BackendSetName string
    CriticalStateBackendNames []string
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    Id string
    The provider-assigned unique ID for this managed resource.
    LoadBalancerId string
    Status string
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    TotalBackendCount int
    The total number of backend servers in this backend set. Example: 7
    UnknownStateBackendNames []string
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    WarningStateBackendNames []string
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080
    backendSetName String
    criticalStateBackendNames List<String>
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    id String
    The provider-assigned unique ID for this managed resource.
    loadBalancerId String
    status String
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    totalBackendCount Integer
    The total number of backend servers in this backend set. Example: 7
    unknownStateBackendNames List<String>
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    warningStateBackendNames List<String>
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080
    backendSetName string
    criticalStateBackendNames string[]
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    id string
    The provider-assigned unique ID for this managed resource.
    loadBalancerId string
    status string
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    totalBackendCount number
    The total number of backend servers in this backend set. Example: 7
    unknownStateBackendNames string[]
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    warningStateBackendNames string[]
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080
    backend_set_name str
    critical_state_backend_names Sequence[str]
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    id str
    The provider-assigned unique ID for this managed resource.
    load_balancer_id str
    status str
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    total_backend_count int
    The total number of backend servers in this backend set. Example: 7
    unknown_state_backend_names Sequence[str]
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    warning_state_backend_names Sequence[str]
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080
    backendSetName String
    criticalStateBackendNames List<String>
    A list of backend servers that are currently in the CRITICAL health state. The list identifies each backend server by IP address and port. Example: 10.0.0.4:8080
    id String
    The provider-assigned unique ID for this managed resource.
    loadBalancerId String
    status String
    Overall health status of the backend set.

    • OK: All backend servers in the backend set return a status of OK.
    • WARNING: Half or more of the backend set's backend servers return a status of OK and at least one backend server returns a status of WARNING, CRITICAL, or UNKNOWN.
    • CRITICAL: Fewer than half of the backend set's backend servers return a status of OK.
    • UNKNOWN: More than half of the backend set's backend servers return a status of UNKNOWN, the system was unable to retrieve metrics, or the backend set does not have a listener attached.
    totalBackendCount Number
    The total number of backend servers in this backend set. Example: 7
    unknownStateBackendNames List<String>
    A list of backend servers that are currently in the UNKNOWN health state. The list identifies each backend server by IP address and port. Example: 10.0.0.5:8080
    warningStateBackendNames List<String>
    A list of backend servers that are currently in the WARNING health state. The list identifies each backend server by IP address and port. Example: 10.0.0.3:8080

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v1.32.0 published on Thursday, Apr 18, 2024 by Pulumi