private List<Entry<RefStreamDefinition, RefDataProcessingInfo>> getInvalidStreams(
            final Txn<ByteBuffer> writeTxn,
            final Predicate<ByteBuffer> partialLoadProgressPredicate) {

        final List<Entry<RefStreamDefinition, RefDataProcessingInfo>> invalidStreams =
                processingInfoDb.streamEntriesAsBytes(
                        writeTxn,
                        KeyRange.all(),
                        stream ->
                                stream.filter(keyVal ->
                                                partialLoadProgressPredicate.test(keyVal.val()))
                                        .map(processingInfoDb::deserializeKeyVal)
                                        .collect(Collectors.toList()));

        final String countsByState = invalidStreams.stream()
                .collect(Collectors.groupingBy(entry ->
                        entry.getValue().getProcessingState(), Collectors.counting()))
                .entrySet()
                .stream()
                .map(entry -> entry.getKey() + ":" + entry.getValue())
                .collect(Collectors.joining(", "));

        if (invalidStreams.size() > 0) {
            LOGGER.info("Found partially loaded/purged ref streams (counts: {}) (total {}). " +
                        "They will now all be purged.",
                    countsByState,
                    invalidStreams.size());
        }

        return invalidStreams;
    }
An Off Heap implementation of {@link RefDataStore} using LMDB.
<p>
Essentially each ref stream (a {@link RefStreamDefinition}) contains 1-* map names.
Multiple ref streams can contain the same map name.
Within a ref stream + map combo (a {@link MapDefinition}) there are 1-* entries.
A lookup is done by creating a key that is the lookup key combined with a {@link MapDefinition}
so only an entry matching the lookup key, the map name and the ref stream will be returned.
stroom-pipeline/src/main/java/stroom/pipeline/refdata/store/offheapstore/RefDataOffHeapStore.java