Author: toad
Date: 2008-01-18 15:52:27 +0000 (Fri, 18 Jan 2008)
New Revision: 17148
Modified:
trunk/freenet/src/freenet/node/NodeClientCore.java
Log:
Tell user if the node is still starting up.
Modified: trunk/freenet/src/freenet/node/NodeClientCore.java
===================================================================
--- trunk/freenet/src/freenet/node/NodeClientCore.java 2008-01-18 15:41:10 UTC
(rev 17147)
+++ trunk/freenet/src/freenet/node/NodeClientCore.java 2008-01-18 15:52:27 UTC
(rev 17148)
@@ -41,6 +41,8 @@
import freenet.keys.SSKVerifyException;
import freenet.l10n.L10n;
import freenet.node.fcp.FCPServer;
+import freenet.node.useralerts.SimpleUserAlert;
+import freenet.node.useralerts.UserAlert;
import freenet.node.useralerts.UserAlertManager;
import freenet.store.KeyCollisionException;
import freenet.support.Base64;
@@ -112,6 +114,8 @@
static final long MAX_ARCHIVE_SIZE = 2*1024*1024; // ??? FIXME
static final long MAX_ARCHIVED_FILE_SIZE = 1024*1024; // arbitrary...
FIXME
static final int MAX_CACHED_ELEMENTS = 256*1024; // equally arbitrary!
FIXME hopefully we can cache many of these though
+
+ private UserAlert startingUpAlert;
NodeClientCore(Node node, Config config, SubConfig nodeConfig, File
nodeDir, int portNumber, int sortOrder, SimpleFieldSet oldThrottleFS,
SimpleFieldSet oldConfig, SubConfig fproxyConfig, SimpleToadletServer toadlets)
throws NodeInitException {
this.node = node;
@@ -349,6 +353,7 @@
// FProxy
// FIXME this is a hack, the real way to do this is plugins
+ this.alerts.register(startingUpAlert = new
SimpleUserAlert(true, l10n("startingUpTitle"), l10n("startingUp"),
UserAlert.MINOR));
try {
toadletContainer = toadlets;
toadletContainer.setCore(this);
@@ -427,6 +432,7 @@
persistentTempBucketFactory.completedInit();
System.out.println("Completed startup: All
persistent requests resumed or restarted");
Logger.normal(this, "Completed startup: All
persistent requests resumed or restarted");
+ alerts.unregister(startingUpAlert);
}
}, "Startup completion thread");
}