Skip to content
This repository was archived by the owner on Nov 21, 2023. It is now read-only.

Conversation

@acmiyaguchi
Copy link
Contributor

bug link

Option b seemed like a good choice. Landfill messages will be parsed directly into a string, which can be later decoded using json.loads if needed.

whd and others added 2 commits May 2, 2018 15:54
Documents from landfill will be decoded directly into their string
representation. The logic for _parse_heka_record is generally
unnecessary because fields are not extracted when dumped to landfill.
@acmiyaguchi acmiyaguchi requested a review from whd May 2, 2018 23:10
Copy link
Member

@whd whd left a comment

Choose a reason for hiding this comment

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

LGTM, the only weird case I could see if when Fields[content] has a non-gzip non-utf8 payload, which we might want to throw an except UnicodeDecodeError on as we do when decoding normal fields.

@acmiyaguchi
Copy link
Contributor Author

@whd I caught a bug after writing the test for an invalid utf-8 string. Is throwing a UnicodeDecodeError and not catching it the behavior we would want here?

@whd
Copy link
Member

whd commented May 3, 2018

This is indeed the "weird case" I mentioned in my previous comment; my intent was to suggest that we do what we already do when decoding normal fields (effectively, drop the field).

@acmiyaguchi
Copy link
Contributor Author

Merging this in, I had been waiting for Python 3 support, but it may be better to rebase on this new functionality.

@acmiyaguchi acmiyaguchi merged commit 8d3813c into mozilla:master May 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants