diff --git a/website/docs/r/data_forwarding_destination.html.markdown b/website/docs/r/data_forwarding_destination.html.markdown index ddd76bbd..c9b6ef35 100644 --- a/website/docs/r/data_forwarding_destination.html.markdown +++ b/website/docs/r/data_forwarding_destination.html.markdown @@ -19,8 +19,8 @@ resource "sumologic_data_forwarding_destination" "example_data_forwarding_destin access_key_id = "accessKeyId" secret_access_key = "secretAccessKey" role_arn = "arn:aws:iam::some-valid-arn" - encrypted = "false" - enabled = "true" + encrypted = false + enabled = true } ``` ## Argument reference diff --git a/website/docs/r/data_forwarding_rule.html.markdown b/website/docs/r/data_forwarding_rule.html.markdown index 62ee7ae5..d0ecead6 100644 --- a/website/docs/r/data_forwarding_rule.html.markdown +++ b/website/docs/r/data_forwarding_rule.html.markdown @@ -9,14 +9,38 @@ description: |- Provider to manage [Sumologic Data Forwarding Rule](https://help.sumologic.com/docs/manage/data-forwarding/amazon-s3-bucket/#forward-datato-s3) ## Example Usage + +For Partitions ```hcl resource "sumologic_data_forwarding_rule" "example_data_forwarding_rule" { - index_id = "00000000024C6155" - destination_id = "00000000000732AA" - enabled = "true" - file_format = "test/{index}/{day}/{hour}/{minute}" - payload_schema = "builtInFields" - format = "json" + index_id = sumologic_partition.test_partition.id + destination_id = "00000000000732AA" + enabled = true + file_format = "test/{index}/{day}/{hour}/{minute}" + payload_schema = "builtInFields" + format = "json" +} +``` +For Scheduled Views +```hcl +resource "sumologic_scheduled_view" "failed_connections" { + index_name = "failed_connections" + query = "_sourceCategory=fire | count" + start_time = "2024-09-01T00:00:00Z" + retention_period = 1 + lifecycle { + prevent_destroy = true + ignore_changes = [index_id] + } +} + +resource "sumologic_data_forwarding_rule" "test_rule_sv" { + index_id = sumologic_scheduled_view.failed_connections.index_id + destination_id = sumologic_data_forwarding_destination.test_destination.id + enabled = false + file_format = "test/{index}" + payload_schema = "raw" + format = "text" } ``` ## Argument reference @@ -31,3 +55,7 @@ The following arguments are supported: _raw_ payloadSchema should be used in conjunction with _text_ format and vice versa. - `format` - (Optional) Format of the payload. Default format will be _csv_. _text_ format should be used in conjunction with _raw_ payloadSchema and vice versa. + +The following attributes are exported: + +- `id` - The Index ID of the data_forwarding_rule \ No newline at end of file diff --git a/website/docs/r/scheduled_view.html.markdown b/website/docs/r/scheduled_view.html.markdown index 8c5f3f9d..df0fef63 100644 --- a/website/docs/r/scheduled_view.html.markdown +++ b/website/docs/r/scheduled_view.html.markdown @@ -23,6 +23,7 @@ QUERY retention_period = 365 lifecycle { prevent_destroy = true + ignore_changes = [index_id] } } ``` @@ -44,7 +45,7 @@ The following arguments are supported: The following attributes are exported: - `id` - The internal ID of the scheduled view. -- `index_id` - The Index ID of the scheduled view. +- `index_id` - The Index ID of the scheduled view. It never updates at any point of time during resource updates, therefore make sure to ignore this via `ignore_changes = [index_id]`. ## 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].