diff options
author | Eike Stepper | 2010-03-10 05:29:16 +0000 |
---|---|---|
committer | Eike Stepper | 2010-03-10 05:29:16 +0000 |
commit | 1f5d684ecd6de6e24f1bd7c2699193b9b91c0f99 (patch) | |
tree | 437196ed5a2c9bd5230e57de321b29133fe19c46 /plugins | |
parent | 7d380eee863141bb5f44e70d8f07338c34830a4d (diff) | |
download | cdo-1f5d684ecd6de6e24f1bd7c2699193b9b91c0f99.tar.gz cdo-1f5d684ecd6de6e24f1bd7c2699193b9b91c0f99.tar.xz cdo-1f5d684ecd6de6e24f1bd7c2699193b9b91c0f99.zip |
[256936] Support for Offline Mode
https://bugs.eclipse.org/bugs/show_bug.cgi?id=256936
Diffstat (limited to 'plugins')
3 files changed, 12 insertions, 3 deletions
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/CDOServerUtil.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/CDOServerUtil.java index 463e9f27c1..54b6b380cf 100644 --- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/CDOServerUtil.java +++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/CDOServerUtil.java @@ -12,6 +12,7 @@ package org.eclipse.emf.cdo.server; import org.eclipse.emf.cdo.common.revision.CDORevision; import org.eclipse.emf.cdo.internal.server.Repository; +import org.eclipse.emf.cdo.internal.server.SessionManager; import org.eclipse.emf.cdo.internal.server.bundle.OM; import org.eclipse.emf.cdo.internal.server.clone.CloneRepository; import org.eclipse.emf.cdo.internal.server.clone.CloneSynchronizer; @@ -59,6 +60,14 @@ public final class CDOServerUtil return new EmbeddedClientSessionConfiguration(); } + /** + * @since 3.0 + */ + public static ISessionManager createSessionManager() + { + return new SessionManager(); + } + public static IRepository createRepository(String name, IStore store, Map<String, String> props) { Repository repository = new Repository.Default(); diff --git a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/config/impl/RepositoryConfig.java b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/config/impl/RepositoryConfig.java index 12b07c0a2a..6919a89bd3 100644 --- a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/config/impl/RepositoryConfig.java +++ b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/config/impl/RepositoryConfig.java @@ -13,7 +13,6 @@ package org.eclipse.emf.cdo.tests.config.impl; import org.eclipse.emf.cdo.internal.common.revision.CDORevisionManagerImpl; import org.eclipse.emf.cdo.internal.common.revision.cache.noop.NOOPRevisionCache; -import org.eclipse.emf.cdo.internal.server.SessionManager; import org.eclipse.emf.cdo.internal.server.clone.CloneSynchronizer; import org.eclipse.emf.cdo.net4j.CDONet4jUtil; import org.eclipse.emf.cdo.net4j.CDOSessionConfiguration; @@ -164,7 +163,7 @@ public abstract class RepositoryConfig extends Config implements IRepositoryConf IUserManager userManager = getTestUserManager(); if (userManager != null) { - InternalSessionManager sessionManager = new SessionManager(); + InternalSessionManager sessionManager = (InternalSessionManager)CDOServerUtil.createSessionManager(); sessionManager.setUserManager(userManager); repository.setSessionManager(sessionManager); } diff --git a/plugins/org.eclipse.net4j/src/org/eclipse/net4j/connector/ConnectorCredentialsInjector.java b/plugins/org.eclipse.net4j/src/org/eclipse/net4j/connector/ConnectorCredentialsInjector.java index 9c69a73b3e..d3b74f140d 100644 --- a/plugins/org.eclipse.net4j/src/org/eclipse/net4j/connector/ConnectorCredentialsInjector.java +++ b/plugins/org.eclipse.net4j/src/org/eclipse/net4j/connector/ConnectorCredentialsInjector.java @@ -23,10 +23,11 @@ import org.eclipse.net4j.util.security.SecurityUtil; * * <pre> * IManagedContainer container = IPluginContainer.INSTANCE; - * String connectorDescription = "localhost:2036"; * + * String connectorDescription = "localhost:2036"; * String userID = "name"; * String password = "secret"; + * * IPasswordCredentialsProvider credentialsProvider = new PasswordCredentialsProvider(userID, password); * * container.addPostProcessor(new ConnectorCredentialsInjector(connectorDescription, credentialsProvider)); |