com.threerings.admin.server
Class DatabaseConfigRegistry
java.lang.Object
com.threerings.admin.server.ConfigRegistry
com.threerings.admin.server.DatabaseConfigRegistry
- Direct Known Subclasses:
- PeeredDatabaseConfigRegistry
public class DatabaseConfigRegistry
- extends ConfigRegistry
Implements the ConfigRegistry using a JDBC database as a persistent store for the
configuration information. Note: config objects should only be created during server
startup because they will result in synchronous requests to load up the initial configuration
data from the database. This ensures that systems initialized after the config registry can
safely make use of configuration information.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_repo
protected ConfigRepository _repo
_invoker
protected Invoker _invoker
_node
protected String _node
DatabaseConfigRegistry
@Inject
public DatabaseConfigRegistry(PersistenceContext ctx,
Invoker invoker)
- Creates a configuration registry and prepares it for operation.
- Parameters:
ctx - will provide access to our database.invoker - this will be used to perform all database activity (except first time
initialization) so as to avoid blocking the distributed object thread.
DatabaseConfigRegistry
public DatabaseConfigRegistry(PersistenceContext ctx,
Invoker invoker,
boolean transitioning)
- Creates a configuration registry and prepares it for operation.
- Parameters:
ctx - will provide access to our database.invoker - this will be used to perform all database activity (except first time
initialization) so as to avoid blocking the distributed object thread.transitioning - if the values in the database need to be transitioned to a new format
DatabaseConfigRegistry
public DatabaseConfigRegistry(PersistenceContext ctx,
Invoker invoker,
String node)
- Creates a configuration registry and prepares it for operation.
- Parameters:
ctx - will provide access to our database.invoker - this will be used to perform all database activity (except first time
initialization) so as to avoid blocking the distributed object thread.node - if this config registry is accessed by multiple servers which wish to maintain
separate configs, then specify a node for each server
DatabaseConfigRegistry
public DatabaseConfigRegistry(PersistenceContext ctx,
Invoker invoker,
String node,
boolean transitioning)
- Creates a configuration registry and prepares it for operation.
- Parameters:
ctx - will provide access to our database.invoker - this will be used to perform all database activity (except first time
initialization) so as to avoid blocking the distributed object thread.node - if this config registry is accessed by multiple servers which wish to maintain
separate configs, then specify a node for each servertransitioning - if the values in the database need to be transitioned to a new format
createObjectRecord
protected ConfigRegistry.ObjectRecord createObjectRecord(String path,
DObject object)
- Description copied from class:
ConfigRegistry
- Creates an object record derivation that will handle the management of the specified object.
- Specified by:
createObjectRecord in class ConfigRegistry