diff --git a/community/consistency-check/src/test/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporterTest.java b/community/consistency-check/src/test/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporterTest.java index 8e33466c97f94..499ec2014c1c3 100644 --- a/community/consistency-check/src/test/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporterTest.java +++ b/community/consistency-check/src/test/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporterTest.java @@ -169,7 +169,7 @@ public void shouldImportCsvData() throws Exception inserter.doImport( Inputs.input( nodes( nodeRandomSeed, NODE_COUNT, inputIdGenerator, groups ), relationships( relationshipRandomSeed, RELATIONSHIP_COUNT, inputIdGenerator, groups ), - idMapper, idGenerator, false, + idMapper, idGenerator, /*insanely high bad tolerance, but it will actually never be that many*/ silentBadCollector( RELATIONSHIP_COUNT ) ) ); diff --git a/community/import-tool/src/test/java/org/neo4j/tooling/CsvDataGeneratorInput.java b/community/import-tool/src/test/java/org/neo4j/tooling/CsvDataGeneratorInput.java index 9d035af8141a1..a6424f8929581 100644 --- a/community/import-tool/src/test/java/org/neo4j/tooling/CsvDataGeneratorInput.java +++ b/community/import-tool/src/test/java/org/neo4j/tooling/CsvDataGeneratorInput.java @@ -105,12 +105,6 @@ public IdGenerator idGenerator() return idType.idGenerator(); } - @Override - public boolean specificRelationshipIds() - { - return false; - } - @Override public Collector badCollector() { diff --git a/community/kernel/src/main/java/org/neo4j/kernel/impl/storemigration/participant/StoreMigrator.java b/community/kernel/src/main/java/org/neo4j/kernel/impl/storemigration/participant/StoreMigrator.java index 9d6e80f73bce9..3c8e5960c3f7c 100644 --- a/community/kernel/src/main/java/org/neo4j/kernel/impl/storemigration/participant/StoreMigrator.java +++ b/community/kernel/src/main/java/org/neo4j/kernel/impl/storemigration/participant/StoreMigrator.java @@ -155,6 +155,9 @@ public void migrate( File storeDir, File migrationDir, MigrationProgressMonitor. RecordFormats newFormat = selectForVersion( versionToMigrateTo ); if ( !oldFormat.equals( newFormat ) ) { + // TODO if this store has relationship indexes then warn user about that they will be incorrect + // after migration, because now we're rewriting the relationship ids. + // Some form of migration is required (a fallback/catch-all option) migrateWithBatchImporter( storeDir, migrationDir, lastTxId, lastTxChecksum, lastTxLogPosition.getLogVersion(), lastTxLogPosition.getByteOffset(), @@ -357,7 +360,7 @@ private void migrateWithBatchImporter( File storeDir, File migrationDir, long la InputIterable relationships = legacyRelationshipsAsInput( legacyStore, requiresPropertyMigration ); importer.doImport( - Inputs.input( nodes, relationships, IdMappers.actual(), IdGenerators.fromInput(), true, + Inputs.input( nodes, relationships, IdMappers.actual(), IdGenerators.fromInput(), Collectors.badCollector( badOutput, 0 ) ) ); // During migration the batch importer doesn't necessarily writes all entities, depending on @@ -507,7 +510,6 @@ protected InputRelationship inputEntityOf( RelationshipRecord record ) InputEntity.NO_PROPERTIES, record.getNextProp(), record.getFirstNode(), record.getSecondNode(), null, record.getType() ); propertyDecorator.accept( result, record ); - result.setSpecificId( record.getId() ); return result; } }; diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/CalculateRelationshipsStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/CalculateRelationshipsStep.java index e0b906b3ea728..79f487ad388b1 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/CalculateRelationshipsStep.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/CalculateRelationshipsStep.java @@ -41,17 +41,7 @@ public CalculateRelationshipsStep( StageControl control, Configuration config, R @Override protected void process( Batch batch, BatchSender sender ) throws Throwable { - int batchSize = batch.input.length; - InputRelationship inputRelationship = batch.input[batchSize - 1]; - - if ( inputRelationship.hasSpecificId() ) - { - maxSpecific = Math.max( inputRelationship.specificId(), maxSpecific ); - } - else - { - numberOfRelationships += batchSize; - } + numberOfRelationships += batch.input.length; sender.send( batch ); } diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/NodeCountsStage.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/NodeCountsStage.java index 3e34c94f9e321..8ae58fe87b795 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/NodeCountsStage.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/NodeCountsStage.java @@ -22,9 +22,12 @@ import org.neo4j.kernel.impl.api.CountsAccessor; import org.neo4j.kernel.impl.store.NodeStore; import org.neo4j.unsafe.impl.batchimport.cache.NodeLabelsCache; +import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; import org.neo4j.unsafe.impl.batchimport.staging.Stage; import org.neo4j.unsafe.impl.batchimport.stats.StatsProvider; +import static org.neo4j.unsafe.impl.batchimport.RecordIdIteration.allIn; + /** * Reads all records from {@link NodeStore} and process the counts in them, populating {@link NodeLabelsCache} * for later use of {@link RelationshipCountsStage}. @@ -35,7 +38,7 @@ public NodeCountsStage( Configuration config, NodeLabelsCache cache, NodeStore n int highLabelId, CountsAccessor.Updater countsUpdater, StatsProvider... additionalStatsProviders ) { super( "Node counts", config ); - add( new ReadNodeRecordsStep( control(), config, nodeStore ) ); + add( new ReadRecordsStep<>( control(), config, nodeStore, allIn( nodeStore ) ) ); add( new RecordProcessorStep<>( control(), "COUNT", config, new NodeCountsProcessor( nodeStore, cache, highLabelId, countsUpdater ), true, additionalStatsProviders ) ); } diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporter.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporter.java index cbec60f364e24..c3429cb8e503a 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporter.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ParallelBatchImporter.java @@ -21,7 +21,6 @@ import java.io.File; import java.io.IOException; - import org.neo4j.collection.primitive.PrimitiveLongIterator; import org.neo4j.helpers.Exceptions; import org.neo4j.helpers.Format; @@ -174,7 +173,7 @@ public void doImport( Input input ) throws IOException executeStages( nodeStage, calculateDenseNodesStage ); } - importRelationships( input, nodeRelationshipCache, storeUpdateMonitor, neoStore, badCollector, writeMonitor, + importRelationships( nodeRelationshipCache, storeUpdateMonitor, neoStore, writeMonitor, idMapper, cachedRelationships, inputCache, calculateDenseNodesStage.getRelationshipTypes( 100 ) ); @@ -225,8 +224,8 @@ public void doImport( Input input ) throws IOException } } - private void importRelationships( Input input, NodeRelationshipCache nodeRelationshipCache, - CountingStoreUpdateMonitor storeUpdateMonitor, BatchingNeoStores neoStore, Collector badCollector, + private void importRelationships( NodeRelationshipCache nodeRelationshipCache, + CountingStoreUpdateMonitor storeUpdateMonitor, BatchingNeoStores neoStore, IoMonitor writeMonitor, IdMapper idMapper, InputIterable relationships, InputCache inputCache, Object[] allRelationshipTypes ) { @@ -245,6 +244,7 @@ private void importRelationships( Input input, NodeRelationshipCache nodeRelatio PerTypeRelationshipSplitter perTypeIterator = new PerTypeRelationshipSplitter( relationships.iterator(), allRelationshipTypes, type -> neoStore.getRelationshipTypeRepository().getOrCreateId( type ), inputCache ); + RelationshipStore relationshipStore = neoStore.getRelationshipStore(); long nextRelationshipId = 0; for ( int i = 0; perTypeIterator.hasNext(); i++ ) @@ -253,13 +253,14 @@ private void importRelationships( Input input, NodeRelationshipCache nodeRelatio nodeRelationshipCache.setForwardScan( true ); Object currentType = perTypeIterator.currentType(); int currentTypeId = neoStore.getRelationshipTypeRepository().getOrCreateId( currentType ); + + System.out.println( "------------- " + currentType + "(" + currentTypeId + ")" ); + InputIterator perType = perTypeIterator.next(); String topic = " [:" + currentType + "] (" + (i+1) + "/" + allRelationshipTypes.length + ")"; final RelationshipStage relationshipStage = new RelationshipStage( topic, config, writeMonitor, - perType, idMapper, - neoStore, nodeRelationshipCache, input.specificRelationshipIds(), storeUpdateMonitor, - nextRelationshipId ); + perType, idMapper, neoStore, nodeRelationshipCache, storeUpdateMonitor, nextRelationshipId ); executeStages( relationshipStage ); // Stage 4a -- set node nextRel fields for dense nodes diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStep.java deleted file mode 100644 index 0fe87300a30c9..0000000000000 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStep.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * Copyright (c) 2002-2016 "Neo Technology," - * Network Engine for Objects in Lund AB [http://neotechnology.com] - * - * This file is part of Neo4j. - * - * Neo4j is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package org.neo4j.unsafe.impl.batchimport; - -import org.neo4j.kernel.impl.store.NodeStore; -import org.neo4j.kernel.impl.store.id.validation.IdValidator; -import org.neo4j.kernel.impl.store.record.NodeRecord; -import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; -import org.neo4j.unsafe.impl.batchimport.staging.StageControl; - -import static java.lang.Math.min; - -/** - * Reads from {@link NodeStore} and produces batches of {@link NodeRecord} for others to process. - *

- * Future: Would be quite efficient just get a page cursor and read inUse+labelField and store - * all labelField values of a batch in one long[] or similar, instead of passing on a NodeRecord[]. - */ -public class ReadNodeRecordsStep extends ReadRecordsStep -{ - private long id; - - public ReadNodeRecordsStep( StageControl control, Configuration config, NodeStore nodeStore ) - { - super( control, config, nodeStore ); - } - - @Override - protected Object nextBatchOrNull( long ticket, int batchSize ) - { - int size = (int) min( batchSize, highId - id ); - NodeRecord[] batch = new NodeRecord[size]; - boolean seenReservedId = false; - - for ( int i = 0; i < size; i++ ) - { - // We don't want null in batch[i], a record, whether used or unused is what we want - cursor.next( id++ ); - NodeRecord newRecord = record.clone(); - batch[i] = newRecord; - seenReservedId |= IdValidator.isReservedId( newRecord.getId() ); - } - - batch = removeRecordWithReservedId( batch, seenReservedId ); - - return batch.length > 0 ? batch : null; - } - - @Override - protected long position() - { - return id * store.getRecordSize(); - } -} diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipCountsDataStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipCountsDataStep.java index afa1207b3dd9a..f8de40284f99d 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipCountsDataStep.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipCountsDataStep.java @@ -26,6 +26,8 @@ import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; import org.neo4j.unsafe.impl.batchimport.staging.StageControl; +import static org.neo4j.unsafe.impl.batchimport.RecordIdIteration.allIn; + /** * Reads from {@link RelationshipStore} and produces batches of startNode,type,endNode values for * others to process. The result is one long[] with all values in. @@ -37,7 +39,7 @@ public class ReadRelationshipCountsDataStep extends ReadRecordsStep. - */ -package org.neo4j.unsafe.impl.batchimport; - -import org.neo4j.kernel.impl.store.RelationshipStore; -import org.neo4j.kernel.impl.store.id.validation.IdValidator; -import org.neo4j.kernel.impl.store.record.RelationshipRecord; -import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; -import org.neo4j.unsafe.impl.batchimport.staging.StageControl; - -import static java.lang.Math.min; - -/** - * Reads from {@link RelationshipStore} backwards and produces batches of {@link RelationshipRecord} for others - * to process. - */ -public class ReadRelationshipRecordsBackwardsStep extends ReadRecordsStep -{ - private final long firstRelationshipId; - private long id; - - public ReadRelationshipRecordsBackwardsStep( StageControl control, Configuration config, - RelationshipStore store, long firstRelationshipId ) - { - super( control, config, store ); - this.firstRelationshipId = firstRelationshipId; - this.id = highId; - } - - @Override - protected Object nextBatchOrNull( long ticket, int batchSize ) - { - int size = (int) min( batchSize, id-firstRelationshipId ); - RelationshipRecord[] batch = new RelationshipRecord[size]; - boolean seenReservedId = false; - - for ( int i = 0; i < size; i++ ) - { - cursor.next( --id ); - RelationshipRecord newRecord = record.clone(); - batch[i] = newRecord; - seenReservedId |= IdValidator.isReservedId( newRecord.getId() ); - } - - batch = removeRecordWithReservedId( batch, seenReservedId ); - - return batch.length > 0 ? batch : null; - } - - @Override - protected long position() - { - return (highId - id) * store.getRecordSize(); - } -} diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RecordIdIteration.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RecordIdIteration.java new file mode 100644 index 0000000000000..a12d9cc0ebe76 --- /dev/null +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RecordIdIteration.java @@ -0,0 +1,42 @@ +package org.neo4j.unsafe.impl.batchimport; + +import org.neo4j.collection.primitive.PrimitiveLongCollections; +import org.neo4j.collection.primitive.PrimitiveLongIterator; +import org.neo4j.kernel.impl.store.RecordStore; +import org.neo4j.kernel.impl.store.record.AbstractBaseRecord; + +public class RecordIdIteration +{ + public static final PrimitiveLongIterator backwards( long highExcluded, long lowIncluded ) + { + return new PrimitiveLongCollections.PrimitiveLongBaseIterator() + { + private long next = highExcluded - 1; + + @Override + protected boolean fetchNext() + { + return next >= lowIncluded ? next( next-- ) : false; + } + }; + } + + public static final PrimitiveLongIterator forwards( long lowIncluded, long highExcluded ) + { + return new PrimitiveLongCollections.PrimitiveLongBaseIterator() + { + private long nextId = lowIncluded; + + @Override + protected boolean fetchNext() + { + return nextId < highExcluded ? next( nextId++ ) : false; + } + }; + } + + public static PrimitiveLongIterator allIn( RecordStore store ) + { + return forwards( store.getNumberOfReservedLowIds(), store.getHighId() ); + } +} diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipEncoderStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipEncoderStep.java index 65633e8bdd307..16a80777aeb35 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipEncoderStep.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipEncoderStep.java @@ -45,23 +45,14 @@ public class RelationshipEncoderStep extends ProcessorStep relationshipTypeRepository, - NodeRelationshipCache cache, - boolean specificIds ) + NodeRelationshipCache cache ) { super( control, "RELATIONSHIP", config, 0 ); this.relationshipTypeRepository = relationshipTypeRepository; this.cache = cache; - this.specificIds = specificIds; } @Override @@ -80,12 +71,7 @@ protected void process( Batch batch, Batch for ( int i = 0; i < input.length; i++ ) { InputRelationship batchRelationship = input[i]; - if ( specificIds != batchRelationship.hasSpecificId() ) - { - throw new IllegalStateException( "Input was declared to have specificRelationshipIds=" + - specificIds + ", but " + batchRelationship + " didn't honor that" ); - } - long relationshipId = specificIds ? batchRelationship.specificId() : nextRelationshipId++; + long relationshipId = nextRelationshipId++; // Ids have been verified to exist in CalculateDenseNodeStep long startNodeId = ids[i*2]; long endNodeId = ids[i*2+1]; diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipLinkbackStage.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipLinkbackStage.java index 069df021e15f1..355118057205d 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipLinkbackStage.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipLinkbackStage.java @@ -22,19 +22,22 @@ import org.neo4j.kernel.impl.store.RelationshipStore; import org.neo4j.kernel.impl.store.record.RelationshipRecord; import org.neo4j.unsafe.impl.batchimport.cache.NodeRelationshipCache; +import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; import org.neo4j.unsafe.impl.batchimport.staging.Stage; +import static org.neo4j.unsafe.impl.batchimport.RecordIdIteration.backwards; + /** * Sets {@link RelationshipRecord#setFirstPrevRel(long)} and {@link RelationshipRecord#setSecondPrevRel(long)} * in {@link ParallelBatchImporter}. */ public class RelationshipLinkbackStage extends Stage { - public RelationshipLinkbackStage( String topic, Configuration config, RelationshipStore store, NodeRelationshipCache cache, - long firstRelationshipId, boolean denseNodes ) + public RelationshipLinkbackStage( String topic, Configuration config, RelationshipStore store, + NodeRelationshipCache cache, long firstRelationshipId, boolean denseNodes ) { super( "Relationship --> Relationship" + topic, config ); - add( new ReadRelationshipRecordsBackwardsStep( control(), config, store, firstRelationshipId ) ); + add( new ReadRecordsStep<>( control(), config, store, backwards( store.getHighId(), firstRelationshipId ) ) ); add( new RecordProcessorStep<>( control(), "LINK", config, new RelationshipLinkbackProcessor( cache, denseNodes ), false ) ); add( new UpdateRecordsStep<>( control(), config, store ) ); diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipStage.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipStage.java index ba9337811744d..e7ec028d9954b 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipStage.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/RelationshipStage.java @@ -38,11 +38,10 @@ public class RelationshipStage extends Stage { private ParallelizeByNodeIdStep parallelizer; - private RelationshipEncoderStep encoder; public RelationshipStage( String topic, Configuration config, IoMonitor writeMonitor, InputIterator relationships, IdMapper idMapper, BatchingNeoStores neoStore, - NodeRelationshipCache cache, boolean specificIds, EntityStoreUpdaterStep.Monitor storeUpdateMonitor, + NodeRelationshipCache cache, EntityStoreUpdaterStep.Monitor storeUpdateMonitor, long firstRelationshipId ) { super( "Relationships" + topic, config, ORDER_SEND_DOWNSTREAM | ORDER_PROCESS ); @@ -53,8 +52,8 @@ public RelationshipStage( String topic, Configuration config, IoMonitor writeMon add( new RelationshipPreparationStep( control(), config, idMapper ) ); add( new PropertyEncoderStep<>( control(), config, neoStore.getPropertyKeyRepository(), propertyStore ) ); add( parallelizer = new ParallelizeByNodeIdStep( control(), config, firstRelationshipId ) ); - add( encoder = new RelationshipEncoderStep( control(), config, - neoStore.getRelationshipTypeRepository(), cache, specificIds ) ); + add( new RelationshipEncoderStep( control(), config, + neoStore.getRelationshipTypeRepository(), cache ) ); add( new EntityStoreUpdaterStep<>( control(), config, relationshipStore, propertyStore, writeMonitor, storeUpdateMonitor ) ); } diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStep.java index c8faab8d86ff5..9a16a7e8c4f03 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStep.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStep.java @@ -33,8 +33,7 @@ import org.neo4j.unsafe.impl.batchimport.stats.StatsProvider; /** - * Updates a batch of records to a store. Can have {@link #accept(AbstractBaseRecord)} overwritten to not not accept - * a record, which will have that record be written as unused instead. + * Updates a batch of records to a store. */ public class UpdateRecordsStep extends ProcessorStep @@ -51,19 +50,13 @@ public UpdateRecordsStep( StageControl control, Configuration config, RecordStor this.recordSize = store.getRecordSize(); } - @SuppressWarnings( "unchecked" ) @Override protected void process( RECORD[] batch, BatchSender sender ) throws Throwable { for ( RECORD record : batch ) { - if ( record != null && !IdValidator.isReservedId( record.getId() ) ) + if ( record != null && record.inUse() && !IdValidator.isReservedId( record.getId() ) ) { - if ( record.inUse() && !accept( record ) ) - { - record = (RECORD) record.clone(); - record.setInUse( false ); - } update( record ); } } @@ -76,11 +69,6 @@ protected void update( RECORD record ) throws Throwable store.updateRecord( record ); } - protected boolean accept( @SuppressWarnings( "unused" ) RECORD record ) - { - return true; - } - @Override protected void collectStatsProviders( Collection into ) { diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Input.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Input.java index 96679f1a6d0ae..6c46d1701c99b 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Input.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Input.java @@ -58,13 +58,6 @@ public interface Input */ IdGenerator idGenerator(); - /** - * @return whether or not {@link InputRelationship input relationships} returned by {@link #relationships()} - * specify specific actual relationship ids to be used in the database. Either all - * {@link InputRelationship input relationships} must specify specific ids or none. - */ - boolean specificRelationshipIds(); - /** * @return a {@link Collector} capable of writing {@link InputRelationship bad relationships} * and {@link InputNode duplicate nodes} to an output stream for later handling. diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputCache.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputCache.java index 66d8591096989..e343ec6cb0d52 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputCache.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputCache.java @@ -110,8 +110,6 @@ public class InputCache implements Closeable static final byte LABEL_REMOVAL = 1; static final byte LABEL_ADDITION = 2; static final byte END_OF_LABEL_CHANGES = 0; - static final byte SPECIFIC_ID = 1; - static final byte UNSPECIFIED_ID = 0; static final byte HAS_TYPE_ID = 2; static final byte SAME_TYPE = 0; static final byte NEW_TYPE = 1; diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationship.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationship.java index f1cf295b5313a..62c8d02cc1acd 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationship.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationship.java @@ -30,9 +30,6 @@ */ public class InputRelationship extends InputEntity { - public static final long NO_SPECIFIC_ID = -1L; - - private long id = NO_SPECIFIC_ID; private final Object startNode; private final Object endNode; private String type; @@ -64,23 +61,6 @@ public InputRelationship( this.typeId = typeId; } - public InputRelationship setSpecificId( long id ) - { - this.id = id; - return this; - } - - public boolean hasSpecificId() - { - return id != NO_SPECIFIC_ID; - } - - public long specificId() - { - assert hasSpecificId() : "Didn't have specific id set"; - return id; - } - public Group startNodeGroup() { return startNodeGroup; diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipCacher.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipCacher.java index c4904a7b1006e..100a40069953a 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipCacher.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipCacher.java @@ -25,9 +25,7 @@ import static org.neo4j.unsafe.impl.batchimport.input.InputCache.NEW_TYPE; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.RELATIONSHIP_TYPE_TOKEN; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.SAME_TYPE; -import static org.neo4j.unsafe.impl.batchimport.input.InputCache.SPECIFIC_ID; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.HAS_TYPE_ID; -import static org.neo4j.unsafe.impl.batchimport.input.InputCache.UNSPECIFIED_ID; /** * Caches {@link InputRelationship} to disk using a binary format. @@ -47,17 +45,6 @@ protected void writeEntity( InputRelationship relationship ) throws IOException // properties super.writeEntity( relationship ); - // id - if ( relationship.hasSpecificId() ) - { - channel.put( SPECIFIC_ID ); - channel.putLong( relationship.specificId() ); - } - else - { - channel.put( UNSPECIFIED_ID ); - } - // groups writeGroup( relationship.startNodeGroup(), 0 ); writeGroup( relationship.endNodeGroup(), 1 ); diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipReader.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipReader.java index 445f92583add6..2f9da9a14d6a7 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipReader.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/InputRelationshipReader.java @@ -26,7 +26,6 @@ import static org.neo4j.unsafe.impl.batchimport.input.InputCache.NEW_TYPE; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.RELATIONSHIP_TYPE_TOKEN; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.SAME_TYPE; -import static org.neo4j.unsafe.impl.batchimport.input.InputCache.SPECIFIC_ID; import static org.neo4j.unsafe.impl.batchimport.input.InputCache.HAS_TYPE_ID; import static org.neo4j.unsafe.impl.batchimport.input.InputEntity.NO_PROPERTIES; @@ -46,9 +45,6 @@ public InputRelationshipReader( StoreChannel channel, StoreChannel header, int b @Override protected InputRelationship readNextOrNull( Object properties ) throws IOException { - // id - long specificId = channel.get() == SPECIFIC_ID ? channel.getLong() : -1; - // groups Group startNodeGroup = readGroup( 0 ); Group endNodeGroup = readGroup( 1 ); @@ -68,13 +64,12 @@ protected InputRelationship readNextOrNull( Object properties ) throws IOExcepti default: throw new IllegalArgumentException( "Unrecognized type mode " + typeMode ); } - InputRelationship relationship = new InputRelationship( sourceDescription(), lineNumber(), position(), + return new InputRelationship( sourceDescription(), lineNumber(), position(), properties.getClass().isArray() ? (Object[]) properties : NO_PROPERTIES, properties.getClass().isArray() ? null : (Long) properties, startNodeGroup, startNodeId, endNodeGroup, endNodeId, type instanceof String ? (String) type : null, type instanceof String ? null : (Integer) type ); - return specificId != -1 ? relationship.setSpecificId( specificId ) : relationship; } } diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Inputs.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Inputs.java index ef8b7b2d50c2d..1d2911536be91 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Inputs.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/Inputs.java @@ -42,8 +42,7 @@ public class Inputs { public static Input input( final InputIterable nodes, final InputIterable relationships, - final IdMapper idMapper, final IdGenerator idGenerator, final boolean specificRelationshipIds, - final Collector badCollector ) + final IdMapper idMapper, final IdGenerator idGenerator, final Collector badCollector ) { return new Input() { @@ -71,12 +70,6 @@ public IdGenerator idGenerator() return idGenerator; } - @Override - public boolean specificRelationshipIds() - { - return specificRelationshipIds; - } - @Override public Collector badCollector() { diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInput.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInput.java index 0f624281381e3..c0641d6c8d6d0 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInput.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInput.java @@ -186,12 +186,6 @@ public IdGenerator idGenerator() return idType.idGenerator(); } - @Override - public boolean specificRelationshipIds() - { - return false; - } - @Override public Collector badCollector() { diff --git a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStep.java b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStep.java index 021e5218827c4..c308290fdf3d1 100644 --- a/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStep.java +++ b/community/kernel/src/main/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStep.java @@ -20,13 +20,15 @@ package org.neo4j.unsafe.impl.batchimport.staging; import java.lang.reflect.Array; +import java.util.Arrays; +import java.util.function.Predicate; import java.util.stream.Stream; +import org.neo4j.collection.primitive.PrimitiveLongIterator; import org.neo4j.kernel.impl.store.RecordCursor; import org.neo4j.kernel.impl.store.RecordStore; import org.neo4j.kernel.impl.store.id.validation.IdValidator; import org.neo4j.kernel.impl.store.record.AbstractBaseRecord; - import static org.neo4j.kernel.impl.store.record.RecordLoad.CHECK; /** @@ -36,17 +38,34 @@ * * @param type of {@link AbstractBaseRecord} */ -public abstract class ReadRecordsStep extends IoProducerStep +public class ReadRecordsStep extends IoProducerStep { protected final RecordStore store; protected final RECORD record; protected final RecordCursor cursor; protected final long highId; + private final PrimitiveLongIterator ids; + private final Class klass; + private final int recordSize; + private final Predicate filter; + private long count; + + public ReadRecordsStep( StageControl control, Configuration config, RecordStore store, + PrimitiveLongIterator ids ) + { + this( control, config, store, ids, all -> true ); + } - public ReadRecordsStep( StageControl control, Configuration config, RecordStore store ) + @SuppressWarnings( "unchecked" ) + public ReadRecordsStep( StageControl control, Configuration config, RecordStore store, + PrimitiveLongIterator ids, Predicate filter ) { super( control, config ); this.store = store; + this.ids = ids; + this.filter = filter; + this.klass = (Class) store.newRecord().getClass(); + this.recordSize = store.getRecordSize(); this.cursor = store.newRecordCursor( record = store.newRecord() ); this.highId = store.getHighId(); } @@ -58,6 +77,40 @@ public void start( int orderingGuarantees ) super.start( orderingGuarantees ); } + @SuppressWarnings( "unchecked" ) + @Override + protected Object nextBatchOrNull( long ticket, int batchSize ) + { + if ( !ids.hasNext() ) + { + return null; + } + + RECORD[] batch = (RECORD[]) Array.newInstance( klass, batchSize ); + boolean seenReservedId = false; + + int i = 0; + while ( i < batchSize && ids.hasNext() ) + { + cursor.next( ids.next() ); + if ( !filter.test( record ) ) + { + continue; + } + + RECORD newRecord = (RECORD) record.clone(); + batch[i] = newRecord; + seenReservedId |= IdValidator.isReservedId( newRecord.getId() ); + i++; + count++; + } + + batch = i == batchSize ? batch : Arrays.copyOf( batch, i ); + batch = removeRecordWithReservedId( batch, seenReservedId ); + + return batch.length > 0 ? batch : null; + } + @Override public void close() throws Exception { @@ -65,6 +118,12 @@ public void close() throws Exception cursor.close(); } + @Override + protected long position() + { + return count * recordSize; + } + protected RECORD[] removeRecordWithReservedId( RECORD[] records, boolean seenReservedId ) { if ( !seenReservedId ) diff --git a/community/kernel/src/test/java/examples/BatchInsertDocTest.java b/community/kernel/src/test/java/examples/BatchInsertDocTest.java index 1015e4dfa0342..d2c1df3693e53 100644 --- a/community/kernel/src/test/java/examples/BatchInsertDocTest.java +++ b/community/kernel/src/test/java/examples/BatchInsertDocTest.java @@ -41,7 +41,6 @@ import org.neo4j.graphdb.factory.GraphDatabaseFactory; import org.neo4j.helpers.collection.MapUtil; import org.neo4j.io.fs.DefaultFileSystemAbstraction; -import org.neo4j.io.fs.FileUtils; import org.neo4j.test.DefaultFileSystemRule; import org.neo4j.unsafe.batchinsert.BatchInserter; import org.neo4j.unsafe.batchinsert.BatchInserters; @@ -55,8 +54,7 @@ public class BatchInsertDocTest public void insert() throws Exception { // Make sure our scratch directory is clean - File tempStoreDir = new File( "target/batchinserter-example" ).getAbsoluteFile(); - FileUtils.deleteRecursively( tempStoreDir ); + File tempStoreDir = clean( "target/batchinserter-example" ).getAbsoluteFile(); // START SNIPPET: insert BatchInserter inserter = null; @@ -116,6 +114,8 @@ public void insert() throws Exception @Test public void insertWithConfig() throws IOException { + clean( "target/batchinserter-example-config" ); + // START SNIPPET: configuredInsert Map config = new HashMap<>(); config.put( "dbms.memory.pagecache.size", "512m" ); @@ -129,6 +129,7 @@ public void insertWithConfig() throws IOException @Test public void insertWithConfigFile() throws IOException { + clean( "target/docs/batchinserter-example-config" ); try ( Writer fw = fileSystem.openAsWriter( new File( "target/docs/batchinsert-config" ).getAbsoluteFile(), StandardCharsets.UTF_8, false ) ) { @@ -147,6 +148,13 @@ public void insertWithConfigFile() throws IOException // END SNIPPET: configFileInsert } + private File clean( String fileName ) throws IOException + { + File directory = new File( fileName ); + fileSystem.deleteRecursively( directory ); + return directory; + } + @Rule public DefaultFileSystemRule fileSystemRule = new DefaultFileSystemRule(); private DefaultFileSystemAbstraction fileSystem; diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipRecordsBackwardsStepTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipRecordsBackwardsStepTest.java deleted file mode 100644 index 29124b26f957b..0000000000000 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadRelationshipRecordsBackwardsStepTest.java +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) 2002-2016 "Neo Technology," - * Network Engine for Objects in Lund AB [http://neotechnology.com] - * - * This file is part of Neo4j. - * - * Neo4j is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package org.neo4j.unsafe.impl.batchimport; - -import org.junit.Test; - -import java.util.Arrays; -import java.util.function.Predicate; -import java.util.stream.Stream; - -import org.neo4j.kernel.impl.store.RelationshipStore; -import org.neo4j.kernel.impl.store.id.IdGeneratorImpl; -import org.neo4j.kernel.impl.store.record.RelationshipRecord; -import org.neo4j.unsafe.impl.batchimport.staging.StageControl; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.mockito.Mockito.mock; -import static org.mockito.Mockito.when; - -public class ReadRelationshipRecordsBackwardsStepTest -{ - @Test - public void reservedIdIsSkipped() - { - long highId = 5; - int batchSize = (int) highId; - RelationshipStore store = StoreWithReservedId.newRelationshipStoreMock( highId ); - when( store.getHighId() ).thenReturn( highId ); - - ReadRelationshipRecordsBackwardsStep step = new ReadRelationshipRecordsBackwardsStep( - mock( StageControl.class ), Configuration.DEFAULT, store, 0 ); - - Object batch = step.nextBatchOrNull( 0, batchSize ); - - assertNotNull( batch ); - - RelationshipRecord[] records = (RelationshipRecord[]) batch; - boolean hasRecordWithReservedId = Stream.of( records ).anyMatch( recordWithReservedId() ); - assertFalse( "Batch contains record with reserved id " + Arrays.toString( records ), hasRecordWithReservedId ); - } - - private static Predicate recordWithReservedId() - { - return record -> record.getId() == IdGeneratorImpl.INTEGER_MINUS_ONE; - } -} diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStepTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStepTest.java index 8d88df33e8e77..8f9cccae39c39 100644 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStepTest.java +++ b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/UpdateRecordsStepTest.java @@ -72,7 +72,9 @@ public void recordWithReservedIdIsSkipped() throws Throwable UpdateRecordsStep step = new UpdateRecordsStep<>( stageControl, Configuration.DEFAULT, store ); NodeRecord node1 = new NodeRecord( 1 ); + node1.setInUse( true ); NodeRecord node2 = new NodeRecord( 2 ); + node2.setInUse( true ); NodeRecord nodeWithReservedId = new NodeRecord( IdGeneratorImpl.INTEGER_MINUS_ONE ); NodeRecord[] batch = {node1, node2, nodeWithReservedId}; diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/cache/NodeRelationshipCacheTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/cache/NodeRelationshipCacheTest.java index fbd5296d10505..81b836fe15949 100644 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/cache/NodeRelationshipCacheTest.java +++ b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/cache/NodeRelationshipCacheTest.java @@ -266,7 +266,6 @@ public void shouldVisitChangedNodes() throws Exception if ( random.nextBoolean() ) { cache.incrementCount( nodeId ); - System.out.println( nodeId + " is dense" ); } } cache.setHighNodeId( nodes ); @@ -278,7 +277,6 @@ public void shouldVisitChangedNodes() throws Exception cache.getAndPutRelationship( nodeId, Direction.OUTGOING, random.nextLong( 1_000_000 ), false ); boolean dense = cache.isDense( nodeId ); (dense ? keyDenseChanged : keySparseChanged).add( nodeId ); - System.out.println( nodeId + " changed" ); } { diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/InputCacheTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/InputCacheTest.java index f7bcfd0029776..9e448df10bffd 100644 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/InputCacheTest.java +++ b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/InputCacheTest.java @@ -136,10 +136,6 @@ private void assertNoFilesLeftBehind() private void assertRelationshipsEquals( InputRelationship expectedRelationship, InputRelationship relationship ) { - if ( expectedRelationship.hasSpecificId() ) - { - assertEquals( expectedRelationship.specificId(), relationship.specificId() ); - } assertProperties( expectedRelationship, relationship ); assertEquals( expectedRelationship.startNode(), relationship.startNode() ); assertEquals( expectedRelationship.startNodeGroup(), relationship.startNodeGroup() ); diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInputTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInputTest.java index 855ea236cd10b..fd932b5fedf5b 100644 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInputTest.java +++ b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/input/csv/CsvInputTest.java @@ -871,7 +871,6 @@ private void assertRelationship( InputRelationship relationship, Group endNodeGroup, Object endNode, String type, Object[] properties ) { - assertFalse( relationship.hasSpecificId() ); assertEquals( startNodeGroup, relationship.startNodeGroup() ); assertEquals( startNode, relationship.startNode() ); assertEquals( endNodeGroup.id(), relationship.endNodeGroup().id() ); diff --git a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStepTest.java b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStepTest.java similarity index 80% rename from community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStepTest.java rename to community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStepTest.java index eb805bd8a6913..6d9557037bb3f 100644 --- a/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/ReadNodeRecordsStepTest.java +++ b/community/kernel/src/test/java/org/neo4j/unsafe/impl/batchimport/staging/ReadRecordsStepTest.java @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -package org.neo4j.unsafe.impl.batchimport; +package org.neo4j.unsafe.impl.batchimport.staging; import org.junit.Test; @@ -28,6 +28,8 @@ import org.neo4j.kernel.impl.store.NodeStore; import org.neo4j.kernel.impl.store.id.IdGeneratorImpl; import org.neo4j.kernel.impl.store.record.NodeRecord; +import org.neo4j.unsafe.impl.batchimport.StoreWithReservedId; +import org.neo4j.unsafe.impl.batchimport.staging.ReadRecordsStep; import org.neo4j.unsafe.impl.batchimport.staging.StageControl; import static org.junit.Assert.assertFalse; @@ -35,7 +37,10 @@ import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; -public class ReadNodeRecordsStepTest +import static org.neo4j.unsafe.impl.batchimport.Configuration.DEFAULT; +import static org.neo4j.unsafe.impl.batchimport.RecordIdIteration.allIn; + +public class ReadRecordsStepTest { @Test public void reservedIdIsSkipped() @@ -45,7 +50,8 @@ public void reservedIdIsSkipped() NodeStore store = StoreWithReservedId.newNodeStoreMock( highId ); when( store.getHighId() ).thenReturn( highId ); - ReadNodeRecordsStep step = new ReadNodeRecordsStep( mock( StageControl.class ), Configuration.DEFAULT, store ); + ReadRecordsStep step = new ReadRecordsStep<>( mock( StageControl.class ), DEFAULT, + store, allIn( store ) ); Object batch = step.nextBatchOrNull( 0, batchSize ); diff --git a/community/neo4j/src/test/java/schema/MultipleIndexPopulationStressIT.java b/community/neo4j/src/test/java/schema/MultipleIndexPopulationStressIT.java index a176b32f70412..874d42d016dc6 100644 --- a/community/neo4j/src/test/java/schema/MultipleIndexPopulationStressIT.java +++ b/community/neo4j/src/test/java/schema/MultipleIndexPopulationStressIT.java @@ -372,12 +372,6 @@ public RandomDataInput( int count ) this.count = count; } - @Override - public boolean specificRelationshipIds() - { - return false; - } - @Override public InputIterable relationships() { diff --git a/stresstests/src/test/java/org/neo4j/kernel/stresstests/transaction/checkpoint/NodeCountInputs.java b/stresstests/src/test/java/org/neo4j/kernel/stresstests/transaction/checkpoint/NodeCountInputs.java index b558ed27da8cd..2055b557622f0 100644 --- a/stresstests/src/test/java/org/neo4j/kernel/stresstests/transaction/checkpoint/NodeCountInputs.java +++ b/stresstests/src/test/java/org/neo4j/kernel/stresstests/transaction/checkpoint/NodeCountInputs.java @@ -114,12 +114,6 @@ public IdGenerator idGenerator() return IdGenerators.startingFromTheBeginning(); } - @Override - public boolean specificRelationshipIds() - { - return true; - } - @Override public Collector badCollector() {