Hitachi

In-Memory Data Grid Hitachi Elastic Application Data Store


17.3.4 How to acquire a list of keys efficiently

If a group of keys is stored in ascending order of the ASCII codes and a user function is used to acquire a list of keys asynchronously, a set of keys acquired once can be excluded from the keys capable of being acquired thereafter (so that afterwards, a list is acquired of only those keys that have not already been acquired). This is done by combining keyIterator() and keyIterator() (key interface specification) of the Group interface.

This method allows you to acquire a list of keys efficiently because you do not have to acquire a list of all keys each time data is added.

[Figure]

For details about the Group interface, see 18.2.9 Group interface.

To acquire a list of keys in descending order of the ASCII codes, combine descendingKeyIterator() and descendingKeyIterator() (key interface specification) of the Group interface.

Tip

You can acquire a list efficiently by specifying as keys a sequence (such as date and time) that corresponds to the key storage sequence.