metron-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From JonZeolla <...@git.apache.org>
Subject [GitHub] metron issue #692: METRON-1107 add support for handling epoch dates in secon...
Date Mon, 14 Aug 2017 16:41:46 GMT
Github user JonZeolla commented on the issue:

    https://github.com/apache/metron/pull/692
  
    > can I ask why?
    
    Because that is 9x `9`s in epoch (`999999999`, assuming seconds).
    
    > for < 10, we don't know if it is millis or timestamps, at least that is my thinking.
adding a 0 up to 13 for those numbers is equally as bad as just leaving them no?
    
    Well, that's partially true.  We know that for 1-3 digits it must be seconds, and for
11-13 digits it must be millis.  Perhaps we provide an optional field that specifies millis
vs seconds with a default to whatever is more common (seconds) and be done with it?  Do we
have any core assumptions of using milli elsewhere?  Of course this will need an update to
a lot of tests to either change to seconds or specify milli.
    
    As far as attempting to appropriately zero-pad it (which I think is what you mentioned
but I could be wrong), I'm probably against that because a small mistake could drastically
affect the timestamp.  To be explicit - `1234567890` (2009) could become `00001234567890`
(1970) or `123456789` (1973) could become `0000123456789` (1970).  More realistically, this
probably isn't a horrible approach either.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message