[
https://issues.apache.org/jira/browse/IGNITE-7986?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16463659#comment-16463659
]
Dmitriy Pavlov commented on IGNITE-7986:
----------------------------------------
[~VitaliyB] , I've looked to change itself and now it looking good. I've missed
BitSet.nextBitSet method takes index as parameter and index is inclusive (I
thougth it is exclusive), so hasNext will not have any side effect.
I hope my last proposal will be ask to write additional randomized test with
control map (e.g. HashMap).
This test will generate some random partitions and its states and put it into
this map and control (java build in map). Then test should compare results and
check it is equal, so we can be sure implemented iterator will return all
values which were placed in map.
> GridPartitionStateMap.entrySet() optimization.
> ----------------------------------------------
>
> Key: IGNITE-7986
> URL: https://issues.apache.org/jira/browse/IGNITE-7986
> Project: Ignite
> Issue Type: Improvement
> Reporter: Vitaliy Biryukov
> Assignee: Vitaliy Biryukov
> Priority: Major
> Fix For: 2.6
>
> Attachments: GridPartitionStateMapBench.java, fullResult.txt
>
>
> GridPartitionStateMap based on BitSet. And the size of a BitSet depends on
> the maximum key element, and not on the number of elements.
> Just using the "BitSet.nextSetBit" method, will improve the performance of
> the iterator for big clusters or caches with a large number of partitions.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)