Revert "Avoid a concrete dependency on PresentsServer."
This reverts commit 938847bea9.
This didn't turn out to work well enough, so let's avoid unhelpful indirection.
This commit is contained in:
@@ -47,7 +47,7 @@ import static com.threerings.presents.Log.log;
|
||||
* instance is initialized.
|
||||
*/
|
||||
@Singleton
|
||||
public class PresentsServer implements RebootManager.Rebootable
|
||||
public class PresentsServer
|
||||
{
|
||||
/** Configures dependencies needed by the Presents services. */
|
||||
public static class PresentsModule extends AbstractModule
|
||||
|
||||
@@ -27,15 +27,6 @@ import static com.threerings.presents.Log.log;
|
||||
*/
|
||||
public abstract class RebootManager
|
||||
{
|
||||
/** An interface implemented by the server we're going to shut down. We do this to avoid having
|
||||
* a dependency on PresentsServer directly because that tends to cause cyclic dependencies for
|
||||
* the real servers (like ProjectX) that use Guice to inject dependencies. */
|
||||
public static interface Rebootable {
|
||||
/** Queues up a request to shutdown on the event thread. This method may be safely called
|
||||
* from any thread. */
|
||||
void queueShutdown ();
|
||||
}
|
||||
|
||||
/**
|
||||
* An interface for receiving notifications about pending automated shutdowns.
|
||||
*/
|
||||
@@ -172,7 +163,7 @@ public abstract class RebootManager
|
||||
/**
|
||||
* Provides us with our dependencies.
|
||||
*/
|
||||
protected RebootManager (Rebootable server, RootDObjectManager omgr)
|
||||
protected RebootManager (PresentsServer server, RootDObjectManager omgr)
|
||||
{
|
||||
_server = server;
|
||||
_omgr = omgr;
|
||||
@@ -342,7 +333,7 @@ public abstract class RebootManager
|
||||
}
|
||||
|
||||
/** The server that we're going to reboot. */
|
||||
protected Rebootable _server;
|
||||
protected PresentsServer _server;
|
||||
|
||||
/** Our distributed object manager. */
|
||||
protected RootDObjectManager _omgr;
|
||||
|
||||
Reference in New Issue
Block a user