import * as pulumi from "@pulumi/pulumi"; /** * Manages a Table in a Log Analytics (formally Operational Insights) Workspace. * * > **Note:** This resource does not create or destroy tables. This resource is used to update attributes (currently only retention_in_days) of the tables created when a Log Analytics Workspace is created. Deleting an azure.loganalytics.WorkspaceTable resource will not delete the table. Instead, the table's retentionInDays field will be set to the value of azure.operationalinsights.AnalyticsWorkspace retention_in_days * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "West Europe", * }); * const exampleAnalyticsWorkspace = new azure.operationalinsights.AnalyticsWorkspace("example", { * name: "example", * location: example.location, * resourceGroupName: example.name, * sku: "PerGB2018", * retentionInDays: 30, * }); * const exampleWorkspaceTable = new azure.loganalytics.WorkspaceTable("example", { * workspaceId: exampleAnalyticsWorkspace.id, * name: "AppMetrics", * retentionInDays: 60, * totalRetentionInDays: 180, * }); * ``` * * ## API Providers * * * This resource uses the following Azure API Providers: * * * `Microsoft.OperationalInsights` - 2022-10-01 */ export declare class WorkspaceTable extends pulumi.CustomResource { /** * Get an existing WorkspaceTable resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: WorkspaceTableState, opts?: pulumi.CustomResourceOptions): WorkspaceTable; /** * Returns true if the given object is an instance of WorkspaceTable. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is WorkspaceTable; /** * Specifies the name of a table in a Log Analytics Workspace. */ readonly name: pulumi.Output; /** * Specify the system how to handle and charge the logs ingested to the table. Possible values are `Analytics` and `Basic`. Defaults to `Analytics`. * * > **Note:** The `name` of tables currently supported by the `Basic` plan can be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/basic-logs-azure-tables). */ readonly plan: pulumi.Output; /** * The table's retention in days. Possible values are between `4` and `730`. * * > **Note:** The `retentionInDays` is fixed to `30` when `plan` is `Basic`. More details could be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/data-retention-configure?tabs=portal%2Cportal-1#analytics-long-term-and-total-retention). */ readonly retentionInDays: pulumi.Output; /** * The table's total retention in days. Possible values range between `4` and `730`; or `1095`, `1460`, `1826`, `2191`, `2556`, `2922`, `3288`, `3653`, `4018`, or `4383`. * * > **Note:** `retentionInDays` and `totalRetentionInDays` will revert back to the value of azure.operationalinsights.AnalyticsWorkspace retention_in_days when a azure.loganalytics.WorkspaceTable is deleted. * * > **Note:** The `retentionInDays` cannot be specified when `plan` is `Basic` because the retention is fixed at eight days. */ readonly totalRetentionInDays: pulumi.Output; /** * The object ID of the Log Analytics Workspace that contains the table. */ readonly workspaceId: pulumi.Output; /** * Create a WorkspaceTable resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: WorkspaceTableArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering WorkspaceTable resources. */ export interface WorkspaceTableState { /** * Specifies the name of a table in a Log Analytics Workspace. */ name?: pulumi.Input; /** * Specify the system how to handle and charge the logs ingested to the table. Possible values are `Analytics` and `Basic`. Defaults to `Analytics`. * * > **Note:** The `name` of tables currently supported by the `Basic` plan can be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/basic-logs-azure-tables). */ plan?: pulumi.Input; /** * The table's retention in days. Possible values are between `4` and `730`. * * > **Note:** The `retentionInDays` is fixed to `30` when `plan` is `Basic`. More details could be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/data-retention-configure?tabs=portal%2Cportal-1#analytics-long-term-and-total-retention). */ retentionInDays?: pulumi.Input; /** * The table's total retention in days. Possible values range between `4` and `730`; or `1095`, `1460`, `1826`, `2191`, `2556`, `2922`, `3288`, `3653`, `4018`, or `4383`. * * > **Note:** `retentionInDays` and `totalRetentionInDays` will revert back to the value of azure.operationalinsights.AnalyticsWorkspace retention_in_days when a azure.loganalytics.WorkspaceTable is deleted. * * > **Note:** The `retentionInDays` cannot be specified when `plan` is `Basic` because the retention is fixed at eight days. */ totalRetentionInDays?: pulumi.Input; /** * The object ID of the Log Analytics Workspace that contains the table. */ workspaceId?: pulumi.Input; } /** * The set of arguments for constructing a WorkspaceTable resource. */ export interface WorkspaceTableArgs { /** * Specifies the name of a table in a Log Analytics Workspace. */ name?: pulumi.Input; /** * Specify the system how to handle and charge the logs ingested to the table. Possible values are `Analytics` and `Basic`. Defaults to `Analytics`. * * > **Note:** The `name` of tables currently supported by the `Basic` plan can be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/basic-logs-azure-tables). */ plan?: pulumi.Input; /** * The table's retention in days. Possible values are between `4` and `730`. * * > **Note:** The `retentionInDays` is fixed to `30` when `plan` is `Basic`. More details could be found [here](https://learn.microsoft.com/en-us/azure/azure-monitor/logs/data-retention-configure?tabs=portal%2Cportal-1#analytics-long-term-and-total-retention). */ retentionInDays?: pulumi.Input; /** * The table's total retention in days. Possible values range between `4` and `730`; or `1095`, `1460`, `1826`, `2191`, `2556`, `2922`, `3288`, `3653`, `4018`, or `4383`. * * > **Note:** `retentionInDays` and `totalRetentionInDays` will revert back to the value of azure.operationalinsights.AnalyticsWorkspace retention_in_days when a azure.loganalytics.WorkspaceTable is deleted. * * > **Note:** The `retentionInDays` cannot be specified when `plan` is `Basic` because the retention is fixed at eight days. */ totalRetentionInDays?: pulumi.Input; /** * The object ID of the Log Analytics Workspace that contains the table. */ workspaceId: pulumi.Input; }