More singleton marking.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5160 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -23,6 +23,8 @@ package com.threerings.admin.server;
|
|||||||
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
|
||||||
|
import com.google.inject.Singleton;
|
||||||
|
|
||||||
import com.samskivert.io.PersistenceException;
|
import com.samskivert.io.PersistenceException;
|
||||||
import com.samskivert.jdbc.WriteOnlyUnit;
|
import com.samskivert.jdbc.WriteOnlyUnit;
|
||||||
import com.samskivert.jdbc.depot.PersistenceContext;
|
import com.samskivert.jdbc.depot.PersistenceContext;
|
||||||
@@ -42,6 +44,7 @@ import static com.threerings.admin.Log.log;
|
|||||||
* data from the database. This ensures that systems initialized after the config registry can
|
* data from the database. This ensures that systems initialized after the config registry can
|
||||||
* safely make use of configuration information.
|
* safely make use of configuration information.
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class DatabaseConfigRegistry extends ConfigRegistry
|
public class DatabaseConfigRegistry extends ConfigRegistry
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -23,6 +23,8 @@ package com.threerings.admin.server;
|
|||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
import com.google.inject.Singleton;
|
||||||
|
|
||||||
import com.samskivert.io.PersistenceException;
|
import com.samskivert.io.PersistenceException;
|
||||||
import com.samskivert.jdbc.depot.PersistenceContext;
|
import com.samskivert.jdbc.depot.PersistenceContext;
|
||||||
import com.samskivert.util.Invoker;
|
import com.samskivert.util.Invoker;
|
||||||
@@ -41,6 +43,7 @@ import static com.threerings.admin.Log.log;
|
|||||||
* A database backed config registry that registers with the peer system and synchronizes with its
|
* A database backed config registry that registers with the peer system and synchronizes with its
|
||||||
* peers when configuration fields are changed.
|
* peers when configuration fields are changed.
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class PeeredDatabaseConfigRegistry extends DatabaseConfigRegistry
|
public class PeeredDatabaseConfigRegistry extends DatabaseConfigRegistry
|
||||||
{
|
{
|
||||||
public PeeredDatabaseConfigRegistry (PersistenceContext ctx, Invoker invoker,
|
public PeeredDatabaseConfigRegistry (PersistenceContext ctx, Invoker invoker,
|
||||||
|
|||||||
@@ -21,13 +21,17 @@
|
|||||||
|
|
||||||
package com.threerings.admin.server;
|
package com.threerings.admin.server;
|
||||||
|
|
||||||
|
import com.google.inject.Singleton;
|
||||||
|
|
||||||
import com.samskivert.util.PrefsConfig;
|
import com.samskivert.util.PrefsConfig;
|
||||||
|
|
||||||
import com.threerings.presents.dobj.DObject;
|
import com.threerings.presents.dobj.DObject;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Implements the {@link ConfigRegistry} using the Java preferences system as a persistent store
|
* Implements the {@link ConfigRegistry} using the Java preferences system as a persistent store
|
||||||
* for the configuration information (see {@link Config} for more information on how that works).
|
* for the configuration information (see {@link Config} for more information on how that works).
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class PrefsConfigRegistry extends ConfigRegistry
|
public class PrefsConfigRegistry extends ConfigRegistry
|
||||||
{
|
{
|
||||||
@Override // from ConfigRegistry
|
@Override // from ConfigRegistry
|
||||||
|
|||||||
@@ -23,19 +23,24 @@ package com.threerings.bureau.server;
|
|||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import com.threerings.bureau.data.AgentObject;
|
|
||||||
import com.threerings.bureau.data.BureauCodes;
|
import com.google.common.collect.Maps;
|
||||||
import com.threerings.bureau.data.BureauCredentials;
|
import com.google.common.collect.Sets;
|
||||||
import com.threerings.presents.data.ClientObject;
|
import com.google.inject.Singleton;
|
||||||
import com.threerings.presents.dobj.RootDObjectManager;
|
|
||||||
import com.threerings.presents.dobj.ObjectDeathListener;
|
|
||||||
import com.threerings.presents.dobj.ObjectDestroyedEvent;
|
|
||||||
import com.threerings.presents.server.InvocationManager;
|
|
||||||
import com.samskivert.util.StringUtil;
|
import com.samskivert.util.StringUtil;
|
||||||
import com.samskivert.util.Invoker;
|
import com.samskivert.util.Invoker;
|
||||||
import com.samskivert.util.ProcessLogger;
|
import com.samskivert.util.ProcessLogger;
|
||||||
import com.google.common.collect.Maps;
|
|
||||||
import com.google.common.collect.Sets;
|
import com.threerings.presents.data.ClientObject;
|
||||||
|
import com.threerings.presents.dobj.ObjectDeathListener;
|
||||||
|
import com.threerings.presents.dobj.ObjectDestroyedEvent;
|
||||||
|
import com.threerings.presents.dobj.RootDObjectManager;
|
||||||
|
import com.threerings.presents.server.InvocationManager;
|
||||||
|
|
||||||
|
import com.threerings.bureau.data.AgentObject;
|
||||||
|
import com.threerings.bureau.data.BureauCodes;
|
||||||
|
import com.threerings.bureau.data.BureauCredentials;
|
||||||
|
|
||||||
import static com.threerings.bureau.Log.log;
|
import static com.threerings.bureau.Log.log;
|
||||||
|
|
||||||
@@ -43,6 +48,7 @@ import static com.threerings.bureau.Log.log;
|
|||||||
* Abstracts the launching and termination of external processes (bureaus) that host instances of
|
* Abstracts the launching and termination of external processes (bureaus) that host instances of
|
||||||
* server-side code (agents).
|
* server-side code (agents).
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class BureauRegistry
|
public class BureauRegistry
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ package com.threerings.crowd.chat.server;
|
|||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
|
|
||||||
import com.google.inject.Inject;
|
import com.google.inject.Inject;
|
||||||
|
import com.google.inject.Singleton;
|
||||||
|
|
||||||
import com.samskivert.util.StringUtil;
|
import com.samskivert.util.StringUtil;
|
||||||
import com.threerings.util.MessageBundle;
|
import com.threerings.util.MessageBundle;
|
||||||
@@ -53,6 +54,7 @@ import com.threerings.crowd.chat.data.UserMessage;
|
|||||||
/**
|
/**
|
||||||
* The chat provider handles the server side of the chat-related invocation services.
|
* The chat provider handles the server side of the chat-related invocation services.
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class ChatProvider
|
public class ChatProvider
|
||||||
implements InvocationProvider
|
implements InvocationProvider
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ import java.util.Iterator;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.google.inject.Inject;
|
import com.google.inject.Inject;
|
||||||
|
import com.google.inject.Singleton;
|
||||||
|
|
||||||
import com.samskivert.util.IntMap;
|
import com.samskivert.util.IntMap;
|
||||||
import com.samskivert.util.IntMaps;
|
import com.samskivert.util.IntMaps;
|
||||||
@@ -46,6 +47,7 @@ import static com.threerings.crowd.Log.log;
|
|||||||
* create new places and it will take care of instantiating and initializing a place manager to
|
* create new places and it will take care of instantiating and initializing a place manager to
|
||||||
* manage newly created places.
|
* manage newly created places.
|
||||||
*/
|
*/
|
||||||
|
@Singleton
|
||||||
public class PlaceRegistry
|
public class PlaceRegistry
|
||||||
implements ShutdownManager.Shutdowner
|
implements ShutdownManager.Shutdowner
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user