mirror of
https://github.com/bisq-network/bisq.git
synced 2025-02-23 23:06:39 +01:00
Add logs for expired storage data
This commit is contained in:
parent
f1df5af69e
commit
1635e414fa
1 changed files with 5 additions and 2 deletions
|
@ -170,7 +170,7 @@ public class P2PDataStorage implements MessageListener, ConnectionListener, Pers
|
|||
ProtectedStorageEntry protectedStorageEntry = map.get(hashOfPayload);
|
||||
if (!(protectedStorageEntry.getProtectedStoragePayload() instanceof PersistableNetworkPayload)) {
|
||||
toRemoveSet.add(protectedStorageEntry);
|
||||
log.debug("We found an expired data entry. We remove the protectedData:\n\t" + Utilities.toTruncatedString(protectedStorageEntry));
|
||||
log.info("We found an expired data entry. We remove the protectedDataPayload:\n\t" + Utilities.toTruncatedString(protectedStorageEntry.getProtectedStoragePayload(), 100));
|
||||
map.remove(hashOfPayload);
|
||||
}
|
||||
});
|
||||
|
@ -255,8 +255,11 @@ public class P2PDataStorage implements MessageListener, ConnectionListener, Pers
|
|||
// TODO investigate what causes the disconnections.
|
||||
// Usually the are: SOCKET_TIMEOUT ,TERMINATED (EOFException)
|
||||
protectedData.backDate();
|
||||
if (protectedData.isExpired())
|
||||
if (protectedData.isExpired()) {
|
||||
log.warn("We found an expired data entry which we have already back dated. " +
|
||||
"We remove the protectedStoragePayload:\n\t" + Utilities.toTruncatedString(protectedData.getProtectedStoragePayload(), 100));
|
||||
doRemoveProtectedExpirableData(protectedData, hashOfPayload);
|
||||
}
|
||||
} else {
|
||||
log.debug("Remove data ignored as we don't have an entry for that data.");
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue