1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Logging
  5. Log
Oracle Cloud Infrastructure v1.27.0 published on Friday, Mar 15, 2024 by Pulumi

oci.Logging.Log

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v1.27.0 published on Friday, Mar 15, 2024 by Pulumi

    This resource provides the Log resource in Oracle Cloud Infrastructure Logging service.

    Creates a log within the specified log group. This call fails if a log group has already been created with the same displayName or (service, resource, category) triplet.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testLog = new oci.logging.Log("testLog", {
        displayName: _var.log_display_name,
        logGroupId: oci_logging_log_group.test_log_group.id,
        logType: _var.log_log_type,
        configuration: {
            source: {
                category: _var.log_configuration_source_category,
                resource: _var.log_configuration_source_resource,
                service: _var.log_configuration_source_service,
                sourceType: _var.log_configuration_source_source_type,
                parameters: _var.log_configuration_source_parameters,
            },
            compartmentId: _var.compartment_id,
        },
        definedTags: {
            "Operations.CostCenter": "42",
        },
        freeformTags: {
            Department: "Finance",
        },
        isEnabled: _var.log_is_enabled,
        retentionDuration: _var.log_retention_duration,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_log = oci.logging.Log("testLog",
        display_name=var["log_display_name"],
        log_group_id=oci_logging_log_group["test_log_group"]["id"],
        log_type=var["log_log_type"],
        configuration=oci.logging.LogConfigurationArgs(
            source=oci.logging.LogConfigurationSourceArgs(
                category=var["log_configuration_source_category"],
                resource=var["log_configuration_source_resource"],
                service=var["log_configuration_source_service"],
                source_type=var["log_configuration_source_source_type"],
                parameters=var["log_configuration_source_parameters"],
            ),
            compartment_id=var["compartment_id"],
        ),
        defined_tags={
            "Operations.CostCenter": "42",
        },
        freeform_tags={
            "Department": "Finance",
        },
        is_enabled=var["log_is_enabled"],
        retention_duration=var["log_retention_duration"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/go/oci/Logging"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Logging.NewLog(ctx, "testLog", &Logging.LogArgs{
    			DisplayName: pulumi.Any(_var.Log_display_name),
    			LogGroupId:  pulumi.Any(oci_logging_log_group.Test_log_group.Id),
    			LogType:     pulumi.Any(_var.Log_log_type),
    			Configuration: &logging.LogConfigurationArgs{
    				Source: &logging.LogConfigurationSourceArgs{
    					Category:   pulumi.Any(_var.Log_configuration_source_category),
    					Resource:   pulumi.Any(_var.Log_configuration_source_resource),
    					Service:    pulumi.Any(_var.Log_configuration_source_service),
    					SourceType: pulumi.Any(_var.Log_configuration_source_source_type),
    					Parameters: pulumi.Any(_var.Log_configuration_source_parameters),
    				},
    				CompartmentId: pulumi.Any(_var.Compartment_id),
    			},
    			DefinedTags: pulumi.Map{
    				"Operations.CostCenter": pulumi.Any("42"),
    			},
    			FreeformTags: pulumi.Map{
    				"Department": pulumi.Any("Finance"),
    			},
    			IsEnabled:         pulumi.Any(_var.Log_is_enabled),
    			RetentionDuration: pulumi.Any(_var.Log_retention_duration),
    		})
    		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 testLog = new Oci.Logging.Log("testLog", new()
        {
            DisplayName = @var.Log_display_name,
            LogGroupId = oci_logging_log_group.Test_log_group.Id,
            LogType = @var.Log_log_type,
            Configuration = new Oci.Logging.Inputs.LogConfigurationArgs
            {
                Source = new Oci.Logging.Inputs.LogConfigurationSourceArgs
                {
                    Category = @var.Log_configuration_source_category,
                    Resource = @var.Log_configuration_source_resource,
                    Service = @var.Log_configuration_source_service,
                    SourceType = @var.Log_configuration_source_source_type,
                    Parameters = @var.Log_configuration_source_parameters,
                },
                CompartmentId = @var.Compartment_id,
            },
            DefinedTags = 
            {
                { "Operations.CostCenter", "42" },
            },
            FreeformTags = 
            {
                { "Department", "Finance" },
            },
            IsEnabled = @var.Log_is_enabled,
            RetentionDuration = @var.Log_retention_duration,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Logging.Log;
    import com.pulumi.oci.Logging.LogArgs;
    import com.pulumi.oci.Logging.inputs.LogConfigurationArgs;
    import com.pulumi.oci.Logging.inputs.LogConfigurationSourceArgs;
    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 testLog = new Log("testLog", LogArgs.builder()        
                .displayName(var_.log_display_name())
                .logGroupId(oci_logging_log_group.test_log_group().id())
                .logType(var_.log_log_type())
                .configuration(LogConfigurationArgs.builder()
                    .source(LogConfigurationSourceArgs.builder()
                        .category(var_.log_configuration_source_category())
                        .resource(var_.log_configuration_source_resource())
                        .service(var_.log_configuration_source_service())
                        .sourceType(var_.log_configuration_source_source_type())
                        .parameters(var_.log_configuration_source_parameters())
                        .build())
                    .compartmentId(var_.compartment_id())
                    .build())
                .definedTags(Map.of("Operations.CostCenter", "42"))
                .freeformTags(Map.of("Department", "Finance"))
                .isEnabled(var_.log_is_enabled())
                .retentionDuration(var_.log_retention_duration())
                .build());
    
        }
    }
    
    resources:
      testLog:
        type: oci:Logging:Log
        properties:
          #Required
          displayName: ${var.log_display_name}
          logGroupId: ${oci_logging_log_group.test_log_group.id}
          logType: ${var.log_log_type}
          configuration:
            source:
              category: ${var.log_configuration_source_category}
              resource: ${var.log_configuration_source_resource}
              service: ${var.log_configuration_source_service}
              sourceType: ${var.log_configuration_source_source_type}
              parameters: ${var.log_configuration_source_parameters}
            compartmentId: ${var.compartment_id}
          definedTags:
            Operations.CostCenter: '42'
          freeformTags:
            Department: Finance
          isEnabled: ${var.log_is_enabled}
          retentionDuration: ${var.log_retention_duration}
    

    Create Log Resource

    new Log(name: string, args: LogArgs, opts?: CustomResourceOptions);
    @overload
    def Log(resource_name: str,
            opts: Optional[ResourceOptions] = None,
            configuration: Optional[_logging.LogConfigurationArgs] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            display_name: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            is_enabled: Optional[bool] = None,
            log_group_id: Optional[str] = None,
            log_type: Optional[str] = None,
            retention_duration: Optional[int] = None)
    @overload
    def Log(resource_name: str,
            args: LogArgs,
            opts: Optional[ResourceOptions] = None)
    func NewLog(ctx *Context, name string, args LogArgs, opts ...ResourceOption) (*Log, error)
    public Log(string name, LogArgs args, CustomResourceOptions? opts = null)
    public Log(String name, LogArgs args)
    public Log(String name, LogArgs args, CustomResourceOptions options)
    
    type: oci:Logging:Log
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args LogArgs
    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 LogArgs
    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 LogArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args LogArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args LogArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Log 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 Log resource accepts the following input properties:

    DisplayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    LogGroupId string
    (Updatable) OCID of a log group to work with.
    LogType string
    The logType that the log object is for, whether custom or service.
    Configuration LogConfiguration
    Log object configuration.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    FreeformTags Dictionary<string, object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    IsEnabled bool
    (Updatable) Whether or not this resource is currently enabled.
    RetentionDuration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    DisplayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    LogGroupId string
    (Updatable) OCID of a log group to work with.
    LogType string
    The logType that the log object is for, whether custom or service.
    Configuration LogConfigurationArgs
    Log object configuration.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    FreeformTags map[string]interface{}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    IsEnabled bool
    (Updatable) Whether or not this resource is currently enabled.
    RetentionDuration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    displayName String
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    logGroupId String
    (Updatable) OCID of a log group to work with.
    logType String
    The logType that the log object is for, whether custom or service.
    configuration LogConfiguration
    Log object configuration.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    freeformTags Map<String,Object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled Boolean
    (Updatable) Whether or not this resource is currently enabled.
    retentionDuration Integer

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    displayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    logGroupId string
    (Updatable) OCID of a log group to work with.
    logType string
    The logType that the log object is for, whether custom or service.
    configuration LogConfiguration
    Log object configuration.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    freeformTags {[key: string]: any}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled boolean
    (Updatable) Whether or not this resource is currently enabled.
    retentionDuration number

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    display_name str
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    log_group_id str
    (Updatable) OCID of a log group to work with.
    log_type str
    The logType that the log object is for, whether custom or service.
    configuration LogConfigurationArgs
    Log object configuration.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    freeform_tags Mapping[str, Any]
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    is_enabled bool
    (Updatable) Whether or not this resource is currently enabled.
    retention_duration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    displayName String
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    logGroupId String
    (Updatable) OCID of a log group to work with.
    logType String
    The logType that the log object is for, whether custom or service.
    configuration Property Map
    Log object configuration.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    freeformTags Map<Any>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled Boolean
    (Updatable) Whether or not this resource is currently enabled.
    retentionDuration Number

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    Outputs

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

    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The pipeline state.
    TenancyId string
    The OCID of the tenancy.
    TimeCreated string
    Time the resource was created.
    TimeLastModified string
    Time the resource was last modified.
    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    Id string
    The provider-assigned unique ID for this managed resource.
    State string
    The pipeline state.
    TenancyId string
    The OCID of the tenancy.
    TimeCreated string
    Time the resource was created.
    TimeLastModified string
    Time the resource was last modified.
    compartmentId String
    The OCID of the compartment that the resource belongs to.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The pipeline state.
    tenancyId String
    The OCID of the tenancy.
    timeCreated String
    Time the resource was created.
    timeLastModified String
    Time the resource was last modified.
    compartmentId string
    The OCID of the compartment that the resource belongs to.
    id string
    The provider-assigned unique ID for this managed resource.
    state string
    The pipeline state.
    tenancyId string
    The OCID of the tenancy.
    timeCreated string
    Time the resource was created.
    timeLastModified string
    Time the resource was last modified.
    compartment_id str
    The OCID of the compartment that the resource belongs to.
    id str
    The provider-assigned unique ID for this managed resource.
    state str
    The pipeline state.
    tenancy_id str
    The OCID of the tenancy.
    time_created str
    Time the resource was created.
    time_last_modified str
    Time the resource was last modified.
    compartmentId String
    The OCID of the compartment that the resource belongs to.
    id String
    The provider-assigned unique ID for this managed resource.
    state String
    The pipeline state.
    tenancyId String
    The OCID of the tenancy.
    timeCreated String
    Time the resource was created.
    timeLastModified String
    Time the resource was last modified.

    Look up Existing Log Resource

    Get an existing Log 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?: LogState, opts?: CustomResourceOptions): Log
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            compartment_id: Optional[str] = None,
            configuration: Optional[_logging.LogConfigurationArgs] = None,
            defined_tags: Optional[Mapping[str, Any]] = None,
            display_name: Optional[str] = None,
            freeform_tags: Optional[Mapping[str, Any]] = None,
            is_enabled: Optional[bool] = None,
            log_group_id: Optional[str] = None,
            log_type: Optional[str] = None,
            retention_duration: Optional[int] = None,
            state: Optional[str] = None,
            tenancy_id: Optional[str] = None,
            time_created: Optional[str] = None,
            time_last_modified: Optional[str] = None) -> Log
    func GetLog(ctx *Context, name string, id IDInput, state *LogState, opts ...ResourceOption) (*Log, error)
    public static Log Get(string name, Input<string> id, LogState? state, CustomResourceOptions? opts = null)
    public static Log get(String name, Output<String> id, LogState 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:
    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    Configuration LogConfiguration
    Log object configuration.
    DefinedTags Dictionary<string, object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    FreeformTags Dictionary<string, object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    IsEnabled bool
    (Updatable) Whether or not this resource is currently enabled.
    LogGroupId string
    (Updatable) OCID of a log group to work with.
    LogType string
    The logType that the log object is for, whether custom or service.
    RetentionDuration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    State string
    The pipeline state.
    TenancyId string
    The OCID of the tenancy.
    TimeCreated string
    Time the resource was created.
    TimeLastModified string
    Time the resource was last modified.
    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    Configuration LogConfigurationArgs
    Log object configuration.
    DefinedTags map[string]interface{}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    DisplayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    FreeformTags map[string]interface{}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    IsEnabled bool
    (Updatable) Whether or not this resource is currently enabled.
    LogGroupId string
    (Updatable) OCID of a log group to work with.
    LogType string
    The logType that the log object is for, whether custom or service.
    RetentionDuration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    State string
    The pipeline state.
    TenancyId string
    The OCID of the tenancy.
    TimeCreated string
    Time the resource was created.
    TimeLastModified string
    Time the resource was last modified.
    compartmentId String
    The OCID of the compartment that the resource belongs to.
    configuration LogConfiguration
    Log object configuration.
    definedTags Map<String,Object>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    freeformTags Map<String,Object>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled Boolean
    (Updatable) Whether or not this resource is currently enabled.
    logGroupId String
    (Updatable) OCID of a log group to work with.
    logType String
    The logType that the log object is for, whether custom or service.
    retentionDuration Integer

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    state String
    The pipeline state.
    tenancyId String
    The OCID of the tenancy.
    timeCreated String
    Time the resource was created.
    timeLastModified String
    Time the resource was last modified.
    compartmentId string
    The OCID of the compartment that the resource belongs to.
    configuration LogConfiguration
    Log object configuration.
    definedTags {[key: string]: any}
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName string
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    freeformTags {[key: string]: any}
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled boolean
    (Updatable) Whether or not this resource is currently enabled.
    logGroupId string
    (Updatable) OCID of a log group to work with.
    logType string
    The logType that the log object is for, whether custom or service.
    retentionDuration number

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    state string
    The pipeline state.
    tenancyId string
    The OCID of the tenancy.
    timeCreated string
    Time the resource was created.
    timeLastModified string
    Time the resource was last modified.
    compartment_id str
    The OCID of the compartment that the resource belongs to.
    configuration LogConfigurationArgs
    Log object configuration.
    defined_tags Mapping[str, Any]
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    display_name str
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    freeform_tags Mapping[str, Any]
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    is_enabled bool
    (Updatable) Whether or not this resource is currently enabled.
    log_group_id str
    (Updatable) OCID of a log group to work with.
    log_type str
    The logType that the log object is for, whether custom or service.
    retention_duration int

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    state str
    The pipeline state.
    tenancy_id str
    The OCID of the tenancy.
    time_created str
    Time the resource was created.
    time_last_modified str
    Time the resource was last modified.
    compartmentId String
    The OCID of the compartment that the resource belongs to.
    configuration Property Map
    Log object configuration.
    definedTags Map<Any>
    (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
    displayName String
    (Updatable) The user-friendly display name. This must be unique within the enclosing resource, and it's changeable. Avoid entering confidential information.
    freeformTags Map<Any>
    (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
    isEnabled Boolean
    (Updatable) Whether or not this resource is currently enabled.
    logGroupId String
    (Updatable) OCID of a log group to work with.
    logType String
    The logType that the log object is for, whether custom or service.
    retentionDuration Number

    (Updatable) Log retention duration in 30-day increments (30, 60, 90 and so on until 180).

    ** 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

    state String
    The pipeline state.
    tenancyId String
    The OCID of the tenancy.
    timeCreated String
    Time the resource was created.
    timeLastModified String
    Time the resource was last modified.

    Supporting Types

    LogConfiguration, LogConfigurationArgs

    Source LogConfigurationSource
    The source the log object comes from.
    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    Source LogConfigurationSource
    The source the log object comes from.
    CompartmentId string
    The OCID of the compartment that the resource belongs to.
    source LogConfigurationSource
    The source the log object comes from.
    compartmentId String
    The OCID of the compartment that the resource belongs to.
    source LogConfigurationSource
    The source the log object comes from.
    compartmentId string
    The OCID of the compartment that the resource belongs to.
    source LogConfigurationSource
    The source the log object comes from.
    compartment_id str
    The OCID of the compartment that the resource belongs to.
    source Property Map
    The source the log object comes from.
    compartmentId String
    The OCID of the compartment that the resource belongs to.

    LogConfigurationSource, LogConfigurationSourceArgs

    Category string
    Log object category.
    Resource string
    The unique identifier of the resource emitting the log.
    Service string
    Service generating log.
    SourceType string
    The log source.

    • OCISERVICE: Oracle Service.
    Parameters Dictionary<string, object>
    (Updatable) Log category parameters are stored here.
    Category string
    Log object category.
    Resource string
    The unique identifier of the resource emitting the log.
    Service string
    Service generating log.
    SourceType string
    The log source.

    • OCISERVICE: Oracle Service.
    Parameters map[string]interface{}
    (Updatable) Log category parameters are stored here.
    category String
    Log object category.
    resource String
    The unique identifier of the resource emitting the log.
    service String
    Service generating log.
    sourceType String
    The log source.

    • OCISERVICE: Oracle Service.
    parameters Map<String,Object>
    (Updatable) Log category parameters are stored here.
    category string
    Log object category.
    resource string
    The unique identifier of the resource emitting the log.
    service string
    Service generating log.
    sourceType string
    The log source.

    • OCISERVICE: Oracle Service.
    parameters {[key: string]: any}
    (Updatable) Log category parameters are stored here.
    category str
    Log object category.
    resource str
    The unique identifier of the resource emitting the log.
    service str
    Service generating log.
    source_type str
    The log source.

    • OCISERVICE: Oracle Service.
    parameters Mapping[str, Any]
    (Updatable) Log category parameters are stored here.
    category String
    Log object category.
    resource String
    The unique identifier of the resource emitting the log.
    service String
    Service generating log.
    sourceType String
    The log source.

    • OCISERVICE: Oracle Service.
    parameters Map<Any>
    (Updatable) Log category parameters are stored here.

    Import

    Logs can be imported using the id, e.g.

    $ pulumi import oci:Logging/log:Log test_log "logGroupId/{logGroupId}/logId/{logId}"
    

    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.27.0 published on Friday, Mar 15, 2024 by Pulumi