Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

INDY-1475: Fix losing events with same timestamps #847

Merged
merged 3 commits into from
Jul 31, 2018

Conversation

skhoroshavin
Copy link
Member

No description provided.

Sergey Khoroshavin added 2 commits July 31, 2018 15:17
Signed-off-by: Sergey Khoroshavin <sergey.khoroshavin@dsr-corporation.com>
Signed-off-by: Sergey Khoroshavin <sergey.khoroshavin@dsr-corporation.com>
def decode(key: bytes, value: bytes) -> MetricsEvent:
key = int.from_bytes(key, byteorder='big', signed=False)
ts = datetime.utcfromtimestamp((key >> KvStoreMetricsFormat.seq_bits) / 1000000.0)
type = MetricsType(int.from_bytes(value[:32], byteorder='big', signed=False))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

type is a standard Python function, so it's better not to use it

Signed-off-by: Sergey Khoroshavin <sergey.khoroshavin@dsr-corporation.com>
@ashcherbakov ashcherbakov merged commit 1123069 into hyperledger:master Jul 31, 2018
@skhoroshavin skhoroshavin deleted the indy-1475 branch July 31, 2018 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants