public static ConflictDetectionManager createWithNoConflictDetection() { return new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override public ConflictHandler load(TableReference tableReference) throws Exception { return ConflictHandler.IGNORE_ALL; } }); }
@VisibleForTesting static ConflictDetectionManager createWithStaticConflictDetection( Map<TableReference, ConflictHandler> staticMap) { return new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override public ConflictHandler load(TableReference tableReference) throws Exception { return staticMap.getOrDefault( tableReference, ConflictHandler.RETRY_ON_WRITE_WRITE); } }); } }
private static ConflictDetectionManager create(KeyValueService kvs, boolean warmCache) { ConflictDetectionManager conflictDetectionManager = new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override
public static ConflictDetectionManager createWithNoConflictDetection() { return new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override public ConflictHandler load(TableReference tableReference) throws Exception { return ConflictHandler.IGNORE_ALL; } }); }
@VisibleForTesting static ConflictDetectionManager createWithStaticConflictDetection( Map<TableReference, ConflictHandler> staticMap) { return new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override public ConflictHandler load(TableReference tableReference) throws Exception { return staticMap.getOrDefault( tableReference, ConflictHandler.RETRY_ON_WRITE_WRITE); } }); } }
private static ConflictDetectionManager create(KeyValueService kvs, boolean warmCache) { ConflictDetectionManager conflictDetectionManager = new ConflictDetectionManager( new CacheLoader<TableReference, ConflictHandler>() { @Override