mirror of
https://github.com/bisq-network/bisq.git
synced 2024-11-19 01:41:11 +01:00
Change log level to debug for non-essential logs
Set loge level for org.berndpruenster.netlayer.tor.Tor to WARN (we get repeated logs about HS announced to network from netlayer - would be better to change in netlayer). Make data request/response logs more visible with line breaks
This commit is contained in:
parent
65a020ad7f
commit
8ee67e555d
@ -6,6 +6,8 @@
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<!-- <logger name="org.bitcoinj" level="WARN"/>-->
|
||||
<logger name="org.berndpruenster.netlayer.tor.Tor" level="WARN"/>
|
||||
<root level="TRACE">
|
||||
<appender-ref ref="CONSOLE_APPENDER"/>
|
||||
</root>
|
||||
|
@ -142,7 +142,7 @@ class RequestDataHandler implements MessageListener {
|
||||
}
|
||||
|
||||
getDataRequestType = getDataRequest.getClass().getSimpleName();
|
||||
log.info("We send a {} to peer {}. ", getDataRequestType, nodeAddress);
|
||||
log.info("\n\n>> We send a {} to peer {}\n", getDataRequestType, nodeAddress);
|
||||
networkNode.addMessageListener(this);
|
||||
SettableFuture<Connection> future = networkNode.sendMessage(nodeAddress, getDataRequest);
|
||||
//noinspection UnstableApiUsage
|
||||
@ -242,7 +242,7 @@ class RequestDataHandler implements MessageListener {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
String sep = System.lineSeparator();
|
||||
sb.append(sep).append("#################################################################").append(sep);
|
||||
sb.append("Connected to node: ").append(peersNodeAddress.getFullAddress()).append(sep);
|
||||
sb.append("Data provided by node: ").append(peersNodeAddress.getFullAddress()).append(sep);
|
||||
int items = dataSet.size() + persistableNetworkPayloadSet.size();
|
||||
sb.append("Received ").append(items).append(" instances from a ")
|
||||
.append(getDataRequestType).append(sep);
|
||||
@ -252,7 +252,7 @@ class RequestDataHandler implements MessageListener {
|
||||
.append(" / ")
|
||||
.append(Utilities.readableFileSize(value.second.get()))
|
||||
.append(sep));
|
||||
sb.append("#################################################################");
|
||||
sb.append("#################################################################\n");
|
||||
log.info(sb.toString());
|
||||
}
|
||||
|
||||
|
@ -126,7 +126,7 @@ public final class GetDataResponse extends NetworkEnvelope implements SupportedC
|
||||
NetworkProtoResolver resolver,
|
||||
int messageVersion) {
|
||||
boolean wasTruncated = proto.getWasTruncated();
|
||||
log.info("Received a GetDataResponse with {} {}",
|
||||
log.info("\n\n<< Received a GetDataResponse with {} {}\n",
|
||||
Utilities.readableFileSize(proto.getSerializedSize()),
|
||||
wasTruncated ? " (was truncated)" : "");
|
||||
Set<ProtectedStorageEntry> dataSet = proto.getDataSetList().stream()
|
||||
|
@ -145,7 +145,7 @@ public abstract class HistoricalDataStoreService<T extends PersistableNetworkPay
|
||||
@Override
|
||||
protected void readFromResources(String postFix, Runnable completeHandler) {
|
||||
readStore(persisted -> {
|
||||
log.info("We have created the {} store for the live data and filled it with {} entries from the persisted data.",
|
||||
log.debug("We have created the {} store for the live data and filled it with {} entries from the persisted data.",
|
||||
getFileName(), getMapOfLiveData().size());
|
||||
|
||||
// Now we add our historical data stores.
|
||||
@ -185,7 +185,7 @@ public abstract class HistoricalDataStoreService<T extends PersistableNetworkPay
|
||||
persistenceManager.readPersisted(fileName, persisted -> {
|
||||
storesByVersion.put(version, persisted);
|
||||
allHistoricalPayloads.putAll(persisted.getMap());
|
||||
log.info("We have read from {} {} historical items.", fileName, persisted.getMap().size());
|
||||
log.debug("We have read from {} {} historical items.", fileName, persisted.getMap().size());
|
||||
pruneStore(persisted, version);
|
||||
completeHandler.run();
|
||||
},
|
||||
@ -199,11 +199,11 @@ public abstract class HistoricalDataStoreService<T extends PersistableNetworkPay
|
||||
mapOfLiveData.keySet().removeAll(historicalStore.getMap().keySet());
|
||||
int postLive = mapOfLiveData.size();
|
||||
if (preLive > postLive) {
|
||||
log.info("We pruned data from our live data store which are already contained in the historical data store with version {}. " +
|
||||
log.debug("We pruned data from our live data store which are already contained in the historical data store with version {}. " +
|
||||
"The live map had {} entries before pruning and has {} entries afterwards.",
|
||||
version, preLive, postLive);
|
||||
} else {
|
||||
log.info("No pruning from historical data store with version {} was applied", version);
|
||||
log.debug("No pruning from historical data store with version {} was applied", version);
|
||||
}
|
||||
requestPersistence();
|
||||
}
|
||||
|
@ -113,18 +113,18 @@ public abstract class StoreService<T extends PersistableEnvelope> {
|
||||
File destinationFile = new File(Paths.get(absolutePathOfStorageDir, fileName).toString());
|
||||
if (!destinationFile.exists()) {
|
||||
try {
|
||||
log.info("We copy resource to file: resourceFileName={}, destinationFile={}", resourceFileName, destinationFile);
|
||||
log.debug("We copy resource to file: resourceFileName={}, destinationFile={}", resourceFileName, destinationFile);
|
||||
FileUtil.resourceToFile(resourceFileName, destinationFile);
|
||||
return true;
|
||||
} catch (ResourceNotFoundException e) {
|
||||
log.info("Could not find resourceFile " + resourceFileName + ". That is expected if none is provided yet.");
|
||||
log.debug("Could not find resourceFile " + resourceFileName + ". That is expected if none is provided yet.");
|
||||
} catch (Throwable e) {
|
||||
log.error("Could not copy resourceFile " + resourceFileName + " to " +
|
||||
destinationFile.getAbsolutePath() + ".\n" + e.getMessage());
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else {
|
||||
log.info("No resource file was copied. {} exists already.", fileName);
|
||||
log.debug("No resource file was copied. {} exists already.", fileName);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user