sammyF
sammyF

Reputation: 11

Writing data to AWS timestream table using IOT - timestamp not working

I am trying to use iot core rules to define an action which will send a JSON object to a timestream table. the object looks like this:

{ "Time": 1483715700000, "TimeUnit": "MILLISECONDS", "endpointID": "ahu3", "Introduction_temperature": 15.8 }

the sql query:

SELECT Introduction_temperature FROM topic

I want to use the timestamp in the object:(Defined in the rule)

Value: ${Time} Unit: MILLISECOND

when I try to use my timestamp, nothing gets ingested into the table! it only works if I don't use my timestamp. has anyone encountered this issue before? thanks

Upvotes: 0

Views: 1166

Answers (1)

sammyF
sammyF

Reputation: 11

After consulting with AWS on the matter, it seems that you cannot send an object with a timestamp dating from before your retention period - therefore, since the retention period for the ingestion storage is up to 12 months, you cannot send in anything with a timestamp older than 12 months. What I ended up having to do was change the year, and for some the timestamps, the month as well, and that solved the issue.

Upvotes: 1

Related Questions