@pulumi/sumologic
Version:
A Pulumi package for creating and managing sumologic cloud resources.
175 lines (174 loc) • 8.66 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides a [Sumologic Scheduled View](https://help.sumologic.com/Manage/Scheduled-Views).
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as sumologic from "@pulumi/sumologic";
*
* const failedConnections = new sumologic.ScheduledView("failed_connections", {
* indexName: "failed_connections",
* query: `_view=connections connectionStats
* | parse "connectionStats.CS *" as body
* | json field=body "exitCode", "isHttp2"
* | lookup org_name from shared/partners on partner_id=partnerid
* | timeslice 10m
* `,
* startTime: "2019-09-01T00:00:00Z",
* retentionPeriod: 365,
* });
* ```
*
* ## Import
*
* Scheduled Views can can be imported using the id. The list of scheduled views and their ids can be obtained using the Sumologic [scheduled views api][2].
*
* hcl
*
* ```sh
* $ pulumi import sumologic:index/scheduledView:ScheduledView failed_connections 1234567890
* ```
*
* [1]: https://help.sumologic.com/Manage/Scheduled-Views
*
* [2]: https://api.sumologic.com/docs/#operation/listScheduledViews
*/
export declare class ScheduledView extends pulumi.CustomResource {
/**
* Get an existing ScheduledView 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<pulumi.ID>, state?: ScheduledViewState, opts?: pulumi.CustomResourceOptions): ScheduledView;
/**
* Returns true if the given object is an instance of ScheduledView. 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 ScheduledView;
/**
* An optional ID of a data forwarding configuration to be used by the scheduled view.
*/
readonly dataForwardingId: pulumi.Output<string | undefined>;
/**
* The Index ID of the scheduled view. It remains unchanged during resource updates, and any manual modifications will be disregarded. While it’s not mandatory, we recommend to ignore this via `ignoreChanges = [indexId]`.
*/
readonly indexId: pulumi.Output<string>;
/**
* Name of the index (scheduled view).
*/
readonly indexName: pulumi.Output<string>;
/**
* Default to `Manual`. Define the parsing mode to scan the JSON format log messages. Possible values are: `AutoParse` - In AutoParse mode, the system automatically figures out fields to parse based on the search query. `Manual` - While in the Manual mode, no fields are parsed out automatically. For more information see Dynamic Parsing.
*/
readonly parsingMode: pulumi.Output<string | undefined>;
/**
* Log query defining the scheduled view.
*/
readonly query: pulumi.Output<string>;
/**
* This is required on update if the newly specified retention period is less than the existing retention period. In such a situation, a value of true says that data between the existing retention period and the new retention period should be deleted immediately; if false, such data will be deleted after seven days. This property is optional and ignored if the specified retentionPeriod is greater than or equal to the current retention period.
*
* The following attributes are exported:
*/
readonly reduceRetentionPeriodImmediately: pulumi.Output<boolean | undefined>;
/**
* The number of days to retain data in the scheduled view, or -1 to use the default value for your account. Only relevant if your account has multi-retention. enabled.
*/
readonly retentionPeriod: pulumi.Output<number | undefined>;
/**
* Start timestamp in UTC in RFC3339 format.
*/
readonly startTime: pulumi.Output<string>;
/**
* Create a ScheduledView 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: ScheduledViewArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering ScheduledView resources.
*/
export interface ScheduledViewState {
/**
* An optional ID of a data forwarding configuration to be used by the scheduled view.
*/
dataForwardingId?: pulumi.Input<string>;
/**
* The Index ID of the scheduled view. It remains unchanged during resource updates, and any manual modifications will be disregarded. While it’s not mandatory, we recommend to ignore this via `ignoreChanges = [indexId]`.
*/
indexId?: pulumi.Input<string>;
/**
* Name of the index (scheduled view).
*/
indexName?: pulumi.Input<string>;
/**
* Default to `Manual`. Define the parsing mode to scan the JSON format log messages. Possible values are: `AutoParse` - In AutoParse mode, the system automatically figures out fields to parse based on the search query. `Manual` - While in the Manual mode, no fields are parsed out automatically. For more information see Dynamic Parsing.
*/
parsingMode?: pulumi.Input<string>;
/**
* Log query defining the scheduled view.
*/
query?: pulumi.Input<string>;
/**
* This is required on update if the newly specified retention period is less than the existing retention period. In such a situation, a value of true says that data between the existing retention period and the new retention period should be deleted immediately; if false, such data will be deleted after seven days. This property is optional and ignored if the specified retentionPeriod is greater than or equal to the current retention period.
*
* The following attributes are exported:
*/
reduceRetentionPeriodImmediately?: pulumi.Input<boolean>;
/**
* The number of days to retain data in the scheduled view, or -1 to use the default value for your account. Only relevant if your account has multi-retention. enabled.
*/
retentionPeriod?: pulumi.Input<number>;
/**
* Start timestamp in UTC in RFC3339 format.
*/
startTime?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a ScheduledView resource.
*/
export interface ScheduledViewArgs {
/**
* An optional ID of a data forwarding configuration to be used by the scheduled view.
*/
dataForwardingId?: pulumi.Input<string>;
/**
* The Index ID of the scheduled view. It remains unchanged during resource updates, and any manual modifications will be disregarded. While it’s not mandatory, we recommend to ignore this via `ignoreChanges = [indexId]`.
*/
indexId?: pulumi.Input<string>;
/**
* Name of the index (scheduled view).
*/
indexName: pulumi.Input<string>;
/**
* Default to `Manual`. Define the parsing mode to scan the JSON format log messages. Possible values are: `AutoParse` - In AutoParse mode, the system automatically figures out fields to parse based on the search query. `Manual` - While in the Manual mode, no fields are parsed out automatically. For more information see Dynamic Parsing.
*/
parsingMode?: pulumi.Input<string>;
/**
* Log query defining the scheduled view.
*/
query: pulumi.Input<string>;
/**
* This is required on update if the newly specified retention period is less than the existing retention period. In such a situation, a value of true says that data between the existing retention period and the new retention period should be deleted immediately; if false, such data will be deleted after seven days. This property is optional and ignored if the specified retentionPeriod is greater than or equal to the current retention period.
*
* The following attributes are exported:
*/
reduceRetentionPeriodImmediately?: pulumi.Input<boolean>;
/**
* The number of days to retain data in the scheduled view, or -1 to use the default value for your account. Only relevant if your account has multi-retention. enabled.
*/
retentionPeriod?: pulumi.Input<number>;
/**
* Start timestamp in UTC in RFC3339 format.
*/
startTime: pulumi.Input<string>;
}