Skip to content

Fixes for coverity id'd issues#265

Merged
rwgdrummer merged 1 commit intomasterfrom
GEOWAVE-264
Mar 17, 2015
Merged

Fixes for coverity id'd issues#265
rwgdrummer merged 1 commit intomasterfrom
GEOWAVE-264

Conversation

@chrisbennight
Copy link
Copy Markdown
Contributor

(don't accept this yet, wanted to open this up to discuss a few questions first)
(coverity issues can be seen @ https://scan.coverity.com/projects/3371/view_defects - login required)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@rfecher @rwgdrummer
So when .flush() (or .close()) is called on the StatsCompositionTool instance it goes through the local set of statistics, and pushes them to accumulo.

The problem is there are plenty of statistics which are non idempotent (count being one) - and I don't think there's any realistic way we can require the statistics to be idempotent (it rules it too many).

The problem is any code path which might end up calling .flush() twice (or call a .flush() and later a .close()) will currently trigger multiple evaluations of these.

I would expect calling .flush() multiple times to be safe.

I added a statistics.clear() call here after statistics were flushed; I'm not familiar enough with the rest of the statistics stack to know if this will have other unintended side effects. (It passes testing fine, and in a brief look seemed to be okay.) (had to ad locking around it to ensure what was cleared was the same as what was already persisted).

Added reset to stats tool to clear out entries in error and retain auto-closeable capability

merge with master
rwgdrummer added a commit that referenced this pull request Mar 17, 2015
Fixes for coverity id'd issues
@rwgdrummer rwgdrummer merged commit 357bf93 into master Mar 17, 2015
@rwgdrummer rwgdrummer deleted the GEOWAVE-264 branch March 17, 2015 19:11
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.

2 participants