use of org.apache.jackrabbit.oak.plugins.blob.datastore.BlobTracker in project jackrabbit-oak by apache.
the class AbstractBlobTrackerRegistrationTest method reRegisterBlobTrackingStore.
@Test
public void reRegisterBlobTrackingStore() throws Exception {
registerNodeStoreService();
assertServiceNotActivated();
registerTrackingBlobStore();
assertServiceActivated();
BlobStore blobStore = context.getService(BlobStore.class);
assertTrue(blobStore instanceof BlobTrackingStore);
BlobTrackingStore trackingStore = (BlobTrackingStore) blobStore;
assertNotNull(trackingStore.getTracker());
BlobTracker oldTracker = trackingStore.getTracker();
unregisterNodeStoreService();
registerNodeStoreService();
blobStore = context.getService(BlobStore.class);
trackingStore = (BlobTrackingStore) blobStore;
BlobTracker newTracker = trackingStore.getTracker();
assertNotEquals(oldTracker, newTracker);
assertTrackerReinitialized();
}
Aggregations