Scheduled query error reports - Amazon Timestream

Scheduled query error reports

This section describes the location, format, and reasons for error reports generated by Timestream for LiveAnalytics when errors are encountered by running scheduled queries.

Scheduled query error reports reasons

Error reports are generated for recoverable errors. Error reports are not generated for non-recoverable errors. Timestream for LiveAnalytics can disable the scheduled queries automatically when non-recoverable errors are encountered. These include:

  • AssumeRole failure

  • Any 4xx errors encountered when communicating with KMS when a customer-managed KMS key is specified

  • Any 4xx errors encountered when a scheduled query runs

  • Any 4xx errors encountered during ingestion of query results

For non-recoverable errors, Timestream for LiveAnalytics sends a failure notification with a non-recoverable error message. An update notification is also sent which indicates that the scheduled query is disabled.

Scheduled query error reports location

A scheduled query error report location has the following naming convention:

s3://customer-bucket/customer-prefix/

Following is an example scheduled query ARN:

arn:aws:timestream:us-east-1:000000000000:scheduled-query/test-query-hd734tegrgfd
s3://customer-bucket/customer-prefix/test-query-hd734tegrgfd/<InvocationTime>/<Auto or Manual>/<Actual Trigger Time>

Auto indicates scheduled queries automatically scheduled by Timestream for LiveAnalytics and Manual indicates scheduled queries manually triggered by a user via ExecuteScheduledQuery API action in Amazon Timestream for LiveAnalytics Query. For more information about ExecuteScheduledQuery, see ExecuteScheduledQuery.

Scheduled query error reports format

The error reports have the following JSON format:

{ "reportId": <String>, // A unique string ID for all error reports belonging to a particular scheduled query run "errors": [ <Error>, ... ], // One or more errors }

Scheduled query error types

The Error object can be one of three types:

  • Records Ingestion Errors

    { "reason": <String>, // The error message String "records": [ <Record>, ... ], // One or more rejected records ) }
  • Row Parse and Validation Errors

    { "reason": <String>, // The error message String "rawLine": <String>, // [Optional] The raw line String that is being parsed into record(s) to be ingested. This line has encountered the above-mentioned parse error. }
  • General Errors

    { "reason": <String>, // The error message }

Scheduled query error reports example

The following is an example of an error report that was produced due to ingestion errors.

{ "reportId": "C9494AABE012D1FBC162A67EA2C18255", "errors": [ { "reason": "The record timestamp is outside the time range [2021-11-12T14:18:13.354Z, 2021-11-12T16:58:13.354Z) of the memory store.", "records": [ { "dimensions": [ { "name": "dim0", "value": "d0_1", "dimensionValueType": null }, { "name": "dim1", "value": "d1_1", "dimensionValueType": null } ], "measureName": "random_measure_value", "measureValue": "3.141592653589793", "measureValues": null, "measureValueType": "DOUBLE", "time": "1637166175635000000", "timeUnit": "NANOSECONDS", "version": null }, { "dimensions": [ { "name": "dim0", "value": "d0_2", "dimensionValueType": null }, { "name": "dim1", "value": "d1_2", "dimensionValueType": null } ], "measureName": "random_measure_value", "measureValue": "6.283185307179586", "measureValues": null, "measureValueType": "DOUBLE", "time": "1637166175636000000", "timeUnit": "NANOSECONDS", "version": null }, { "dimensions": [ { "name": "dim0", "value": "d0_3", "dimensionValueType": null }, { "name": "dim1", "value": "d1_3", "dimensionValueType": null } ], "measureName": "random_measure_value", "measureValue": "9.42477796076938", "measureValues": null, "measureValueType": "DOUBLE", "time": "1637166175637000000", "timeUnit": "NANOSECONDS", "version": null }, { "dimensions": [ { "name": "dim0", "value": "d0_4", "dimensionValueType": null }, { "name": "dim1", "value": "d1_4", "dimensionValueType": null } ], "measureName": "random_measure_value", "measureValue": "12.566370614359172", "measureValues": null, "measureValueType": "DOUBLE", "time": "1637166175638000000", "timeUnit": "NANOSECONDS", "version": null } ] } ] }