Open pgdr opened 7 years ago
Maybe we could send a srring like 'now' or 'server'?
If I submit the value (value, sensor_id, timestamp) with timestamp = null, I would like to have the server interpret it as now.
Then it is up to the client to not cache values, in a fire-and-forget style.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/FriskByBergen/friskby/issues/206, or mute the thread https://github.com/notifications/unsubscribe-auth/ABQqwYYdNdWlbUNV5qQM3jjk8gz__DSUks5rp54IgaJpZM4MqI3S .
Yes, we could. Are you afraid that we might wrongly interpret (or transmit) a null
or 0
as timestamp(0)
?
It sounds easier on the server side to use 0, as we can then if not timestamp: timestamp = now()
.
My main point was that the client should send something, and not just an empty value. I might have misunderstood your original suggestion.
If I submit the value
(value, sensor_id, timestamp)
withtimestamp = null
, I would like to have the server interpret it asnow
.Then it is up to the client to not cache values, in a fire-and-forget style.