archive_order
Creates, updates, deletes, gets or lists an archive_order resource.
Overview
| Name | archive_order |
| Type | Resource |
| Id | datadog.logs.archive_order |
Fields
The following fields are returned by SELECT queries:
- get_logs_archive_order
| Name | Datatype | Description |
|---|---|---|
attributes | object | The attributes associated with the archive order. |
type | string | Type of the archive order definition. (archive_order) (default: archive_order, example: archive_order) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_logs_archive_order | select | Get the current order of your archives.<br />This endpoint takes no JSON arguments. | ||
update_logs_archive_order | replace | Update the order of your archives. Since logs are processed sequentially, reordering an archive may change<br />the structure and content of the data processed by other archives.<br /><br />Note: Using the PUT method updates your archive's order by replacing the current order<br />with the new one. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
site | string | The Datadog site (region) for your organization, for example datadoghq.com, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, datadoghq.eu, ddog-gov.com. Resolved from the DD_SITE environment variable when set. Optional: defaults to datadoghq.com, or the value of the DD_SITE environment variable when set; a WHERE value overrides both. |
SELECT examples
- get_logs_archive_order
Get the current order of your archives.<br />This endpoint takes no JSON arguments.
SELECT
attributes,
type
FROM datadog.logs.archive_order
;
REPLACE examples
- update_logs_archive_order
Update the order of your archives. Since logs are processed sequentially, reordering an archive may change<br />the structure and content of the data processed by other archives.<br /><br />Note: Using the PUT method updates your archive's order by replacing the current order<br />with the new one.
REPLACE datadog.logs.archive_order
SET
data = '{{ data }}'
WHERE
RETURNING
data;