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

Fix memory leak around timestamp precision adjust #408

Merged
merged 1 commit into from
Oct 12, 2018

Conversation

cheynearista
Copy link
Contributor

  • Global MAX_REASONABLE_TIMESTAMP adjusted in error. Due to arbitrary precision
    arithmetic, over time memory can be seen leaking for lines processed with ms
    precision timestamps. Set/adjust local copy max_reasonable_timestamp within scope of function.

  • Perform timestamp precision check before converting timestamp to int to
    save allocation of buffer.

  • Replace space normalization looping construct with split/join.

* Global MAX_REASONABLE_TIMESTAMP adjusted in error. Due to arbitrary precision
arithmetic, over time memory can be seen leaking for lines processed with ms
precision timestamps.

* Perform timestamp precision check before converting timestamp to int to
save allocation of buffer.

* Replace space normalization looping construct with split/join.
@cheynearista
Copy link
Contributor Author

@OpenTSDB Can I get a set of eyes on this?

@tsuna
Copy link
Member

tsuna commented Oct 12, 2018

LGTM, thanks for the fix!

@tsuna tsuna merged commit 7b7ab7e into OpenTSDB:master Oct 12, 2018
@johann8384 johann8384 added this to the 1.3.3 milestone Sep 17, 2020
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.

3 participants