private List<RefStreamDefinition> loadBulkData(
            final int refStreamDefinitionCount,
            final int keyValueMapCount,
            final int rangeValueMapCount,
            final int entryCount,
            final int refStreamDefinitionOffset,
            final MapNamFunc mapNamFunc) {

        assertThat(refStreamDefinitionCount)
                .isGreaterThan(0);
        assertThat(keyValueMapCount)
                .isGreaterThanOrEqualTo(0);
        assertThat(rangeValueMapCount)
                .isGreaterThanOrEqualTo(0);
        assertThat(entryCount)
                .isGreaterThan(0);

        List<RefStreamDefinition> refStreamDefinitions = new ArrayList<>();

        for (int i = 0; i < refStreamDefinitionCount; i++) {

            RefStreamDefinition refStreamDefinition = buildRefStreamDefintion(i + refStreamDefinitionOffset);

            refStreamDefinitions.add(refStreamDefinition);

            refDataStore.doWithLoaderUnlessComplete(
                    refStreamDefinition,
                    System.currentTimeMillis(),
                    loader -> {
                        loader.initialise(false);
                        loader.setCommitInterval(1000);

                        loadKeyValueData(keyValueMapCount, entryCount, refStreamDefinition, loader, mapNamFunc);
                        loadRangeValueData(keyValueMapCount, entryCount, refStreamDefinition, loader, mapNamFunc);

                        loader.completeProcessing();
                    });
        }
        return refStreamDefinitions;
    }
@param refStreamDefinitionCount  Number of {@link RefStreamDefinition}s to create.
@param keyValueMapCount          Number of KeyValue type maps to create per {@link RefStreamDefinition}
@param rangeValueMapCount        Number of RangeValue type maps to create per {@link RefStreamDefinition}
@param entryCount                Number of map entries to create per map
@param refStreamDefinitionOffset The offset from zero for the refStreamDefinition partIndex
@return The created {@link RefStreamDefinition} objects
stroom-pipeline/src/test/java/stroom/pipeline/refdata/store/onheapstore/TestRefDataOnHeapStore.java