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

oci.Opsi.getAwrHubs

Explore with Pulumi AI

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

    This data source provides the list of Awr Hubs in Oracle Cloud Infrastructure Opsi service.

    Gets a list of AWR hubs. Either compartmentId or id must be specified. All these resources are expected to be in root compartment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testAwrHubs = oci.Opsi.getAwrHubs({
        operationsInsightsWarehouseId: oci_opsi_operations_insights_warehouse.test_operations_insights_warehouse.id,
        compartmentId: _var.compartment_id,
        displayName: _var.awr_hub_display_name,
        id: _var.awr_hub_id,
        states: _var.awr_hub_state,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_awr_hubs = oci.Opsi.get_awr_hubs(operations_insights_warehouse_id=oci_opsi_operations_insights_warehouse["test_operations_insights_warehouse"]["id"],
        compartment_id=var["compartment_id"],
        display_name=var["awr_hub_display_name"],
        id=var["awr_hub_id"],
        states=var["awr_hub_state"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Opsi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Opsi.GetAwrHubs(ctx, &opsi.GetAwrHubsArgs{
    			OperationsInsightsWarehouseId: oci_opsi_operations_insights_warehouse.Test_operations_insights_warehouse.Id,
    			CompartmentId:                 pulumi.StringRef(_var.Compartment_id),
    			DisplayName:                   pulumi.StringRef(_var.Awr_hub_display_name),
    			Id:                            pulumi.StringRef(_var.Awr_hub_id),
    			States:                        _var.Awr_hub_state,
    		}, 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 testAwrHubs = Oci.Opsi.GetAwrHubs.Invoke(new()
        {
            OperationsInsightsWarehouseId = oci_opsi_operations_insights_warehouse.Test_operations_insights_warehouse.Id,
            CompartmentId = @var.Compartment_id,
            DisplayName = @var.Awr_hub_display_name,
            Id = @var.Awr_hub_id,
            States = @var.Awr_hub_state,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Opsi.OpsiFunctions;
    import com.pulumi.oci.Opsi.inputs.GetAwrHubsArgs;
    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 testAwrHubs = OpsiFunctions.getAwrHubs(GetAwrHubsArgs.builder()
                .operationsInsightsWarehouseId(oci_opsi_operations_insights_warehouse.test_operations_insights_warehouse().id())
                .compartmentId(var_.compartment_id())
                .displayName(var_.awr_hub_display_name())
                .id(var_.awr_hub_id())
                .states(var_.awr_hub_state())
                .build());
    
        }
    }
    
    variables:
      testAwrHubs:
        fn::invoke:
          Function: oci:Opsi:getAwrHubs
          Arguments:
            operationsInsightsWarehouseId: ${oci_opsi_operations_insights_warehouse.test_operations_insights_warehouse.id}
            compartmentId: ${var.compartment_id}
            displayName: ${var.awr_hub_display_name}
            id: ${var.awr_hub_id}
            states: ${var.awr_hub_state}
    

    Using getAwrHubs

    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 getAwrHubs(args: GetAwrHubsArgs, opts?: InvokeOptions): Promise<GetAwrHubsResult>
    function getAwrHubsOutput(args: GetAwrHubsOutputArgs, opts?: InvokeOptions): Output<GetAwrHubsResult>
    def get_awr_hubs(compartment_id: Optional[str] = None,
                     display_name: Optional[str] = None,
                     filters: Optional[Sequence[_opsi.GetAwrHubsFilter]] = None,
                     id: Optional[str] = None,
                     operations_insights_warehouse_id: Optional[str] = None,
                     states: Optional[Sequence[str]] = None,
                     opts: Optional[InvokeOptions] = None) -> GetAwrHubsResult
    def get_awr_hubs_output(compartment_id: Optional[pulumi.Input[str]] = None,
                     display_name: Optional[pulumi.Input[str]] = None,
                     filters: Optional[pulumi.Input[Sequence[pulumi.Input[_opsi.GetAwrHubsFilterArgs]]]] = None,
                     id: Optional[pulumi.Input[str]] = None,
                     operations_insights_warehouse_id: Optional[pulumi.Input[str]] = None,
                     states: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                     opts: Optional[InvokeOptions] = None) -> Output[GetAwrHubsResult]
    func GetAwrHubs(ctx *Context, args *GetAwrHubsArgs, opts ...InvokeOption) (*GetAwrHubsResult, error)
    func GetAwrHubsOutput(ctx *Context, args *GetAwrHubsOutputArgs, opts ...InvokeOption) GetAwrHubsResultOutput

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

    public static class GetAwrHubs 
    {
        public static Task<GetAwrHubsResult> InvokeAsync(GetAwrHubsArgs args, InvokeOptions? opts = null)
        public static Output<GetAwrHubsResult> Invoke(GetAwrHubsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetAwrHubsResult> getAwrHubs(GetAwrHubsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Opsi/getAwrHubs:getAwrHubs
      arguments:
        # arguments dictionary

    The following arguments are supported:

    OperationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    CompartmentId string
    The OCID of the compartment.
    DisplayName string
    A filter to return only resources that match the entire display name.
    Filters List<GetAwrHubsFilter>
    Id string
    Unique Awr Hub identifier
    States List<string>
    Lifecycle states
    OperationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    CompartmentId string
    The OCID of the compartment.
    DisplayName string
    A filter to return only resources that match the entire display name.
    Filters []GetAwrHubsFilter
    Id string
    Unique Awr Hub identifier
    States []string
    Lifecycle states
    operationsInsightsWarehouseId String
    Unique Operations Insights Warehouse identifier
    compartmentId String
    The OCID of the compartment.
    displayName String
    A filter to return only resources that match the entire display name.
    filters List<GetAwrHubsFilter>
    id String
    Unique Awr Hub identifier
    states List<String>
    Lifecycle states
    operationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    compartmentId string
    The OCID of the compartment.
    displayName string
    A filter to return only resources that match the entire display name.
    filters GetAwrHubsFilter[]
    id string
    Unique Awr Hub identifier
    states string[]
    Lifecycle states
    operations_insights_warehouse_id str
    Unique Operations Insights Warehouse identifier
    compartment_id str
    The OCID of the compartment.
    display_name str
    A filter to return only resources that match the entire display name.
    filters Sequence[opsi.GetAwrHubsFilter]
    id str
    Unique Awr Hub identifier
    states Sequence[str]
    Lifecycle states
    operationsInsightsWarehouseId String
    Unique Operations Insights Warehouse identifier
    compartmentId String
    The OCID of the compartment.
    displayName String
    A filter to return only resources that match the entire display name.
    filters List<Property Map>
    id String
    Unique Awr Hub identifier
    states List<String>
    Lifecycle states

    getAwrHubs Result

    The following output properties are available:

    AwrHubSummaryCollections List<GetAwrHubsAwrHubSummaryCollection>
    The list of awr_hub_summary_collection.
    OperationsInsightsWarehouseId string
    OPSI Warehouse OCID
    CompartmentId string
    The OCID of the compartment.
    DisplayName string
    User-friedly name of AWR Hub that does not have to be unique.
    Filters List<GetAwrHubsFilter>
    Id string
    AWR Hub OCID
    States List<string>
    Possible lifecycle states
    AwrHubSummaryCollections []GetAwrHubsAwrHubSummaryCollection
    The list of awr_hub_summary_collection.
    OperationsInsightsWarehouseId string
    OPSI Warehouse OCID
    CompartmentId string
    The OCID of the compartment.
    DisplayName string
    User-friedly name of AWR Hub that does not have to be unique.
    Filters []GetAwrHubsFilter
    Id string
    AWR Hub OCID
    States []string
    Possible lifecycle states
    awrHubSummaryCollections List<GetAwrHubsAwrHubSummaryCollection>
    The list of awr_hub_summary_collection.
    operationsInsightsWarehouseId String
    OPSI Warehouse OCID
    compartmentId String
    The OCID of the compartment.
    displayName String
    User-friedly name of AWR Hub that does not have to be unique.
    filters List<GetAwrHubsFilter>
    id String
    AWR Hub OCID
    states List<String>
    Possible lifecycle states
    awrHubSummaryCollections GetAwrHubsAwrHubSummaryCollection[]
    The list of awr_hub_summary_collection.
    operationsInsightsWarehouseId string
    OPSI Warehouse OCID
    compartmentId string
    The OCID of the compartment.
    displayName string
    User-friedly name of AWR Hub that does not have to be unique.
    filters GetAwrHubsFilter[]
    id string
    AWR Hub OCID
    states string[]
    Possible lifecycle states
    awr_hub_summary_collections Sequence[opsi.GetAwrHubsAwrHubSummaryCollection]
    The list of awr_hub_summary_collection.
    operations_insights_warehouse_id str
    OPSI Warehouse OCID
    compartment_id str
    The OCID of the compartment.
    display_name str
    User-friedly name of AWR Hub that does not have to be unique.
    filters Sequence[opsi.GetAwrHubsFilter]
    id str
    AWR Hub OCID
    states Sequence[str]
    Possible lifecycle states
    awrHubSummaryCollections List<Property Map>
    The list of awr_hub_summary_collection.
    operationsInsightsWarehouseId String
    OPSI Warehouse OCID
    compartmentId String
    The OCID of the compartment.
    displayName String
    User-friedly name of AWR Hub that does not have to be unique.
    filters List<Property Map>
    id String
    AWR Hub OCID
    states List<String>
    Possible lifecycle states

    Supporting Types

    GetAwrHubsAwrHubSummaryCollection

    GetAwrHubsAwrHubSummaryCollectionItem

    AwrMailboxUrl string
    Mailbox URL required for AWR hub and AWR source setup.
    CompartmentId string
    The OCID of the compartment.
    DefinedTags Dictionary<string, object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    DisplayName string
    A filter to return only resources that match the entire display name.
    FreeformTags Dictionary<string, object>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    HubDstTimezoneVersion string
    Dst Time Zone Version of the AWR Hub
    Id string
    Unique Awr Hub identifier
    LifecycleDetails string
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    ObjectStorageBucketName string
    Object Storage Bucket Name
    OperationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    State string
    Lifecycle states
    SystemTags Dictionary<string, object>
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The time at which the resource was first created. An RFC3339 formatted datetime string
    TimeUpdated string
    The time at which the resource was last updated. An RFC3339 formatted datetime string
    AwrMailboxUrl string
    Mailbox URL required for AWR hub and AWR source setup.
    CompartmentId string
    The OCID of the compartment.
    DefinedTags map[string]interface{}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    DisplayName string
    A filter to return only resources that match the entire display name.
    FreeformTags map[string]interface{}
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    HubDstTimezoneVersion string
    Dst Time Zone Version of the AWR Hub
    Id string
    Unique Awr Hub identifier
    LifecycleDetails string
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    ObjectStorageBucketName string
    Object Storage Bucket Name
    OperationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    State string
    Lifecycle states
    SystemTags map[string]interface{}
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    TimeCreated string
    The time at which the resource was first created. An RFC3339 formatted datetime string
    TimeUpdated string
    The time at which the resource was last updated. An RFC3339 formatted datetime string
    awrMailboxUrl String
    Mailbox URL required for AWR hub and AWR source setup.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<String,Object>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName String
    A filter to return only resources that match the entire display name.
    freeformTags Map<String,Object>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    hubDstTimezoneVersion String
    Dst Time Zone Version of the AWR Hub
    id String
    Unique Awr Hub identifier
    lifecycleDetails String
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    objectStorageBucketName String
    Object Storage Bucket Name
    operationsInsightsWarehouseId String
    Unique Operations Insights Warehouse identifier
    state String
    Lifecycle states
    systemTags Map<String,Object>
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The time at which the resource was first created. An RFC3339 formatted datetime string
    timeUpdated String
    The time at which the resource was last updated. An RFC3339 formatted datetime string
    awrMailboxUrl string
    Mailbox URL required for AWR hub and AWR source setup.
    compartmentId string
    The OCID of the compartment.
    definedTags {[key: string]: any}
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName string
    A filter to return only resources that match the entire display name.
    freeformTags {[key: string]: any}
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    hubDstTimezoneVersion string
    Dst Time Zone Version of the AWR Hub
    id string
    Unique Awr Hub identifier
    lifecycleDetails string
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    objectStorageBucketName string
    Object Storage Bucket Name
    operationsInsightsWarehouseId string
    Unique Operations Insights Warehouse identifier
    state string
    Lifecycle states
    systemTags {[key: string]: any}
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated string
    The time at which the resource was first created. An RFC3339 formatted datetime string
    timeUpdated string
    The time at which the resource was last updated. An RFC3339 formatted datetime string
    awr_mailbox_url str
    Mailbox URL required for AWR hub and AWR source setup.
    compartment_id str
    The OCID of the compartment.
    defined_tags Mapping[str, Any]
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    display_name str
    A filter to return only resources that match the entire display name.
    freeform_tags Mapping[str, Any]
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    hub_dst_timezone_version str
    Dst Time Zone Version of the AWR Hub
    id str
    Unique Awr Hub identifier
    lifecycle_details str
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    object_storage_bucket_name str
    Object Storage Bucket Name
    operations_insights_warehouse_id str
    Unique Operations Insights Warehouse identifier
    state str
    Lifecycle states
    system_tags Mapping[str, Any]
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    time_created str
    The time at which the resource was first created. An RFC3339 formatted datetime string
    time_updated str
    The time at which the resource was last updated. An RFC3339 formatted datetime string
    awrMailboxUrl String
    Mailbox URL required for AWR hub and AWR source setup.
    compartmentId String
    The OCID of the compartment.
    definedTags Map<Any>
    Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
    displayName String
    A filter to return only resources that match the entire display name.
    freeformTags Map<Any>
    Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
    hubDstTimezoneVersion String
    Dst Time Zone Version of the AWR Hub
    id String
    Unique Awr Hub identifier
    lifecycleDetails String
    A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
    objectStorageBucketName String
    Object Storage Bucket Name
    operationsInsightsWarehouseId String
    Unique Operations Insights Warehouse identifier
    state String
    Lifecycle states
    systemTags Map<Any>
    System tags for this resource. Each key is predefined and scoped to a namespace. Example: {"orcl-cloud.free-tier-retained": "true"}
    timeCreated String
    The time at which the resource was first created. An RFC3339 formatted datetime string
    timeUpdated String
    The time at which the resource was last updated. An RFC3339 formatted datetime string

    GetAwrHubsFilter

    Name string
    Values List<string>
    Regex bool
    Name string
    Values []string
    Regex bool
    name String
    values List<String>
    regex Boolean
    name string
    values string[]
    regex boolean
    name str
    values Sequence[str]
    regex bool
    name String
    values List<String>
    regex Boolean

    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