Home › Forums › Mayfly Data Logger › Response code 504 from data.envirodiy.org › Reply To: Response code 504 from data.envirodiy.org
I ran another test overnight, again using a 2 minute sampling interval, with no code changes, but I removed the build flags for modem debugging from the platformio.ini. Here are the results
I ran another test overnight, again using a 2 minute sampling interval, with no code changes, but I removed the build flags for modem debugging from the platformio.ini. Here are the results:
- 427 total samples taken
- 52 sample events received a Response Code 504.
- 246 sample events received a Response Code 201.
- 155 of the samples are absent from the MMW database.
The new wrinkle here is that sometimes the Mayfly apparently didn’t attempt to send to MMW; this happened 129 times. In the log file, one of these occurrences looks like this:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
18:06:01.802 > \/---- Line Saved to SD Card ----\/ 18:06:01.802 > 2020-04-02 17:06:00,25.00,4.836,-69,5,77.0 18:06:01.802 > 18:06:01.802 > 18:06:01.802 > ------------------------------------------ 18:06:53.812 > 18:06:53.812 > ------------------------------------------ 18:08:01.191 > 18:08:01.782 > \/---- Line Saved to SD Card ----\/ |
… whereas a “normal” interval across consecutive samples, where the Mayfly does attempt to send, looks like this:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
18:10:01.804 > \/---- Line Saved to SD Card ----\/ 18:10:01.804 > 2020-04-02 17:10:00,25.25,4.836,-69,7,77.4 18:10:01.804 > 18:10:01.804 > 18:10:01.804 > 18:10:53.254 > Sending data to [ 0 ] data.envirodiy.org 18:10:53.255 > POST /api/data-stream/ HTTP/1.1 18:10:53.581 > Host: data.envirodiy.org 18:10:53.581 > TOKEN: xyz 18:10:53.581 > Content-Length: 317 18:10:53.581 > Content-Type: application/json 18:10:53.581 > 18:10:53.581 > {"sampling_feature":"989b7148-d939-487e-ac47-baf41e30370d","timestamp":"2020-04-02T17:10:00-07:00","6ea18195-7d08-4cdb-9d02-2a374444b105":25.25,"b286a34a-0b48-4c35-a90e-a531a2594959":4.836,"621555d7-ebb1-4f8c-b8af-33fb35e78c3a":-69,"622b1b19-5a60-4c65-85d9-f33c80f81365":7,"6c79d6be-edd7-4bb3-836b-30b99d6b4f5d":77.4} 18:10:53.581 > 18:10:53.581 > -- Response Code -- 18:11:05.737 > 504 18:11:05.737 > ------------------------------------------ 18:11:06.663 > 18:11:06.663 > ------------------------------------------ 18:12:01.184 > 18:12:01.805 > \/---- Line Saved to SD Card ----\/ |
Any idea why the Mayfly didn’t send data at these times?
I’ll attach the log file and a time-series chart of when data was sent/not sent.
Thanks,
Matt
(Edit Apr6: Renaming my logfile so that it will successfully upload here.)