telefonicaid / fiware-orion

Context Broker and CEF building block for context data management, providing NGSI interfaces.
https://github.com/telefonicaid/fiware-orion/blob/master/doc/manuals/orion-api.md
GNU Affero General Public License v3.0
210 stars 265 forks source link

Using long long for dates instead of doubles #2611

Open fgalan opened 8 years ago

fgalan commented 8 years ago

Raised in https://github.com/telefonicaid/fiware-orion/pull/2590#discussion_r84064391

Currently we are using internally double types for dates. It has been proposed to use long long.

Some quotes:

Changing to long long could be a better option... but we need to analyze the implications (including the ones at DB level)

I was thinking maybe it was to have decimals of a second ... If that is not the case, let's open an issue. Doubles give rounding problems that integers don't have.

fgalan commented 7 years ago

Taking into accoun the (recent) issue at https://github.com/telefonicaid/fiware-orion/issues/2670, probably it is not a bad idea to keep them as double ( @kzangeli already mention this possibility in its original comment in the cited PR).