mirror of
https://github.com/usatiuk/dhfs.git
synced 2025-10-29 04:57:48 +01:00
remove bump verification
This commit is contained in:
@@ -156,7 +156,7 @@ public class JObject<T extends JObjectData> implements Serializable, Comparable<
|
||||
verifyRefs();
|
||||
}
|
||||
|
||||
public <R> R runReadLocked(ResolutionStrategy resolutionStrategy, ObjectFnRead<T, R> fn) {
|
||||
public <R> R runReadLocked(ResolutionStrategy resolutionStrategy, ObjectFnRead<T, R> fn) {
|
||||
tryResolve(resolutionStrategy);
|
||||
|
||||
_lock.readLock().lock();
|
||||
@@ -211,13 +211,6 @@ public class JObject<T extends JObjectData> implements Serializable, Comparable<
|
||||
var newMetaHash = Objects.hash(_metaPart.metaHash(), newDataHash);
|
||||
var newData = hasLocalCopy();
|
||||
|
||||
if (_resolver.bumpVerification) {
|
||||
if (_dataPart.get() != null && _dataPart.get().assumeUnique())
|
||||
if (!Objects.equals(newDataHash, dataHash))
|
||||
throw new IllegalStateException("Object changed but is assumed immutable: " + getName());
|
||||
// Todo: data check?
|
||||
}
|
||||
|
||||
if (_dataPart.get() != null)
|
||||
_metaPart.narrowClass(_dataPart.get().getClass());
|
||||
|
||||
|
||||
@@ -44,9 +44,6 @@ public class JObjectResolver {
|
||||
@ConfigProperty(name = "dhfs.objects.ref_verification")
|
||||
boolean refVerification;
|
||||
|
||||
@ConfigProperty(name = "dhfs.objects.bump_verification")
|
||||
boolean bumpVerification;
|
||||
|
||||
public <T extends JObjectData> void registerWriteListener(Class<T> klass, WriteListenerFn<T> fn) {
|
||||
_writeListeners.put(klass, fn);
|
||||
}
|
||||
|
||||
@@ -27,7 +27,6 @@ dhfs.objects.writeback.threads=2
|
||||
dhfs.objects.writeback.nursery_limit=-1
|
||||
dhfs.objects.deletion.delay=0
|
||||
dhfs.objects.ref_verification=true
|
||||
dhfs.objects.bump_verification=true
|
||||
dhfs.files.use_hash_for_chunks=false
|
||||
dhfs.objects.autosync.threads=2
|
||||
dhfs.objects.autosync.download-all=false
|
||||
|
||||
Reference in New Issue
Block a user