Author: toad
Date: 2009-03-24 16:06:07 +0000 (Tue, 24 Mar 2009)
New Revision: 26158
Modified:
branches/db4o/freenet/src/freenet/client/async/USKFetcherTag.java
Log:
Logging infrastructure, logging
Modified: branches/db4o/freenet/src/freenet/client/async/USKFetcherTag.java
===================================================================
--- branches/db4o/freenet/src/freenet/client/async/USKFetcherTag.java
2009-03-24 14:16:30 UTC (rev 26157)
+++ branches/db4o/freenet/src/freenet/client/async/USKFetcherTag.java
2009-03-24 16:06:07 UTC (rev 26158)
@@ -5,6 +5,7 @@
import freenet.client.FetchContext;
import freenet.keys.USK;
import freenet.node.RequestClient;
+import freenet.support.LogThresholdCallback;
import freenet.support.Logger;
import freenet.support.io.NativeThread;
@@ -206,7 +207,20 @@
return finished;
}
+ private static volatile boolean logMINOR;
+
+ static {
+ Logger.registerLogThresholdCallback(new LogThresholdCallback() {
+
+ @Override
+ public void shouldUpdate() {
+ logMINOR = Logger.shouldLog(Logger.MINOR, this);
+ }
+ });
+ }
+
public void removeFrom(ObjectContainer container, ClientContext
context) {
+ if(logMINOR) Logger.minor(this, "Removing "+this);
container.activate(origUSK, 5);
origUSK.removeFrom(container);
if(ownFetchContext) {
_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs