Search in sources :

Example 11 with ScopedInterningLayer

use of com.apple.foundationdb.record.provider.foundationdb.layers.interning.ScopedInterningLayer in project fdb-record-layer by FoundationDB.

the class InterningLayerToInterningLayerReplicaTest method setup.

@BeforeEach
public void setup() {
    try (FDBRecordContext context = database.openContext()) {
        primary = new ScopedInterningLayer(database, keySpace.path("test-path").add("to").add("primary").toResolvedPath(context));
        replica = new ScopedInterningLayer(database, keySpace.path("test-path").add("to").add("replica").toResolvedPath(context));
    }
    seedWithMetadata = true;
}
Also used : FDBRecordContext(com.apple.foundationdb.record.provider.foundationdb.FDBRecordContext) ScopedInterningLayer(com.apple.foundationdb.record.provider.foundationdb.layers.interning.ScopedInterningLayer) BeforeEach(org.junit.jupiter.api.BeforeEach)

Aggregations

FDBRecordContext (com.apple.foundationdb.record.provider.foundationdb.FDBRecordContext)11 ScopedInterningLayer (com.apple.foundationdb.record.provider.foundationdb.layers.interning.ScopedInterningLayer)11 Test (org.junit.jupiter.api.Test)8 BeforeEach (org.junit.jupiter.api.BeforeEach)4 FDBDatabase (com.apple.foundationdb.record.provider.foundationdb.FDBDatabase)3 FDBDatabaseFactory (com.apple.foundationdb.record.provider.foundationdb.FDBDatabaseFactory)2 FDBTestBase (com.apple.foundationdb.record.provider.foundationdb.FDBTestBase)2 Tuple (com.apple.foundationdb.tuple.Tuple)2 Tags (com.apple.test.Tags)2 List (java.util.List)2 Random (java.util.Random)2 CompletableFuture (java.util.concurrent.CompletableFuture)2 Transaction (com.apple.foundationdb.Transaction)1 AsyncUtil (com.apple.foundationdb.async.AsyncUtil)1 EndpointType (com.apple.foundationdb.record.EndpointType)1 ExecuteProperties (com.apple.foundationdb.record.ExecuteProperties)1 RecordCoreArgumentException (com.apple.foundationdb.record.RecordCoreArgumentException)1 RecordCursor (com.apple.foundationdb.record.RecordCursor)1 ScanProperties (com.apple.foundationdb.record.ScanProperties)1 TestHelpers.assertThrows (com.apple.foundationdb.record.TestHelpers.assertThrows)1