By using AWS re:Post, you agree to the Terms of Use

Timestream IOT data ingestion payload format

0

Hi,

My message payload from my iiot device ( Advantech ECU-1251) will not ingest correctly into my timestream database.

The payload looks like this:

{ "state": { "reported": { "FiveMins": 197, "device_id": 9654006.1, "ModStat": 0, "CJC00": 37.3, "Ch00": 37.3,
} } }

In my table the measure_name always = "state" and the measure_value::varchar has all the remaing data in it. measure_value::bigint = blank measure_value::double = blank

I think its because the ECU-1251 curly bracket structure is wrong.

I cannot change the ouput on the ECU-1251.

From the docs I know it should look like this:

{ Measures "temperature": 24.62216675311284, "pressure": 31.381285890765184, "humidity": 1015.2094878981652, ”device_id": "sensor_02", "building": "Day 1", "room": "10.01" }

Is there a way to change the "rule" to parse this format correctly so it can ingest correctly into time stream?

Thanks!

Evguy

1 Answer
0

Hi,

I suggest to use statement like this one in your IoT Rule:

select state.reported.FiveMins as FiveMins, ...

Please also consider following resources

best regards, Andrei

answered 9 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions