1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. LogAnalytics
  5. LogAnalyticsPreferencesManagement
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

oci.LogAnalytics.LogAnalyticsPreferencesManagement

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

    This resource provides the Log Analytics Preferences Management resource in Oracle Cloud Infrastructure Log Analytics service.

    Updates the tenant preferences such as DEFAULT_HOMEPAGE and collection properties.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testLogAnalyticsPreferencesManagement = new oci.loganalytics.LogAnalyticsPreferencesManagement("test_log_analytics_preferences_management", {
        namespace: logAnalyticsPreferencesManagementNamespace,
        items: [{
            name: logAnalyticsPreferencesManagementItemsName,
            value: logAnalyticsPreferencesManagementItemsValue,
        }],
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_log_analytics_preferences_management = oci.log_analytics.LogAnalyticsPreferencesManagement("test_log_analytics_preferences_management",
        namespace=log_analytics_preferences_management_namespace,
        items=[{
            "name": log_analytics_preferences_management_items_name,
            "value": log_analytics_preferences_management_items_value,
        }])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/LogAnalytics"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := LogAnalytics.NewLogAnalyticsPreferencesManagement(ctx, "test_log_analytics_preferences_management", &LogAnalytics.LogAnalyticsPreferencesManagementArgs{
    			Namespace: pulumi.Any(logAnalyticsPreferencesManagementNamespace),
    			Items: loganalytics.LogAnalyticsPreferencesManagementItemArray{
    				&loganalytics.LogAnalyticsPreferencesManagementItemArgs{
    					Name:  pulumi.Any(logAnalyticsPreferencesManagementItemsName),
    					Value: pulumi.Any(logAnalyticsPreferencesManagementItemsValue),
    				},
    			},
    		})
    		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 testLogAnalyticsPreferencesManagement = new Oci.LogAnalytics.LogAnalyticsPreferencesManagement("test_log_analytics_preferences_management", new()
        {
            Namespace = logAnalyticsPreferencesManagementNamespace,
            Items = new[]
            {
                new Oci.LogAnalytics.Inputs.LogAnalyticsPreferencesManagementItemArgs
                {
                    Name = logAnalyticsPreferencesManagementItemsName,
                    Value = logAnalyticsPreferencesManagementItemsValue,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.LogAnalytics.LogAnalyticsPreferencesManagement;
    import com.pulumi.oci.LogAnalytics.LogAnalyticsPreferencesManagementArgs;
    import com.pulumi.oci.LogAnalytics.inputs.LogAnalyticsPreferencesManagementItemArgs;
    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) {
            var testLogAnalyticsPreferencesManagement = new LogAnalyticsPreferencesManagement("testLogAnalyticsPreferencesManagement", LogAnalyticsPreferencesManagementArgs.builder()
                .namespace(logAnalyticsPreferencesManagementNamespace)
                .items(LogAnalyticsPreferencesManagementItemArgs.builder()
                    .name(logAnalyticsPreferencesManagementItemsName)
                    .value(logAnalyticsPreferencesManagementItemsValue)
                    .build())
                .build());
    
        }
    }
    
    resources:
      testLogAnalyticsPreferencesManagement:
        type: oci:LogAnalytics:LogAnalyticsPreferencesManagement
        name: test_log_analytics_preferences_management
        properties:
          namespace: ${logAnalyticsPreferencesManagementNamespace}
          items:
            - name: ${logAnalyticsPreferencesManagementItemsName}
              value: ${logAnalyticsPreferencesManagementItemsValue}
    

    Create LogAnalyticsPreferencesManagement Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new LogAnalyticsPreferencesManagement(name: string, args: LogAnalyticsPreferencesManagementArgs, opts?: CustomResourceOptions);
    @overload
    def LogAnalyticsPreferencesManagement(resource_name: str,
                                          args: LogAnalyticsPreferencesManagementArgs,
                                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def LogAnalyticsPreferencesManagement(resource_name: str,
                                          opts: Optional[ResourceOptions] = None,
                                          namespace: Optional[str] = None,
                                          items: Optional[Sequence[_loganalytics.LogAnalyticsPreferencesManagementItemArgs]] = None)
    func NewLogAnalyticsPreferencesManagement(ctx *Context, name string, args LogAnalyticsPreferencesManagementArgs, opts ...ResourceOption) (*LogAnalyticsPreferencesManagement, error)
    public LogAnalyticsPreferencesManagement(string name, LogAnalyticsPreferencesManagementArgs args, CustomResourceOptions? opts = null)
    public LogAnalyticsPreferencesManagement(String name, LogAnalyticsPreferencesManagementArgs args)
    public LogAnalyticsPreferencesManagement(String name, LogAnalyticsPreferencesManagementArgs args, CustomResourceOptions options)
    
    type: oci:LogAnalytics:LogAnalyticsPreferencesManagement
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args LogAnalyticsPreferencesManagementArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args LogAnalyticsPreferencesManagementArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args LogAnalyticsPreferencesManagementArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args LogAnalyticsPreferencesManagementArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args LogAnalyticsPreferencesManagementArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var logAnalyticsPreferencesManagementResource = new Oci.LogAnalytics.LogAnalyticsPreferencesManagement("logAnalyticsPreferencesManagementResource", new()
    {
        Namespace = "string",
        Items = new[]
        {
            new Oci.LogAnalytics.Inputs.LogAnalyticsPreferencesManagementItemArgs
            {
                Name = "string",
                Value = "string",
            },
        },
    });
    
    example, err := LogAnalytics.NewLogAnalyticsPreferencesManagement(ctx, "logAnalyticsPreferencesManagementResource", &LogAnalytics.LogAnalyticsPreferencesManagementArgs{
    	Namespace: pulumi.String("string"),
    	Items: loganalytics.LogAnalyticsPreferencesManagementItemArray{
    		&loganalytics.LogAnalyticsPreferencesManagementItemArgs{
    			Name:  pulumi.String("string"),
    			Value: pulumi.String("string"),
    		},
    	},
    })
    
    var logAnalyticsPreferencesManagementResource = new LogAnalyticsPreferencesManagement("logAnalyticsPreferencesManagementResource", LogAnalyticsPreferencesManagementArgs.builder()
        .namespace("string")
        .items(LogAnalyticsPreferencesManagementItemArgs.builder()
            .name("string")
            .value("string")
            .build())
        .build());
    
    log_analytics_preferences_management_resource = oci.log_analytics.LogAnalyticsPreferencesManagement("logAnalyticsPreferencesManagementResource",
        namespace="string",
        items=[oci.log_analytics.LogAnalyticsPreferencesManagementItemArgs(
            name="string",
            value="string",
        )])
    
    const logAnalyticsPreferencesManagementResource = new oci.loganalytics.LogAnalyticsPreferencesManagement("logAnalyticsPreferencesManagementResource", {
        namespace: "string",
        items: [{
            name: "string",
            value: "string",
        }],
    });
    
    type: oci:LogAnalytics:LogAnalyticsPreferencesManagement
    properties:
        items:
            - name: string
              value: string
        namespace: string
    

    LogAnalyticsPreferencesManagement Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The LogAnalyticsPreferencesManagement resource accepts the following input properties:

    Namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Items List<LogAnalyticsPreferencesManagementItem>
    An array of tenant preference details.
    Namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Items []LogAnalyticsPreferencesManagementItemArgs
    An array of tenant preference details.
    namespace String

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items List<PreferencesManagementItem>
    An array of tenant preference details.
    namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items LogAnalyticsPreferencesManagementItem[]
    An array of tenant preference details.
    namespace str

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items Sequence[loganalytics.LogAnalyticsPreferencesManagementItemArgs]
    An array of tenant preference details.
    namespace String

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items List<Property Map>
    An array of tenant preference details.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the LogAnalyticsPreferencesManagement resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing LogAnalyticsPreferencesManagement Resource

    Get an existing LogAnalyticsPreferencesManagement resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: LogAnalyticsPreferencesManagementState, opts?: CustomResourceOptions): LogAnalyticsPreferencesManagement
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            items: Optional[Sequence[_loganalytics.LogAnalyticsPreferencesManagementItemArgs]] = None,
            namespace: Optional[str] = None) -> LogAnalyticsPreferencesManagement
    func GetLogAnalyticsPreferencesManagement(ctx *Context, name string, id IDInput, state *LogAnalyticsPreferencesManagementState, opts ...ResourceOption) (*LogAnalyticsPreferencesManagement, error)
    public static LogAnalyticsPreferencesManagement Get(string name, Input<string> id, LogAnalyticsPreferencesManagementState? state, CustomResourceOptions? opts = null)
    public static LogAnalyticsPreferencesManagement get(String name, Output<String> id, LogAnalyticsPreferencesManagementState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Items List<LogAnalyticsPreferencesManagementItem>
    An array of tenant preference details.
    Namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Items []LogAnalyticsPreferencesManagementItemArgs
    An array of tenant preference details.
    Namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items List<PreferencesManagementItem>
    An array of tenant preference details.
    namespace String

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items LogAnalyticsPreferencesManagementItem[]
    An array of tenant preference details.
    namespace string

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items Sequence[loganalytics.LogAnalyticsPreferencesManagementItemArgs]
    An array of tenant preference details.
    namespace str

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    items List<Property Map>
    An array of tenant preference details.
    namespace String

    The Logging Analytics namespace used for the request.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Supporting Types

    LogAnalyticsPreferencesManagementItem, LogAnalyticsPreferencesManagementItemArgs

    Name string
    The preference name.
    Value string
    The preference value.
    Name string
    The preference name.
    Value string
    The preference value.
    name String
    The preference name.
    value String
    The preference value.
    name string
    The preference name.
    value string
    The preference value.
    name str
    The preference name.
    value str
    The preference value.
    name String
    The preference name.
    value String
    The preference value.

    Import

    Import is not supported for LogAnalyticsPreferencesManagement

    To learn more about importing existing cloud resources, see Importing resources.

    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 v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi