You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/02/05 01:48:07 UTC
[GitHub] justinborromeo opened a new pull request #7002: [Benchmarking] Call
blackhole#consume() on collections instead of iterating through each element
justinborromeo opened a new pull request #7002: [Benchmarking] Call blackhole#consume() on collections instead of iterating through each element
URL: https://github.com/apache/incubator-druid/pull/7002
Currently, in the query benchmarks, the collection of results is being iterated through and `blackhole.consume()` is being called on each result individually. According to (this comment](https://stackoverflow.com/questions/54488216/does-the-effect-of-jmh-blackholeconsume-vary-depending-on-the-type-of-object?noredirect=1#comment95783891_54488216) comment on SO, it would be better to call `consume` once on the collection. Although the effect of this change is likely trivial, it's probably a better practice to remove unnecessary overhead on our benchmarks.
If anyone disagrees with the opinion in the SO comment, lmk.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org