summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2007-08-13 04:18:44 (EDT)
committerEike Stepper2007-08-13 04:18:44 (EDT)
commit167eedf06e47d5bfa7e4aed9054ede183d86949c (patch)
tree6125125cd5b514c2360b84ca0919c08f39cc97f9
parent8169bfc820d25e8644750c7f7857f97f2e664db5 (diff)
downloadcdo-167eedf06e47d5bfa7e4aed9054ede183d86949c.zip
cdo-167eedf06e47d5bfa7e4aed9054ede183d86949c.tar.gz
cdo-167eedf06e47d5bfa7e4aed9054ede183d86949c.tar.bz2
*** empty log message ***
-rw-r--r--plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStore.java5
-rw-r--r--plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStoreFactory.java39
-rw-r--r--plugins/org.eclipse.emf.cdo.server/plugin.xml8
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ContainerRepositoryProvider.java29
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PackageManager.java (renamed from plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryPackageManager.java)5
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PluginRepositoryProvider.java16
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Repository.java54
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryFactory.java39
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryManager.java132
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ResourceManager.java3
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Session.java59
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/SessionManager.java20
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/View.java8
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/bundle/OM.java13
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOPluginProtocolFactory.java14
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerIndication.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocol.java11
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocolFactory.java15
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CommitTransactionIndication.java4
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/LoadPackageIndication.java4
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/OpenSessionIndication.java17
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/AddPackageOperation.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/NOOPStore.java5
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/Store.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/StoreFactory.java28
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/CDOServerUtil.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IPackageManager.java (renamed from plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionViewsEvent.java)5
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepository.java7
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryElement.java19
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryManager.java36
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryProvider.java19
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IResourceManager.java5
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRevisionManager.java3
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionManager.java6
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/CDO UI.launch138
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/config/cdo.server.xml21
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/config/org.eclipse.emf.cdo.server.db.properties6
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/bundle/OM.java25
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOEventHandler.java8
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOItemProvider.java2
-rw-r--r--plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOSessionsView.java8
-rw-r--r--plugins/org.eclipse.net4j.debug/src/org/eclipse/net4j/internal/debug/views/IntrospectorView.java13
-rw-r--r--plugins/org.eclipse.net4j.jms/src/org/eclipse/net4j/internal/jms/bundle/OM.java4
-rw-r--r--plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/AcceptorsView.java8
-rw-r--r--plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/ConnectorsView.java6
-rw-r--r--plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/internal/ui/views/Net4jContainerView.java4
-rw-r--r--plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/StructuredContentProvider.java31
-rw-r--r--plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/views/ContainerItemProvider.java23
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/bundle/OM.java4
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/ManagedContainer.java134
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginContainer.java (renamed from plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginTransportContainer.java)12
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/ReflectUtil.java2
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginContainer.java (renamed from plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginTransportContainer.java)6
-rw-r--r--plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/io/NIOUtil.java2
-rw-r--r--plugins/org.eclipse.net4j/src/org/eclipse/internal/net4j/Channel.java4
55 files changed, 625 insertions, 488 deletions
diff --git a/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStore.java b/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStore.java
index 82bc9ff..dc2e1fa 100644
--- a/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStore.java
+++ b/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStore.java
@@ -12,7 +12,7 @@ package org.eclipse.emf.cdo.server.internal.db;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
import org.eclipse.emf.cdo.internal.protocol.revision.CDORevisionImpl;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.RevisionManager;
import org.eclipse.emf.cdo.internal.server.store.AddPackageOperation;
import org.eclipse.emf.cdo.internal.server.store.AddRevisionOperation;
@@ -58,8 +58,7 @@ public class DBStore extends Store
}
@Override
- protected AddPackageOperation createAddPackageOperation(RepositoryPackageManager packageManager,
- CDOPackageImpl cdoPackage)
+ protected AddPackageOperation createAddPackageOperation(PackageManager packageManager, CDOPackageImpl cdoPackage)
{
return new AddPackageOperation(packageManager, cdoPackage)
{
diff --git a/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStoreFactory.java b/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStoreFactory.java
new file mode 100644
index 0000000..e2daf67
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server.db/src/org/eclipse/emf/cdo/server/internal/db/DBStoreFactory.java
@@ -0,0 +1,39 @@
+/***************************************************************************
+ * Copyright (c) 2004 - 2007 Eike Stepper, Germany.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Eike Stepper - initial API and implementation
+ **************************************************************************/
+package org.eclipse.emf.cdo.server.internal.db;
+
+import org.eclipse.emf.cdo.internal.server.store.StoreFactory;
+
+import org.eclipse.net4j.util.container.IManagedContainer;
+import org.eclipse.net4j.util.factory.ProductCreationException;
+
+/**
+ * @author Eike Stepper
+ */
+public class DBStoreFactory extends StoreFactory<DBStore>
+{
+ public static final String TYPE = "db";
+
+ public DBStoreFactory()
+ {
+ super(TYPE);
+ }
+
+ public DBStore create(String description) throws ProductCreationException
+ {
+ return null;
+ }
+
+ public static DBStore get(IManagedContainer container, String description)
+ {
+ return (DBStore)container.getElement(PRODUCT_GROUP, TYPE, description);
+ }
+}
diff --git a/plugins/org.eclipse.emf.cdo.server/plugin.xml b/plugins/org.eclipse.emf.cdo.server/plugin.xml
index 4aec906..60532a4 100644
--- a/plugins/org.eclipse.emf.cdo.server/plugin.xml
+++ b/plugins/org.eclipse.emf.cdo.server/plugin.xml
@@ -6,9 +6,13 @@
<extension
point="org.eclipse.net4j.util.factories">
<factory
- class="org.eclipse.emf.cdo.internal.server.protocol.CDOServerProtocolFactory"
+ productGroup="org.eclipse.emf.cdo.server.repositories"
+ type="default"
+ class="org.eclipse.emf.cdo.internal.server.RepositoryFactory"/>
+ <factory
productGroup="org.eclipse.net4j.serverProtocols"
- type="cdo"/>
+ type="cdo"
+ class="org.eclipse.emf.cdo.internal.server.protocol.CDOPluginProtocolFactory"/>
</extension>
</plugin>
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ContainerRepositoryProvider.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ContainerRepositoryProvider.java
new file mode 100644
index 0000000..6f5999b
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ContainerRepositoryProvider.java
@@ -0,0 +1,29 @@
+package org.eclipse.emf.cdo.internal.server;
+
+import org.eclipse.emf.cdo.server.IRepository;
+import org.eclipse.emf.cdo.server.IRepositoryProvider;
+
+import org.eclipse.net4j.util.container.IManagedContainer;
+
+/**
+ * @author Eike Stepper
+ */
+public class ContainerRepositoryProvider implements IRepositoryProvider
+{
+ private IManagedContainer container;
+
+ public ContainerRepositoryProvider(IManagedContainer container)
+ {
+ this.container = container;
+ }
+
+ public IManagedContainer getContainer()
+ {
+ return container;
+ }
+
+ public IRepository getRepository(String name)
+ {
+ return RepositoryFactory.get(container, name);
+ }
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryPackageManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PackageManager.java
index 18c6f0a..9c0b9b0 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryPackageManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PackageManager.java
@@ -13,17 +13,18 @@ package org.eclipse.emf.cdo.internal.server;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageManagerImpl;
import org.eclipse.emf.cdo.protocol.CDOIDRange;
+import org.eclipse.emf.cdo.server.IPackageManager;
import org.eclipse.net4j.util.ImplementationError;
/**
* @author Eike Stepper
*/
-public class RepositoryPackageManager extends CDOPackageManagerImpl
+public class PackageManager extends CDOPackageManagerImpl implements IPackageManager
{
private Repository repository;
- public RepositoryPackageManager(Repository repository)
+ public PackageManager(Repository repository)
{
this.repository = repository;
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PluginRepositoryProvider.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PluginRepositoryProvider.java
new file mode 100644
index 0000000..cd57298
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/PluginRepositoryProvider.java
@@ -0,0 +1,16 @@
+package org.eclipse.emf.cdo.internal.server;
+
+import org.eclipse.net4j.util.container.IPluginContainer;
+
+/**
+ * @author Eike Stepper
+ */
+public final class PluginRepositoryProvider extends ContainerRepositoryProvider
+{
+ public static final PluginRepositoryProvider INSTANCE = new PluginRepositoryProvider();
+
+ private PluginRepositoryProvider()
+ {
+ super(IPluginContainer.INSTANCE);
+ }
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Repository.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Repository.java
index 375fc98..c0de8d5 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Repository.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Repository.java
@@ -18,9 +18,10 @@ import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.emf.cdo.protocol.CDOIDRange;
import org.eclipse.emf.cdo.server.IRepository;
-import org.eclipse.net4j.internal.util.lifecycle.Lifecycle;
+import org.eclipse.net4j.internal.util.container.Container;
import org.eclipse.net4j.util.ImplementationError;
+import java.text.MessageFormat;
import java.util.UUID;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
@@ -28,7 +29,7 @@ import java.util.concurrent.ConcurrentMap;
/**
* @author Eike Stepper
*/
-public class Repository extends Lifecycle implements IRepository
+public class Repository extends Container implements IRepository
{
private static final long INITIAL_OID_VALUE = 2;
@@ -40,13 +41,15 @@ public class Repository extends Lifecycle implements IRepository
private String uuid;
- private RepositoryPackageManager packageManager;
+ private PackageManager packageManager = new PackageManager(this);
- private SessionManager sessionManager;
+ private SessionManager sessionManager = new SessionManager(this);
- private ResourceManager resourceManager;
+ private ResourceManager resourceManager = new ResourceManager(this);
- private RevisionManager revisionManager;
+ private RevisionManager revisionManager = new RevisionManager(this);
+
+ private Object[] elements = { packageManager, sessionManager, resourceManager, revisionManager };
private long nextOIDValue = INITIAL_OID_VALUE;
@@ -54,17 +57,10 @@ public class Repository extends Lifecycle implements IRepository
private ConcurrentMap<CDOID, CDOClassRefImpl> types = new ConcurrentHashMap();
- public Repository(String name, Store store)
+ public Repository(String name)
{
this.name = name;
- this.store = store;
- this.uuid = UUID.randomUUID().toString();
- store.setRepository(this);
-
- packageManager = new RepositoryPackageManager(this);
- sessionManager = new SessionManager(this);
- resourceManager = new ResourceManager(this);
- revisionManager = new RevisionManager(this);
+ uuid = UUID.randomUUID().toString();
}
public String getName()
@@ -72,17 +68,22 @@ public class Repository extends Lifecycle implements IRepository
return name;
}
+ public String getUUID()
+ {
+ return uuid;
+ }
+
public Store getStore()
{
return store;
}
- public String getUUID()
+ public void setStore(Store store)
{
- return uuid;
+ this.store = store;
}
- public RepositoryPackageManager getPackageManager()
+ public PackageManager getPackageManager()
{
return packageManager;
}
@@ -102,6 +103,17 @@ public class Repository extends Lifecycle implements IRepository
return revisionManager;
}
+ public Object[] getElements()
+ {
+ return elements;
+ }
+
+ @Override
+ public boolean isEmpty()
+ {
+ return false;
+ }
+
public CDOIDRange getMetaIDRange(long count)
{
long lowerBound = nextMetaIDValue;
@@ -139,4 +151,10 @@ public class Repository extends Lifecycle implements IRepository
{
types.putIfAbsent(id, type);
}
+
+ @Override
+ public String toString()
+ {
+ return MessageFormat.format("Repository[{0}, {1}]", name, uuid);
+ }
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryFactory.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryFactory.java
new file mode 100644
index 0000000..7646dc4
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryFactory.java
@@ -0,0 +1,39 @@
+/***************************************************************************
+ * Copyright (c) 2004-2007 Eike Stepper, Germany.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Eike Stepper - initial API and implementation
+ **************************************************************************/
+package org.eclipse.emf.cdo.internal.server;
+
+import org.eclipse.net4j.internal.util.factory.Factory;
+import org.eclipse.net4j.util.container.IManagedContainer;
+
+/**
+ * @author Eike Stepper
+ */
+public class RepositoryFactory extends Factory<Repository>
+{
+ public static final String PRODUCT_GROUP = "org.eclipse.emf.cdo.server.repositories";
+
+ public static final String TYPE = "default";
+
+ public RepositoryFactory()
+ {
+ super(PRODUCT_GROUP, TYPE);
+ }
+
+ public Repository create(String name)
+ {
+ return new Repository(name);
+ }
+
+ public static Repository get(IManagedContainer container, String name)
+ {
+ return (Repository)container.getElement(PRODUCT_GROUP, TYPE, name);
+ }
+}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryManager.java
deleted file mode 100644
index 892f03e..0000000
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/RepositoryManager.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/***************************************************************************
- * Copyright (c) 2004-2007 Eike Stepper, Germany.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Eike Stepper - initial API and implementation
- **************************************************************************/
-package org.eclipse.emf.cdo.internal.server;
-
-import org.eclipse.emf.cdo.internal.server.bundle.OM;
-import org.eclipse.emf.cdo.internal.server.store.Store;
-import org.eclipse.emf.cdo.server.IRepositoryManager;
-import org.eclipse.emf.cdo.server.IStore;
-import org.eclipse.emf.cdo.server.RepositoryNotFoundException;
-
-import org.eclipse.net4j.internal.util.lifecycle.Lifecycle;
-import org.eclipse.net4j.util.lifecycle.LifecycleUtil;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * @author Eike Stepper
- */
-public final class RepositoryManager extends Lifecycle implements IRepositoryManager
-{
- // @Singleton
- public static final RepositoryManager INSTANCE = new RepositoryManager();
-
- private Map<String, Repository> repositories = new HashMap();
-
- private RepositoryManager()
- {
- }
-
- public String[] getRepositoryNames()
- {
- synchronized (repositories)
- {
- return repositories.keySet().toArray(new String[repositories.size()]);
- }
- }
-
- public Repository[] getRepositories()
- {
- synchronized (repositories)
- {
- return repositories.values().toArray(new Repository[repositories.size()]);
- }
- }
-
- public Repository getRepository(String name) throws RepositoryNotFoundException
- {
- synchronized (repositories)
- {
- Repository repository = repositories.get(name);
- if (repository == null)
- {
- throw new RepositoryNotFoundException(name);
- }
-
- return repository;
- }
- }
-
- public Repository addRepository(String name, IStore store)
- {
- synchronized (repositories)
- {
- Repository repository = repositories.get(name);
- if (repository != null)
- {
- throw new RuntimeException("Repository already exists: " + name);
- }
-
- // TODO Introduce IStoreFactory so that the client doesn't need to create
- // the store on its own
- repository = new Repository(name, (Store)store);
- LifecycleUtil.activate(repository);
- repositories.put(name, repository);
- return repository;
- }
- }
-
- public boolean isEmpty()
- {
- synchronized (repositories)
- {
- return repositories.isEmpty();
- }
- }
-
- public int size()
- {
- synchronized (repositories)
- {
- return repositories.size();
- }
- }
-
- @Override
- protected void doActivate() throws Exception
- {
- super.doActivate();
- }
-
- @Override
- protected void doDeactivate() throws Exception
- {
- synchronized (repositories)
- {
- for (Repository repository : getRepositories())
- {
- try
- {
- LifecycleUtil.deactivate(repository);
- }
- catch (Exception ex)
- {
- OM.LOG.warn(ex);
- }
- }
-
- repositories.clear();
- }
-
- super.doDeactivate();
- }
-}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ResourceManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ResourceManager.java
index 616632b..20d491b 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ResourceManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/ResourceManager.java
@@ -14,6 +14,7 @@ import org.eclipse.emf.cdo.internal.server.bundle.OM;
import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.emf.cdo.server.IResourceManager;
+import org.eclipse.net4j.internal.util.lifecycle.Lifecycle;
import org.eclipse.net4j.internal.util.om.trace.ContextTracer;
import java.util.HashMap;
@@ -22,7 +23,7 @@ import java.util.Map;
/**
* @author Eike Stepper
*/
-public class ResourceManager implements IResourceManager
+public class ResourceManager extends Lifecycle implements IResourceManager
{
private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_SESSION, SessionManager.class);
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Session.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Session.java
index 3d9ab3b..ffa9fc1 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Session.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/Session.java
@@ -20,16 +20,17 @@ import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.protocol.model.CDOClassRef;
import org.eclipse.emf.cdo.server.ISession;
-import org.eclipse.emf.cdo.server.ISessionViewsEvent;
import org.eclipse.emf.cdo.server.IView;
+import org.eclipse.emf.cdo.server.SessionCreationException;
import org.eclipse.emf.cdo.server.IView.Type;
-import org.eclipse.net4j.internal.util.container.SingleDeltaContainerEvent;
-import org.eclipse.net4j.internal.util.event.Notifier;
+import org.eclipse.net4j.internal.util.container.Container;
+import org.eclipse.net4j.internal.util.lifecycle.LifecycleEventAdapter;
import org.eclipse.net4j.util.ImplementationError;
-import org.eclipse.net4j.util.container.IContainerDelta;
-import org.eclipse.net4j.util.container.IContainerDelta.Kind;
+import org.eclipse.net4j.util.event.IListener;
+import org.eclipse.net4j.util.lifecycle.ILifecycle;
+import java.text.MessageFormat;
import java.util.HashSet;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;
@@ -38,7 +39,7 @@ import java.util.concurrent.ConcurrentMap;
/**
* @author Eike Stepper
*/
-public class Session extends Notifier implements ISession, CDOIDProvider
+public class Session extends Container<IView> implements ISession, CDOIDProvider
{
private SessionManager sessionManager;
@@ -50,11 +51,31 @@ public class Session extends Notifier implements ISession, CDOIDProvider
private Set<CDOID> knownObjects = new HashSet();
+ private IListener protocolListener = new LifecycleEventAdapter()
+ {
+ @Override
+ protected void onDeactivated(ILifecycle lifecycle)
+ {
+ deactivate();
+ }
+ };
+
public Session(SessionManager sessionManager, CDOServerProtocol protocol, int sessionID)
+ throws SessionCreationException
{
this.sessionManager = sessionManager;
this.protocol = protocol;
this.sessionID = sessionID;
+
+ protocol.addListener(protocolListener);
+ try
+ {
+ activate();
+ }
+ catch (Exception ex)
+ {
+ throw new SessionCreationException(ex);
+ }
}
public SessionManager getSessionManager()
@@ -77,6 +98,7 @@ public class Session extends Notifier implements ISession, CDOIDProvider
return getViews();
}
+ @Override
public boolean isEmpty()
{
return views.isEmpty();
@@ -94,7 +116,7 @@ public class Session extends Notifier implements ISession, CDOIDProvider
View view = views.remove(viewID);
if (view != null)
{
- fireEvent(new ViewsEvent(view, IContainerDelta.Kind.REMOVED));
+ fireElementRemovedEvent(view);
}
}
else
@@ -102,7 +124,7 @@ public class Session extends Notifier implements ISession, CDOIDProvider
IView.Type viewType = getViewType(kind);
View view = new View(this, viewID, viewType);
views.put(viewID, view);
- fireEvent(new ViewsEvent(view, IContainerDelta.Kind.ADDED));
+ fireElementAddedEvent(view);
}
}
@@ -152,18 +174,17 @@ public class Session extends Notifier implements ISession, CDOIDProvider
return CDOIDImpl.create(id.getValue(), type);
}
- private final class ViewsEvent extends SingleDeltaContainerEvent<IView> implements ISessionViewsEvent
+ @Override
+ public String toString()
{
- private static final long serialVersionUID = 1L;
-
- private ViewsEvent(IView view, Kind kind)
- {
- super(Session.this, view, kind);
- }
+ return MessageFormat.format("Session[{0}, {1}]", sessionID, protocol.getChannel());
+ }
- public IView getView()
- {
- return getDeltaElement();
- }
+ @Override
+ protected void doDeactivate() throws Exception
+ {
+ protocol.removeListener(protocolListener);
+ sessionManager.sessionClosed(this);
+ super.doDeactivate();
}
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/SessionManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/SessionManager.java
index b780911..534c99f 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/SessionManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/SessionManager.java
@@ -13,9 +13,11 @@ package org.eclipse.emf.cdo.internal.server;
import org.eclipse.emf.cdo.internal.protocol.revision.CDORevisionImpl;
import org.eclipse.emf.cdo.internal.server.bundle.OM;
import org.eclipse.emf.cdo.internal.server.protocol.CDOServerProtocol;
+import org.eclipse.emf.cdo.server.ISession;
import org.eclipse.emf.cdo.server.ISessionManager;
import org.eclipse.emf.cdo.server.SessionCreationException;
+import org.eclipse.net4j.internal.util.container.Container;
import org.eclipse.net4j.internal.util.om.trace.ContextTracer;
import java.util.HashMap;
@@ -24,7 +26,7 @@ import java.util.Map;
/**
* @author Eike Stepper
*/
-public class SessionManager implements ISessionManager
+public class SessionManager extends Container<ISession> implements ISessionManager
{
private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_SESSION, SessionManager.class);
@@ -52,6 +54,20 @@ public class SessionManager implements ISessionManager
}
}
+ public ISession[] getElements()
+ {
+ return getSessions();
+ }
+
+ @Override
+ public boolean isEmpty()
+ {
+ synchronized (sessions)
+ {
+ return sessions.isEmpty();
+ }
+ }
+
public Session openSession(CDOServerProtocol protocol) throws SessionCreationException
{
int id = ++lastSessionID;
@@ -66,11 +82,13 @@ public class SessionManager implements ISessionManager
sessions.put(id, session);
}
+ fireElementAddedEvent(session);
return session;
}
public void sessionClosed(Session session)
{
+ fireElementRemovedEvent(session);
}
public void notifyInvalidation(long timeStamp, CDORevisionImpl[] dirtyObjects, Session excludedSession)
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/View.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/View.java
index e78ca12..aaf0b22 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/View.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/View.java
@@ -12,6 +12,8 @@ package org.eclipse.emf.cdo.internal.server;
import org.eclipse.emf.cdo.server.IView;
+import java.text.MessageFormat;
+
/**
* @author Eike Stepper
*/
@@ -44,4 +46,10 @@ public class View implements IView
{
return viewType;
}
+
+ @Override
+ public String toString()
+ {
+ return MessageFormat.format("View({0}, {1})", viewID, viewType);
+ }
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/bundle/OM.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/bundle/OM.java
index 514e26f..f5d1be4 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/bundle/OM.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/bundle/OM.java
@@ -10,9 +10,6 @@
**************************************************************************/
package org.eclipse.emf.cdo.internal.server.bundle;
-import org.eclipse.emf.cdo.server.IRepositoryManager;
-
-import org.eclipse.net4j.util.lifecycle.LifecycleUtil;
import org.eclipse.net4j.util.om.OMBundle;
import org.eclipse.net4j.util.om.OMPlatform;
import org.eclipse.net4j.util.om.OSGiActivator;
@@ -44,16 +41,6 @@ public abstract class OM
public static final OMLogger LOG = BUNDLE.logger();
- static void start() throws Exception
- {
- LifecycleUtil.activate(IRepositoryManager.INSTANCE);
- }
-
- static void stop() throws Exception
- {
- LifecycleUtil.deactivate(IRepositoryManager.INSTANCE);
- }
-
/**
* @author Eike Stepper
*/
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOPluginProtocolFactory.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOPluginProtocolFactory.java
new file mode 100644
index 0000000..cc94e11
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOPluginProtocolFactory.java
@@ -0,0 +1,14 @@
+package org.eclipse.emf.cdo.internal.server.protocol;
+
+import org.eclipse.emf.cdo.internal.server.PluginRepositoryProvider;
+
+/**
+ * @author Eike Stepper
+ */
+public final class CDOPluginProtocolFactory extends CDOServerProtocolFactory
+{
+ public CDOPluginProtocolFactory()
+ {
+ super(PluginRepositoryProvider.INSTANCE);
+ }
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerIndication.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerIndication.java
index 63a2ec2..da4e7ab 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerIndication.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerIndication.java
@@ -11,7 +11,7 @@
package org.eclipse.emf.cdo.internal.server.protocol;
import org.eclipse.emf.cdo.internal.server.Repository;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.ResourceManager;
import org.eclipse.emf.cdo.internal.server.RevisionManager;
import org.eclipse.emf.cdo.internal.server.Session;
@@ -40,7 +40,7 @@ public abstract class CDOServerIndication extends IndicationWithResponse
return signalID;
}
- protected RepositoryPackageManager getPackageManager()
+ protected PackageManager getPackageManager()
{
return getRepository().getPackageManager();
}
@@ -83,7 +83,7 @@ public abstract class CDOServerIndication extends IndicationWithResponse
protected void transact(Runnable runnable) throws TransactionException
{
- TX.begin(getStore().createTransaction());
+ TX.begin();
try
{
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocol.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocol.java
index 64e0b32..f0fa322 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocol.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocol.java
@@ -12,6 +12,7 @@ package org.eclipse.emf.cdo.internal.server.protocol;
import org.eclipse.emf.cdo.internal.server.Session;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
+import org.eclipse.emf.cdo.server.IRepositoryProvider;
import org.eclipse.net4j.signal.SignalProtocol;
import org.eclipse.net4j.signal.SignalReactor;
@@ -21,10 +22,13 @@ import org.eclipse.net4j.signal.SignalReactor;
*/
public class CDOServerProtocol extends SignalProtocol
{
+ private IRepositoryProvider repositoryProvider;
+
private Session session;
- public CDOServerProtocol()
+ public CDOServerProtocol(IRepositoryProvider repositoryProvider)
{
+ this.repositoryProvider = repositoryProvider;
}
public String getType()
@@ -32,6 +36,11 @@ public class CDOServerProtocol extends SignalProtocol
return CDOProtocolConstants.PROTOCOL_NAME;
}
+ public IRepositoryProvider getRepositoryProvider()
+ {
+ return repositoryProvider;
+ }
+
public Session getSession()
{
return session;
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocolFactory.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocolFactory.java
index dbc107f..61fb88b 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocolFactory.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CDOServerProtocolFactory.java
@@ -1,6 +1,7 @@
package org.eclipse.emf.cdo.internal.server.protocol;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
+import org.eclipse.emf.cdo.server.IRepositoryProvider;
import org.eclipse.net4j.util.container.IManagedContainer;
@@ -9,18 +10,26 @@ import org.eclipse.internal.net4j.ServerProtocolFactory;
/**
* @author Eike Stepper
*/
-public final class CDOServerProtocolFactory extends ServerProtocolFactory<CDOServerProtocol>
+public class CDOServerProtocolFactory extends ServerProtocolFactory<CDOServerProtocol>
{
public static final String TYPE = CDOProtocolConstants.PROTOCOL_NAME;
- public CDOServerProtocolFactory()
+ private IRepositoryProvider repositoryProvider;
+
+ public CDOServerProtocolFactory(IRepositoryProvider repositoryProvider)
{
super(TYPE);
+ this.repositoryProvider = repositoryProvider;
+ }
+
+ public IRepositoryProvider getRepositoryProvider()
+ {
+ return repositoryProvider;
}
public CDOServerProtocol create(String description)
{
- return new CDOServerProtocol();
+ return new CDOServerProtocol(repositoryProvider);
}
public static CDOServerProtocol get(IManagedContainer container, String description)
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CommitTransactionIndication.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CommitTransactionIndication.java
index 36d4263..bb10975 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CommitTransactionIndication.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/CommitTransactionIndication.java
@@ -15,7 +15,7 @@ import org.eclipse.emf.cdo.internal.protocol.CDOIDRangeImpl;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageManagerImpl;
import org.eclipse.emf.cdo.internal.protocol.revision.CDORevisionImpl;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.RevisionManager;
import org.eclipse.emf.cdo.internal.server.bundle.OM;
import org.eclipse.emf.cdo.protocol.CDOID;
@@ -117,7 +117,7 @@ public class CommitTransactionIndication extends CDOServerIndication
if (size != 0)
{
- RepositoryPackageManager packageManager = getPackageManager();
+ PackageManager packageManager = getPackageManager();
newPackages = new CDOPackageImpl[size];
for (int i = 0; i < size; i++)
{
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/LoadPackageIndication.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/LoadPackageIndication.java
index d5cae2d..1c6bd13 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/LoadPackageIndication.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/LoadPackageIndication.java
@@ -11,7 +11,7 @@
package org.eclipse.emf.cdo.internal.server.protocol;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
import org.eclipse.net4j.util.ImplementationError;
@@ -37,7 +37,7 @@ public class LoadPackageIndication extends CDOServerIndication
protected void indicating(ExtendedDataInputStream in) throws IOException
{
String packageURI = in.readString();
- RepositoryPackageManager packageManager = getPackageManager();
+ PackageManager packageManager = getPackageManager();
cdoPackage = packageManager.lookupPackage(packageURI);
if (cdoPackage == null)
{
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/OpenSessionIndication.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/OpenSessionIndication.java
index 5ace6f7..69bcd5d 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/OpenSessionIndication.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/protocol/OpenSessionIndication.java
@@ -11,15 +11,15 @@
package org.eclipse.emf.cdo.internal.server.protocol;
import org.eclipse.emf.cdo.internal.protocol.CDOIDRangeImpl;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.Repository;
-import org.eclipse.emf.cdo.internal.server.RepositoryManager;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
import org.eclipse.emf.cdo.internal.server.Session;
import org.eclipse.emf.cdo.internal.server.SessionManager;
import org.eclipse.emf.cdo.internal.server.bundle.OM;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.protocol.model.CDOPackage;
import org.eclipse.emf.cdo.server.IRepository;
+import org.eclipse.emf.cdo.server.IRepositoryProvider;
import org.eclipse.emf.cdo.server.ISession;
import org.eclipse.emf.cdo.server.RepositoryNotFoundException;
import org.eclipse.emf.cdo.server.SessionCreationException;
@@ -65,8 +65,7 @@ public class OpenSessionIndication extends IndicationWithResponse
{
try
{
- RepositoryManager repositoryManager = RepositoryManager.INSTANCE;
- Repository repository = repositoryManager.getRepository(repositoryName);
+ Repository repository = getRepository();
SessionManager sessionManager = repository.getSessionManager();
CDOServerProtocol serverProtocol = (CDOServerProtocol)getProtocol();
@@ -98,6 +97,13 @@ public class OpenSessionIndication extends IndicationWithResponse
}
}
+ private Repository getRepository()
+ {
+ CDOServerProtocol protocol = (CDOServerProtocol)getProtocol();
+ IRepositoryProvider repositoryProvider = protocol.getRepositoryProvider();
+ return (Repository)repositoryProvider.getRepository(repositoryName);
+ }
+
private void writeSessionID(ExtendedDataOutputStream out, ISession session) throws IOException
{
if (PROTOCOL.isEnabled())
@@ -118,8 +124,7 @@ public class OpenSessionIndication extends IndicationWithResponse
out.writeString(repository.getUUID());
}
- private void writePackageURIs(ExtendedDataOutputStream out, RepositoryPackageManager packageManager)
- throws IOException
+ private void writePackageURIs(ExtendedDataOutputStream out, PackageManager packageManager) throws IOException
{
CDOPackage[] packages = packageManager.getPackages();
for (CDOPackage p : packages)
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/AddPackageOperation.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/AddPackageOperation.java
index bd844aa..0b4fffa 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/AddPackageOperation.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/AddPackageOperation.java
@@ -1,7 +1,7 @@
package org.eclipse.emf.cdo.internal.server.store;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.net4j.util.transaction.ITransaction;
import org.eclipse.net4j.util.transaction.ITransactionalOperation;
@@ -11,11 +11,11 @@ import org.eclipse.net4j.util.transaction.ITransactionalOperation;
*/
public abstract class AddPackageOperation<T extends ITransaction> implements ITransactionalOperation<T, Object>
{
- private RepositoryPackageManager packageManager;
+ private PackageManager packageManager;
private CDOPackageImpl cdoPackage;
- public AddPackageOperation(RepositoryPackageManager packageManager, CDOPackageImpl cdoPackage)
+ public AddPackageOperation(PackageManager packageManager, CDOPackageImpl cdoPackage)
{
this.packageManager = packageManager;
this.cdoPackage = cdoPackage;
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/NOOPStore.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/NOOPStore.java
index 1bb81f2..ce4a1f6 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/NOOPStore.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/NOOPStore.java
@@ -12,7 +12,7 @@ package org.eclipse.emf.cdo.internal.server.store;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
import org.eclipse.emf.cdo.internal.protocol.revision.CDORevisionImpl;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.RevisionManager;
import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.emf.cdo.protocol.model.CDOClassRef;
@@ -40,8 +40,7 @@ public class NOOPStore extends Store
}
@Override
- protected AddPackageOperation createAddPackageOperation(RepositoryPackageManager packageManager,
- CDOPackageImpl cdoPackage)
+ protected AddPackageOperation createAddPackageOperation(PackageManager packageManager, CDOPackageImpl cdoPackage)
{
return new AddPackageOperation(packageManager, cdoPackage)
{
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/Store.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/Store.java
index b6c3819..504e1c2 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/Store.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/Store.java
@@ -14,7 +14,7 @@ import org.eclipse.emf.cdo.internal.protocol.model.CDOClassRefImpl;
import org.eclipse.emf.cdo.internal.protocol.model.CDOPackageImpl;
import org.eclipse.emf.cdo.internal.protocol.revision.CDORevisionImpl;
import org.eclipse.emf.cdo.internal.server.Repository;
-import org.eclipse.emf.cdo.internal.server.RepositoryPackageManager;
+import org.eclipse.emf.cdo.internal.server.PackageManager;
import org.eclipse.emf.cdo.internal.server.RevisionManager;
import org.eclipse.emf.cdo.internal.server.bundle.OM;
import org.eclipse.emf.cdo.protocol.CDOID;
@@ -91,7 +91,7 @@ public abstract class Store implements IStore
return (String)TX.execute(createLoadResourcePathOperation(id));
}
- public void addPackage(RepositoryPackageManager packageManager, CDOPackageImpl cdoPackage)
+ public void addPackage(PackageManager packageManager, CDOPackageImpl cdoPackage)
{
if (TRACER.isEnabled())
{
@@ -158,7 +158,7 @@ public abstract class Store implements IStore
protected abstract LoadResourcePathOperation createLoadResourcePathOperation(CDOID id);
- protected abstract AddPackageOperation createAddPackageOperation(RepositoryPackageManager packageManager,
+ protected abstract AddPackageOperation createAddPackageOperation(PackageManager packageManager,
CDOPackageImpl cdoPackage);
protected abstract LoadPackageOperation createLoadPackageOperation(CDOPackageImpl cdoPackage);
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/StoreFactory.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/StoreFactory.java
new file mode 100644
index 0000000..ff9fd21
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/internal/server/store/StoreFactory.java
@@ -0,0 +1,28 @@
+/***************************************************************************
+ * Copyright (c) 2004 - 2007 Eike Stepper, Germany.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Eike Stepper - initial API and implementation
+ **************************************************************************/
+package org.eclipse.emf.cdo.internal.server.store;
+
+import org.eclipse.emf.cdo.server.IStore;
+
+import org.eclipse.net4j.internal.util.factory.Factory;
+
+/**
+ * @author Eike Stepper
+ */
+public abstract class StoreFactory<PRODUCT extends IStore> extends Factory<PRODUCT>
+{
+ public static final String PRODUCT_GROUP = "org.eclipse.emf.cdo.server.stores";
+
+ public StoreFactory(String type)
+ {
+ super(PRODUCT_GROUP, type);
+ }
+}
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 bbdb3f7..b8f0ca6 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
@@ -10,6 +10,7 @@
**************************************************************************/
package org.eclipse.emf.cdo.server;
+import org.eclipse.emf.cdo.internal.server.RepositoryFactory;
import org.eclipse.emf.cdo.internal.server.protocol.CDOServerProtocolFactory;
import org.eclipse.net4j.util.container.IManagedContainer;
@@ -23,8 +24,9 @@ public final class CDOServerUtil
{
}
- public static void prepareContainer(IManagedContainer container)
+ public static void prepareContainer(IManagedContainer container, IRepositoryProvider repositoryProvider)
{
- container.registerFactory(new CDOServerProtocolFactory());
+ container.registerFactory(new RepositoryFactory());
+ container.registerFactory(new CDOServerProtocolFactory(repositoryProvider));
}
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionViewsEvent.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IPackageManager.java
index b86e838..f4a28de 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionViewsEvent.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IPackageManager.java
@@ -10,12 +10,11 @@
**************************************************************************/
package org.eclipse.emf.cdo.server;
-import org.eclipse.net4j.util.container.IContainerEvent;
+import org.eclipse.emf.cdo.protocol.model.CDOPackageManager;
/**
* @author Eike Stepper
*/
-public interface ISessionViewsEvent extends IContainerEvent<IView>
+public interface IPackageManager extends IRepositoryElement, CDOPackageManager
{
- public IView getView();
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepository.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepository.java
index 1065b1c..784d750 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepository.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepository.java
@@ -12,12 +12,13 @@ package org.eclipse.emf.cdo.server;
import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.emf.cdo.protocol.model.CDOClassRef;
-import org.eclipse.emf.cdo.protocol.model.CDOPackageManager;
+
+import org.eclipse.net4j.util.container.IContainer;
/**
* @author Eike Stepper
*/
-public interface IRepository
+public interface IRepository extends IContainer
{
public String getName();
@@ -25,7 +26,7 @@ public interface IRepository
public String getUUID();
- public CDOPackageManager getPackageManager();
+ public IPackageManager getPackageManager();
public ISessionManager getSessionManager();
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryElement.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryElement.java
new file mode 100644
index 0000000..41c0951
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryElement.java
@@ -0,0 +1,19 @@
+/***************************************************************************
+ * Copyright (c) 2004 - 2007 Eike Stepper, Germany.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Eike Stepper - initial API and implementation
+ **************************************************************************/
+package org.eclipse.emf.cdo.server;
+
+/**
+ * @author Eike Stepper
+ */
+public interface IRepositoryElement
+{
+ public IRepository getRepository();
+}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryManager.java
deleted file mode 100644
index fc04b21..0000000
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryManager.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/***************************************************************************
- * Copyright (c) 2004-2007 Eike Stepper, Germany.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Eike Stepper - initial API and implementation
- **************************************************************************/
-package org.eclipse.emf.cdo.server;
-
-import org.eclipse.emf.cdo.internal.server.RepositoryManager;
-
-/**
- * @author Eike Stepper
- */
-public interface IRepositoryManager
-{
- public static final IRepositoryManager INSTANCE = RepositoryManager.INSTANCE;
-
- public String[] getRepositoryNames();
-
- public IRepository[] getRepositories();
-
- /**
- * @return Never <code>null</code>.
- */
- public IRepository getRepository(String name) throws RepositoryNotFoundException;
-
- public IRepository addRepository(String name, IStore store);
-
- public boolean isEmpty();
-
- public int size();
-}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryProvider.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryProvider.java
new file mode 100644
index 0000000..6f1b04f
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRepositoryProvider.java
@@ -0,0 +1,19 @@
+/***************************************************************************
+ * Copyright (c) 2004 - 2007 Eike Stepper, Germany.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Eike Stepper - initial API and implementation
+ **************************************************************************/
+package org.eclipse.emf.cdo.server;
+
+/**
+ * @author Eike Stepper
+ */
+public interface IRepositoryProvider
+{
+ public IRepository getRepository(String name);
+}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IResourceManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IResourceManager.java
index 6efdd44..ff52cd6 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IResourceManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IResourceManager.java
@@ -10,16 +10,13 @@
**************************************************************************/
package org.eclipse.emf.cdo.server;
-import org.eclipse.emf.cdo.internal.server.Repository;
import org.eclipse.emf.cdo.protocol.CDOID;
/**
* @author Eike Stepper
*/
-public interface IResourceManager
+public interface IResourceManager extends IRepositoryElement
{
- public Repository getRepository();
-
public CDOID getResourceID(String path);
public String getResourcePath(CDOID id);
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRevisionManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRevisionManager.java
index 538ab49..0ab41e0 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRevisionManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/IRevisionManager.java
@@ -15,7 +15,6 @@ import org.eclipse.emf.cdo.protocol.revision.CDORevisionResolver;
/**
* @author Eike Stepper
*/
-public interface IRevisionManager extends CDORevisionResolver
+public interface IRevisionManager extends IRepositoryElement, CDORevisionResolver
{
- public IRepository getRepository();
}
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionManager.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionManager.java
index bcabc5e..a4ea5a0 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionManager.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/ISessionManager.java
@@ -12,13 +12,13 @@ package org.eclipse.emf.cdo.server;
import org.eclipse.emf.cdo.internal.server.protocol.CDOServerProtocol;
+import org.eclipse.net4j.util.container.IContainer;
+
/**
* @author Eike Stepper
*/
-public interface ISessionManager
+public interface ISessionManager extends IRepositoryElement, IContainer<ISession>
{
- public IRepository getRepository();
-
public ISession[] getSessions();
/**
diff --git a/plugins/org.eclipse.emf.cdo.ui/CDO UI.launch b/plugins/org.eclipse.emf.cdo.ui/CDO UI.launch
index 4b8861d..f15f1ea 100644
--- a/plugins/org.eclipse.emf.cdo.ui/CDO UI.launch
+++ b/plugins/org.eclipse.emf.cdo.ui/CDO UI.launch
@@ -4,7 +4,7 @@
<booleanAttribute key="automaticAdd" value="false"/>
<booleanAttribute key="automaticValidate" value="true"/>
<stringAttribute key="bootstrap" value=""/>
-<stringAttribute key="checked" value="org.eclipse.net4j,org.eclipse.net4j.ui,org.eclipse.net4j.util"/>
+<stringAttribute key="checked" value="org.eclipse.emf.cdo,org.eclipse.emf.cdo.protocol,org.eclipse.emf.cdo.server,org.eclipse.emf.cdo.server.db,org.eclipse.net4j,org.eclipse.net4j.ui,org.eclipse.net4j.util"/>
<booleanAttribute key="clearConfig" value="true"/>
<booleanAttribute key="clearws" value="false"/>
<booleanAttribute key="clearwslog" value="false"/>
@@ -18,7 +18,7 @@
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Dosgi.console&#13;&#10;-Dorg.aspectj.tracing.debug=true&#13;&#10;-Xms40m&#13;&#10;-Xmx512m"/>
<stringAttribute key="pde.version" value="3.3"/>
<stringAttribute key="product" value="org.eclipse.sdk.ide"/>
-<stringAttribute key="selectedPlugin" value="org.eclipse.net4j.util"/>
+<stringAttribute key="selectedPlugin" value="org.eclipse.emf.cdo.server.db"/>
<stringAttribute key="selected_target_plugins" value="com.ibm.icu,com.ibm.icu36.data.update,com.jcraft.jsch,javax.servlet,javax.servlet.jsp,org.apache.ant,org.apache.commons.el,org.apache.commons.logging,org.apache.jasper,org.apache.lucene,org.apache.lucene.analysis,org.aspectj.runtime,org.aspectj.weaver,org.eclipse.ant.core,org.eclipse.ant.ui,org.eclipse.compare,org.eclipse.core.boot,org.eclipse.core.commands,org.eclipse.core.contenttype,org.eclipse.core.databinding,org.eclipse.core.databinding.beans,org.eclipse.core.expressions,org.eclipse.core.filebuffers,org.eclipse.core.filesystem,org.eclipse.core.filesystem.win32.x86,org.eclipse.core.jobs,org.eclipse.core.net,org.eclipse.core.resources,org.eclipse.core.resources.compatibility,org.eclipse.core.resources.win32,org.eclipse.core.runtime,org.eclipse.core.runtime.compatibility,org.eclipse.core.runtime.compatibility.auth,org.eclipse.core.runtime.compatibility.registry,org.eclipse.core.variables,org.eclipse.cvs,org.eclipse.cvs.source,org.eclipse.debug.core,org.eclipse.debug.ui,org.eclipse.emf,org.eclipse.emf.ant,org.eclipse.emf.cheatsheets,org.eclipse.emf.codegen,org.eclipse.emf.codegen.ecore,org.eclipse.emf.codegen.ecore.ui,org.eclipse.emf.codegen.ui,org.eclipse.emf.common,org.eclipse.emf.common.ui,org.eclipse.emf.commonj.sdo,org.eclipse.emf.converter,org.eclipse.emf.doc,org.eclipse.emf.ecore,org.eclipse.emf.ecore,org.eclipse.emf.ecore.change,org.eclipse.emf.ecore.change.edit,org.eclipse.emf.ecore.edit,org.eclipse.emf.ecore.editor,org.eclipse.emf.ecore.sdo,org.eclipse.emf.ecore.sdo.doc,org.eclipse.emf.ecore.sdo.edit,org.eclipse.emf.ecore.sdo.editor,org.eclipse.emf.ecore.sdo.source,org.eclipse.emf.ecore.xmi,org.eclipse.emf.edit,org.eclipse.emf.edit.ui,org.eclipse.emf.exporter,org.eclipse.emf.importer,org.eclipse.emf.importer.ecore,org.eclipse.emf.importer.java,org.eclipse.emf.importer.rose,org.eclipse.emf.mapping,org.eclipse.emf.mapping.ecore2ecore,org.eclipse.emf.mapping.ecore2ecore.editor,org.eclipse.emf.mapping.ecore2xml,org.eclipse.emf.mapping.ecore2xml.ui,org.eclipse.emf.mapping.ui,org.eclipse.emf.mapping.xsd2ecore,org.eclipse.emf.mapping.xsd2ecore.editor,org.eclipse.emf.source,org.eclipse.equinox.app,org.eclipse.equinox.common,org.eclipse.equinox.http.jetty,org.eclipse.equinox.http.registry,org.eclipse.equinox.http.servlet,org.eclipse.equinox.jsp.jasper,org.eclipse.equinox.jsp.jasper.registry,org.eclipse.equinox.launcher,org.eclipse.equinox.launcher.win32.win32.x86,org.eclipse.equinox.preferences,org.eclipse.equinox.registry,org.eclipse.help,org.eclipse.help.appserver,org.eclipse.help.base,org.eclipse.help.ui,org.eclipse.help.webapp,org.eclipse.jdt,org.eclipse.jdt.core,org.eclipse.jdt.core.manipulation,org.eclipse.jdt.debug,org.eclipse.jdt.debug.ui,org.eclipse.jdt.doc.isv,org.eclipse.jdt.doc.user,org.eclipse.jdt.junit,org.eclipse.jdt.junit.runtime,org.eclipse.jdt.junit4.runtime,org.eclipse.jdt.launching,org.eclipse.jdt.source,org.eclipse.jdt.ui,org.eclipse.jface,org.eclipse.jface.databinding,org.eclipse.jface.text,org.eclipse.jsch.core,org.eclipse.ltk.core.refactoring,org.eclipse.ltk.ui.refactoring,org.eclipse.osgi,org.eclipse.osgi.services,org.eclipse.osgi.util,org.eclipse.pde,org.eclipse.pde.build,org.eclipse.pde.core,org.eclipse.pde.doc.user,org.eclipse.pde.junit.runtime,org.eclipse.pde.runtime,org.eclipse.pde.source,org.eclipse.pde.ui,org.eclipse.pde.ui.templates,org.eclipse.platform,org.eclipse.platform.doc.isv,org.eclipse.platform.source,org.eclipse.platform.source.win32.win32.x86,org.eclipse.rcp,org.eclipse.rcp.source,org.eclipse.rcp.source.win32.win32.x86,org.eclipse.sdk,org.eclipse.search,org.eclipse.swt,org.eclipse.swt.win32.win32.x86,org.eclipse.team.core,org.eclipse.team.cvs.core,org.eclipse.team.cvs.ssh,org.eclipse.team.cvs.ssh2,org.eclipse.team.cvs.ui,org.eclipse.team.ui,org.eclipse.text,org.eclipse.tomcat,org.eclipse.ui,org.eclipse.ui.browser,org.eclipse.ui.cheatsheets,org.eclipse.ui.console,org.eclipse.ui.editors,org.eclipse.ui.externaltools,org.eclipse.ui.forms,org.eclipse.ui.ide,org.eclipse.ui.ide.application,org.eclipse.ui.intro,org.eclipse.ui.intro.universal,org.eclipse.ui.navigator,org.eclipse.ui.navigator.resources,org.eclipse.ui.presentations.r21,org.eclipse.ui.views,org.eclipse.ui.views.properties.tabbed,org.eclipse.ui.win32,org.eclipse.ui.workbench,org.eclipse.ui.workbench.compatibility,org.eclipse.ui.workbench.texteditor,org.eclipse.uml2.common,org.eclipse.uml2.common.edit,org.eclipse.uml2.uml,org.eclipse.uml2.uml,org.eclipse.update.configurator,org.eclipse.update.core,org.eclipse.update.core.win32,org.eclipse.update.scheduler,org.eclipse.update.ui,org.eclipse.xsd,org.eclipse.xsd.cheatsheets,org.eclipse.xsd.doc,org.eclipse.xsd.ecore.exporter,org.eclipse.xsd.ecore.importer,org.eclipse.xsd.edit,org.eclipse.xsd.editor,org.eclipse.xsd.source,org.junit,org.junit4,org.mortbay.jetty"/>
<stringAttribute key="selected_workspace_plugins" value="org.eclipse.emf.cdo.protocol,org.eclipse.net4j.util,org.eclipse.emf.cdo.server,org.eclipse.emf.cdo.ui,org.eclipse.emf.cdo.edit,org.eclipse.net4j.debug,org.eclipse.emf.cdo,org.eclipse.emf.cdo.server.db,org.eclipse.emf.cdo.weaver,org.eclipse.emf.cdo.tests.model1.edit,org.eclipse.net4j.util.ui,org.eclipse.net4j.db.derby,org.eclipse.net4j.db,org.eclipse.net4j,org.eclipse.emf.cdo.tests.model1,org.eclipse.net4j.tcp,org.eclipse.net4j.ui,org.eclipse.emf.cdo.weaver.ui"/>
<stringAttribute key="templateConfig" value="${target_home}\configuration\config.ini"/>
@@ -38,22 +38,22 @@
<mapEntry key="org.eclipse.ui/trace/contexts" value="false"/>
<mapEntry key="org.eclipse.wst.common.environment/trace/error" value="true"/>
<mapEntry key="org.eclipse.debug.ui/debug/viewers/updateSequence" value="false"/>
-<mapEntry key="org.eclipse.emf.validation/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.wst.common.environment/trace/warning" value="true"/>
+<mapEntry key="org.eclipse.emf.validation/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.osgi/trace/filename" value="runtime.traces"/>
<mapEntry key="org.eclipse.wst.sse.ui/extendededitoractionbuilder" value="false"/>
-<mapEntry key="org.eclipse.debug.ui/debug/contextlaunching" value="false"/>
-<mapEntry key="org.eclipse.wst.sse.ui/actioncontributor/debugstatusfields" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug" value="true"/>
+<mapEntry key="org.eclipse.wst.sse.ui/actioncontributor/debugstatusfields" value="true"/>
+<mapEntry key="org.eclipse.debug.ui/debug/contextlaunching" value="false"/>
<mapEntry key="org.eclipse.osgi/eclipseadaptor/debug" value="false"/>
<mapEntry key="org.eclipse.net4j.tcp/debug" value="true"/>
<mapEntry key="org.eclipse.team.cvs.core/dirtycaching" value="false"/>
<mapEntry key="org.eclipse.emf.cdo.server/debug.repository" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/javamodel" value="false"/>
-<mapEntry key="org.eclipse.emf.ocl/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/contentOutline" value="false"/>
-<mapEntry key="org.eclipse.wtp.common/debug/logtrace" value="false"/>
+<mapEntry key="org.eclipse.emf.ocl/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/preferences-properties" value="false"/>
+<mapEntry key="org.eclipse.wtp.common/debug/logtrace" value="false"/>
<mapEntry key="org.eclipse.ui.intro/trace/printHTML" value="false"/>
<mapEntry key="org.eclipse.emf.query.ocl/debug" value="true"/>
<mapEntry key="org.eclipse.ltk.core.refactoring/perf/participants/createChanges" value="300"/>
@@ -61,38 +61,38 @@
<mapEntry key="org.eclipse.net4j.util/debug.lifecycle.dump" value="true"/>
<mapEntry key="org.eclipse.ui/listeners/IWorkbenchWindow.IPerspectiveListener" value="false"/>
<mapEntry key="org.eclipse.emf.cdo/debug.util" value="true"/>
-<mapEntry key="org.eclipse.wst.sse.ui/propertySheet" value="false"/>
<mapEntry key="org.eclipse.osgi/resolver/debug" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.ui/propertySheet" value="false"/>
<mapEntry key="org.eclipse.team.core/refreshjob" value="false"/>
-<mapEntry key="org.eclipse.update.core/debug/installhandler" value="false"/>
<mapEntry key="org.eclipse.ui/debug" value="false"/>
+<mapEntry key="org.eclipse.update.core/debug/installhandler" value="false"/>
<mapEntry key="org.eclipse.wtp.common/debug/loglevel" value="WARNING"/>
<mapEntry key="org.eclipse.help.ui/debug/infopop" value="false"/>
<mapEntry key="org.eclipse.pde.core/classpath" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/threading" value="false"/>
<mapEntry key="org.eclipse.equinox.preferences/general" value="false"/>
<mapEntry key="org.eclipse.net4j.jms.server/debug.store" value="true"/>
-<mapEntry key="org.eclipse.wst.sse.core/format" value="false"/>
<mapEntry key="org.eclipse.ui/trace/handlers.performance" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.core/format" value="false"/>
<mapEntry key="org.eclipse.ocl/debug/evaluation" value="false"/>
<mapEntry key="org.eclipse.ui/trace/operations.verbose" value="false"/>
<mapEntry key="org.eclipse.emf.validation/debug/constraints" value="false"/>
<mapEntry key="org.eclipse.osgi/trace/activation" value="false"/>
<mapEntry key="org.eclipse.ocl/debug/exceptions/catching" value="false"/>
<mapEntry key="org.eclipse.debug.core/debug/commands" value="false"/>
-<mapEntry key="org.eclipse.team.core/threading" value="false"/>
<mapEntry key="org.eclipse.ui/perf/workbench.restore" value="30000"/>
+<mapEntry key="org.eclipse.team.core/threading" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/structureddocument" value="false"/>
<mapEntry key="org.eclipse.emf.transaction/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/parsing" value="false"/>
-<mapEntry key="org.eclipse.jdt.core/debug/postaction" value="false"/>
<mapEntry key="org.eclipse.emf.cdo.protocol/debug.protocol" value="true"/>
+<mapEntry key="org.eclipse.jdt.core/debug/postaction" value="false"/>
<mapEntry key="org.eclipse.ocl/debug" value="true"/>
<mapEntry key="org.eclipse.ui/trace/graphics" value="false"/>
<mapEntry key="org.eclipse.osgi/defaultprofile/logsynchronously" value="false"/>
<mapEntry key="org.eclipse.net4j.db/debug" value="true"/>
-<mapEntry key="org.eclipse.wst.common.environment/trace/ws_dt_cmd_engine" value="true"/>
<mapEntry key="org.eclipse.emf.query/debug/exceptions/throwing" value="false"/>
+<mapEntry key="org.eclipse.wst.common.environment/trace/ws_dt_cmd_engine" value="true"/>
<mapEntry key="org.eclipse.osgi/monitor/activation" value="false"/>
<mapEntry key="org.eclipse.net4j.jms/debug.protocol" value="true"/>
<mapEntry key="org.eclipse.wst.sse.ui/gotoNextAnnotation" value="false"/>
@@ -100,8 +100,8 @@
<mapEntry key="org.eclipse.debug.ui/debug" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/buffermanager" value="false"/>
<mapEntry key="org.eclipse.help.base/debug/search" value="false"/>
-<mapEntry key="org.eclipse.pde.build/debug" value="false"/>
<mapEntry key="org.eclipse.jface.text/debug/ContentAssistSubjectAdapters" value="false"/>
+<mapEntry key="org.eclipse.pde.build/debug" value="false"/>
<mapEntry key="org.eclipse.wst.common.environment/trace/ws_ant" value="true"/>
<mapEntry key="org.eclipse.jdt.ui/perf/search/participants" value="300"/>
<mapEntry key="org.eclipse.emf.validation/debug/parsers" value="false"/>
@@ -110,13 +110,13 @@
<mapEntry key="org.eclipse.ui/perf/perspective.create" value="800"/>
<mapEntry key="org.eclipse.update.core/debug/type" value="false"/>
<mapEntry key="org.eclipse.osgi/eclipseadaptor/debug/platformadmin" value="false"/>
-<mapEntry key="org.eclipse.osgi/resolver/generics" value="false"/>
-<mapEntry key="org.eclipse.ui/listeners/IWorkbenchPage.IPropertyChangeListener" value="false"/>
<mapEntry key="org.eclipse.emf.workspace/debug/methods/exiting" value="false"/>
+<mapEntry key="org.eclipse.ui/listeners/IWorkbenchPage.IPropertyChangeListener" value="false"/>
+<mapEntry key="org.eclipse.osgi/resolver/generics" value="false"/>
<mapEntry key="org.eclipse.wst.common.project.facet.core/actionSorting" value="false"/>
<mapEntry key="org.eclipse.osgi/resolver/requires" value="false"/>
-<mapEntry key="org.eclipse.core.resources/refresh" value="false"/>
<mapEntry key="org.eclipse.emf.workspace/debug/exceptions/throwing" value="false"/>
+<mapEntry key="org.eclipse.core.resources/refresh" value="false"/>
<mapEntry key="org.eclipse.jdt.core/perf/containerinitializer" value="5000"/>
<mapEntry key="org.eclipse.osgi/profile/benchmark" value="false"/>
<mapEntry key="org.eclipse.jet/debug/builder" value="false"/>
@@ -128,18 +128,18 @@
<mapEntry key="org.eclipse.ui/trace/handlers" value="false"/>
<mapEntry key="org.eclipse.ui/trace/contexts.performance" value="false"/>
<mapEntry key="org.eclipse.jem.util/debug/logtrace" value="false"/>
-<mapEntry key="org.eclipse.jdt.core/perf/completion" value="300"/>
<mapEntry key="org.eclipse.team.cvs.core/metafiles" value="false"/>
+<mapEntry key="org.eclipse.jdt.core/perf/completion" value="300"/>
<mapEntry key="org.eclipse.osgi/profile/startup" value="false"/>
<mapEntry key="org.eclipse.core.jobs/jobs" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/debug" value="true"/>
-<mapEntry key="org.eclipse.wst.common.environment/trace/info" value="true"/>
-<mapEntry key="org.eclipse.emf.query.ocl/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.core.resources/perf/save.participants" value="500"/>
+<mapEntry key="org.eclipse.emf.query.ocl/debug/exceptions/throwing" value="false"/>
+<mapEntry key="org.eclipse.wst.common.environment/trace/info" value="true"/>
<mapEntry key="org.eclipse.net4j/perf" value="false"/>
<mapEntry key="org.eclipse.help.base/debug" value="true"/>
-<mapEntry key="org.eclipse.net4j/debug" value="true"/>
<mapEntry key="org.eclipse.jet/debug/projectBundleLoading" value="false"/>
+<mapEntry key="org.eclipse.net4j/debug" value="true"/>
<mapEntry key="org.eclipse.net4j/debug.signal" value="true"/>
<mapEntry key="org.eclipse.emf.query/debug/methods/entering" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/structuredmodel/modelmanager" value="false"/>
@@ -154,11 +154,11 @@
<mapEntry key="org.eclipse.core.resources/contenttype/cache" value="false"/>
<mapEntry key="org.eclipse.emf.cdo/debug.repository" value="true"/>
<mapEntry key="org.eclipse.wst.sse.ui/extendedconfigurationbuilder" value="false"/>
-<mapEntry key="org.eclipse.core.jobs/jobs/locks" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/configuration" value="false"/>
+<mapEntry key="org.eclipse.core.jobs/jobs/locks" value="false"/>
<mapEntry key="org.eclipse.wst.xml.core/debug/cmdocumentmanager" value="false"/>
-<mapEntry key="org.eclipse.core.runtime/url/debug/connect" value="false"/>
<mapEntry key="org.eclipse.ui/trace/handlers.verbose.commandId" value=""/>
+<mapEntry key="org.eclipse.core.runtime/url/debug/connect" value="false"/>
<mapEntry key="org.eclipse.ui.ide/debug" value="false"/>
<mapEntry key="org.eclipse.osgi/profile/debug" value="false"/>
<mapEntry key="org.eclipse.pde.core/debug" value="true"/>
@@ -168,17 +168,17 @@
<mapEntry key="org.eclipse.net4j.util/debug.registry" value="true"/>
<mapEntry key="org.eclipse.jdt.ui/perf/explorer/createPartControl" value="1300"/>
<mapEntry key="org.eclipse.jdt.core/debug/hierarchy" value="false"/>
-<mapEntry key="org.eclipse.ui.ide/debug/internalerror/openDialog" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo/debug.object" value="false"/>
<mapEntry key="org.eclipse.jdt.core/perf/variableinitializer" value="5000"/>
+<mapEntry key="org.eclipse.emf.cdo/debug.object" value="false"/>
+<mapEntry key="org.eclipse.ui.ide/debug/internalerror/openDialog" value="false"/>
<mapEntry key="org.eclipse.emf.cdo.server/debug.revision" value="false"/>
<mapEntry key="org.eclipse.core.resources/strings" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/sourcemapper" value="false"/>
<mapEntry key="org.eclipse.core.resources/save/mastertable" value="false"/>
<mapEntry key="org.eclipse.core.expressions/tracePropertyResolving" value="false"/>
-<mapEntry key="org.eclipse.ui/perf/showHeapStatus" value="true"/>
-<mapEntry key="org.eclipse.jdt.core/debug/javadelta" value="false"/>
<mapEntry key="org.eclipse.core.resources/preferences" value="false"/>
+<mapEntry key="org.eclipse.jdt.core/debug/javadelta" value="false"/>
+<mapEntry key="org.eclipse.ui/perf/showHeapStatus" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/selection" value="false"/>
<mapEntry key="org.eclipse.emf.workspace/debug" value="true"/>
<mapEntry key="org.eclipse.jdt.ui/perf/content_assist_sorters/extensions" value=""/>
@@ -192,33 +192,33 @@
<mapEntry key="org.eclipse.emf.transaction/debug/transactions" value="false"/>
<mapEntry key="org.eclipse.ocl/debug/parsing" value="false"/>
<mapEntry key="org.eclipse.update.core/debug" value="true"/>
-<mapEntry key="org.eclipse.wst.sse.core/tasks/preferences" value="false"/>
<mapEntry key="org.eclipse.osgi/debug/security" value="false"/>
-<mapEntry key="org.eclipse.core.resources/build/needbuild" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.core/tasks/preferences" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore/metainfo" value="false"/>
+<mapEntry key="org.eclipse.core.resources/build/needbuild" value="false"/>
<mapEntry key="org.eclipse.core.resources/perf/builders" value="10000"/>
-<mapEntry key="org.eclipse.net4j.jms.admin/debug.protocol" value="true"/>
<mapEntry key="org.eclipse.ui/perf/perspective.listeners" value="200"/>
+<mapEntry key="org.eclipse.net4j.jms.admin/debug.protocol" value="true"/>
<mapEntry key="org.eclipse.ui/debug/showAllJobs" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo.server/debug.store" value="true"/>
<mapEntry key="org.eclipse.core.resources/history" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.server/debug.store" value="true"/>
<mapEntry key="org.eclipse.wst.sse.ui/propertyChangeUpdateActionContributionItem" value="false"/>
<mapEntry key="org.eclipse.ui/listeners/IWorkbenchPage.IPartListener" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/search" value="false"/>
-<mapEntry key="org.eclipse.pde.core/validation" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/cvsprotocol" value="true"/>
+<mapEntry key="org.eclipse.pde.core/validation" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/extendededitoractionbuilder/readtime" value="false"/>
<mapEntry key="org.eclipse.jface.text/debug/AnnotationPainter" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore/mastertable" value="false"/>
-<mapEntry key="org.eclipse.core.runtime/debug" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/tasks" value="false"/>
+<mapEntry key="org.eclipse.core.runtime/debug" value="false"/>
<mapEntry key="org.eclipse.equinox.preferences/set" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore/snapshots" value="false"/>
<mapEntry key="org.eclipse.ui/perf/perspective.switch" value="800"/>
<mapEntry key="org.eclipse.jet/debug/pluginBundleLoading" value="false"/>
<mapEntry key="org.eclipse.wst.xml.core/debug/tracefilter" value=""/>
-<mapEntry key="org.eclipse.emf.cdo/debug.protocol" value="true"/>
<mapEntry key="org.eclipse.help.webapp/debug/workingsets" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo/debug.protocol" value="true"/>
<mapEntry key="org.eclipse.osgi/debug/bundleTime" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore/markers" value="false"/>
<mapEntry key="org.eclipse.emf.validation/debug/listeners" value="false"/>
@@ -226,8 +226,8 @@
<mapEntry key="org.eclipse.core.runtime/url/debug/cachecopy" value="false"/>
<mapEntry key="org.eclipse.core.runtime/perf/success" value="false"/>
<mapEntry key="org.eclipse.net4j/debug.connector" value="true"/>
-<mapEntry key="org.eclipse.jdt.core/perf/selection" value="300"/>
<mapEntry key="org.eclipse.wst.dtd.ui/projectionperf" value="false"/>
+<mapEntry key="org.eclipse.jdt.core/perf/selection" value="300"/>
<mapEntry key="org.eclipse.osgi/debug/startlevel" value="false"/>
<mapEntry key="org.eclipse.ocl/debug/methods/entering" value="false"/>
<mapEntry key="org.eclipse.core.resources/restore" value="false"/>
@@ -235,8 +235,8 @@
<mapEntry key="org.eclipse.osgi/resolver/wiring" value="false"/>
<mapEntry key="org.eclipse.core.resources/perf/snapshot" value="1000"/>
<mapEntry key="org.eclipse.ui.intro/trace/logPerformance" value="false"/>
-<mapEntry key="org.eclipse.osgi/debug/loader" value="false"/>
<mapEntry key="org.eclipse.ui/trace/contexts.verbose" value="false"/>
+<mapEntry key="org.eclipse.osgi/debug/loader" value="false"/>
<mapEntry key="org.eclipse.osgi/resolver/grouping" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/debug/reconcilerjob" value="false"/>
<mapEntry key="org.eclipse.jdt.ui/perf/explorer/makeActions" value="1000"/>
@@ -252,11 +252,11 @@
<mapEntry key="org.eclipse.emf.validation/debug/cache" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/install" value="false"/>
<mapEntry key="org.eclipse.equinox.registry/debug/events" value="false"/>
-<mapEntry key="org.eclipse.core.resources/save/metainfo" value="false"/>
<mapEntry key="org.eclipse.help/debug/protocols" value="false"/>
+<mapEntry key="org.eclipse.core.resources/save/metainfo" value="false"/>
<mapEntry key="org.eclipse.net4j.util/debug.lifecycle" value="true"/>
-<mapEntry key="org.eclipse.ui/perf/contentTypes" value="200"/>
<mapEntry key="org.eclipse.emf.validation/debug/methods/entering" value="false"/>
+<mapEntry key="org.eclipse.ui/perf/contentTypes" value="200"/>
<mapEntry key="org.eclipse.help.ui/debug/embeddedBrowser/inprocess" value="false"/>
<mapEntry key="org.eclipse.jdt.core/perf/javadeltalistener" value="500"/>
<mapEntry key="org.eclipse.core.resources/perf/listeners" value="500"/>
@@ -270,10 +270,10 @@
<mapEntry key="org.eclipse.help/debug/context" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/debug/reconcilerValidators" value="false"/>
<mapEntry key="org.eclipse.emf.validation/debug/xml" value="false"/>
-<mapEntry key="org.eclipse.jet/debug/bundleLoading" value="false"/>
<mapEntry key="org.eclipse.osgi/debug/manifest" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo/debug" value="true"/>
+<mapEntry key="org.eclipse.jet/debug/bundleLoading" value="false"/>
<mapEntry key="org.eclipse.ui/trace/multipageeditor" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo/debug" value="true"/>
<mapEntry key="org.eclipse.emf.cdo.ui/debug" value="true"/>
<mapEntry key="org.eclipse.emf.workspace/debug/exceptions/catching" value="false"/>
<mapEntry key="org.eclipse.core.resources/build/needbuildstack" value="false"/>
@@ -284,29 +284,29 @@
<mapEntry key="org.eclipse.emf.ocl/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.team.cvs.ssh/debug" value="false"/>
<mapEntry key="org.eclipse.core.resources/build/failure" value="false"/>
-<mapEntry key="org.eclipse.jet/debug" value="false"/>
<mapEntry key="org.eclipse.team.core/debug" value="false"/>
+<mapEntry key="org.eclipse.jet/debug" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/builder" value="false"/>
<mapEntry key="org.eclipse.osgi/trace/classLoading" value="false"/>
<mapEntry key="org.eclipse.net4j.jms.server.jdbc/debug" value="true"/>
<mapEntry key="org.eclipse.wst.xml.ui/projectionperf" value="false"/>
-<mapEntry key="org.eclipse.core.resources/save" value="false"/>
<mapEntry key="org.eclipse.core.jobs/jobs/errorondeadlock" value="false"/>
+<mapEntry key="org.eclipse.core.resources/save" value="false"/>
<mapEntry key="org.eclipse.emf.transaction/debug/exceptions/throwing" value="false"/>
<mapEntry key="org.eclipse.core.resources/contenttype" value="false"/>
-<mapEntry key="org.eclipse.jface.text/debug/FastPartitioner/PositionCache" value="false"/>
<mapEntry key="org.eclipse.jem.util/debug/loglevel" value="WARNING"/>
+<mapEntry key="org.eclipse.jface.text/debug/FastPartitioner/PositionCache" value="false"/>
<mapEntry key="org.eclipse.emf.validation/debug/exceptions/catching" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo.server/debug" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/compiler" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.server/debug" value="true"/>
<mapEntry key="org.eclipse.osgi/debug/events" value="false"/>
<mapEntry key="org.eclipse.ui/trace/commands" value="false"/>
<mapEntry key="org.eclipse.equinox.preferences/get" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/filemodelprovider/operations" value="false"/>
<mapEntry key="org.eclipse.jdt.ui/debug/ResultCollector" value="false"/>
<mapEntry key="org.eclipse.debug.ui/debug/launchhistory" value="false"/>
-<mapEntry key="org.eclipse.wst.sse.ui/extendededitoractionbuilder/contributetime" value="false"/>
<mapEntry key="org.eclipse.net4j.util/debug.om" value="true"/>
+<mapEntry key="org.eclipse.wst.sse.ui/extendededitoractionbuilder/contributetime" value="false"/>
<mapEntry key="org.eclipse.net4j.jms.server/debug" value="true"/>
<mapEntry key="org.eclipse.emf.workspace/debug/methods/entering" value="false"/>
<mapEntry key="org.eclipse.emf.query.ocl/debug/methods/entering" value="false"/>
@@ -318,8 +318,8 @@
<mapEntry key="org.eclipse.ui.intro/debug" value="true"/>
<mapEntry key="org.eclipse.emf.transaction/debug/locking" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/cpresolution/advanced" value="false"/>
-<mapEntry key="org.eclipse.emf.validation/debug/providers" value="false"/>
<mapEntry key="org.eclipse.net4j.jms/debug" value="true"/>
+<mapEntry key="org.eclipse.emf.validation/debug/providers" value="false"/>
<mapEntry key="org.eclipse.osgi/eclipseadaptor/converter/debug" value="false"/>
<mapEntry key="org.eclipse.emf.cdo.server/debug.resource" value="true"/>
<mapEntry key="org.eclipse.pde.core/cache" value="false"/>
@@ -327,18 +327,18 @@
<mapEntry key="org.eclipse.wst.sse.ui/extendedconfigurationbuilder/time" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/tasks/time" value="false"/>
<mapEntry key="org.eclipse.emf.cdo/debug.transaction" value="true"/>
-<mapEntry key="org.eclipse.emf.query/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/filemodelprovider/lifecyclelistener" value="false"/>
-<mapEntry key="org.eclipse.net4j/debug.selector" value="true"/>
+<mapEntry key="org.eclipse.emf.query/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.debug.core/debug/events" value="false"/>
+<mapEntry key="org.eclipse.net4j/debug.selector" value="true"/>
<mapEntry key="org.eclipse.jdt.ui/debug" value="true"/>
-<mapEntry key="org.eclipse.osgi/monitor/classes" value="false"/>
-<mapEntry key="org.eclipse.wst.sse.core/filebuffers/modelmanagement" value="false"/>
<mapEntry key="org.eclipse.net4j.db/debug.sql" value="true"/>
-<mapEntry key="org.eclipse.wst.sse.ui/debug/tracefilter" value=""/>
+<mapEntry key="org.eclipse.wst.sse.core/filebuffers/modelmanagement" value="false"/>
+<mapEntry key="org.eclipse.osgi/monitor/classes" value="false"/>
<mapEntry key="org.eclipse.ui/perf/part.input" value="200"/>
-<mapEntry key="org.eclipse.jet/debug/ext/xpathFunctions" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.ui/debug/tracefilter" value=""/>
<mapEntry key="org.eclipse.wtp.common/debug/logtracefile" value="false"/>
+<mapEntry key="org.eclipse.jet/debug/ext/xpathFunctions" value="false"/>
<mapEntry key="org.eclipse.emf.query/debug" value="true"/>
<mapEntry key="org.eclipse.ui.intro.universal/debug" value="true"/>
<mapEntry key="org.eclipse.jdt.ui/debug/TypeConstraints" value="false"/>
@@ -354,11 +354,11 @@
<mapEntry key="org.eclipse.net4j.jms.admin/debug" value="true"/>
<mapEntry key="org.eclipse.emf.cdo/debug.model" value="false"/>
<mapEntry key="org.eclipse.jdt.core/debug/cpresolution" value="false"/>
-<mapEntry key="org.eclipse.help.ui/debug/embeddedBrowser" value="false"/>
<mapEntry key="org.eclipse.wst.common.project.facet.core/activation" value="false"/>
+<mapEntry key="org.eclipse.help.ui/debug/embeddedBrowser" value="false"/>
<mapEntry key="org.eclipse.team.cvs.ssh/ssh_protocol" value="false"/>
-<mapEntry key="org.eclipse.ui/perf/part.create" value="800"/>
<mapEntry key="org.eclipse.core.resources/build/stacktrace" value="false"/>
+<mapEntry key="org.eclipse.ui/perf/part.create" value="800"/>
<mapEntry key="org.eclipse.ui.intro/trace/logInfo" value="true"/>
<mapEntry key="org.eclipse.team.core/streams" value="false"/>
<mapEntry key="org.eclipse.ui.ide/debug/undomonitor" value="false"/>
@@ -366,11 +366,11 @@
<mapEntry key="org.eclipse.ui/experimental/menus" value="false"/>
<mapEntry key="org.eclipse.core.jobs/jobs/shutdown" value="false"/>
<mapEntry key="org.eclipse.osgi/debug/packageadmin" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo/debug.session" value="true"/>
<mapEntry key="org.eclipse.net4j.container.ui/debug" value="true"/>
+<mapEntry key="org.eclipse.emf.cdo/debug.session" value="true"/>
<mapEntry key="org.eclipse.core.runtime/compatibility/debug" value="false"/>
-<mapEntry key="org.eclipse.wst.sse.ui/storagemodelprovider/operations" value="false"/>
<mapEntry key="org.eclipse.emf.cdo/debug.adapter" value="true"/>
+<mapEntry key="org.eclipse.wst.sse.ui/storagemodelprovider/operations" value="false"/>
<mapEntry key="org.eclipse.ui/debug/declaredImages" value="false"/>
<mapEntry key="org.eclipse.update.core/debug/reconciler" value="false"/>
<mapEntry key="org.eclipse.ui.ide/debug/gc" value="false"/>
@@ -380,38 +380,38 @@
<mapEntry key="org.eclipse.net4j.db.mysql/debug.sql" value="true"/>
<mapEntry key="org.eclipse.ui.workbench/debug" value="false"/>
<mapEntry key="org.eclipse.jdt.ui/perf/content_assist/extensions" value="1000"/>
-<mapEntry key="org.eclipse.emf.cdo.protocol/debug.model" value="false"/>
<mapEntry key="org.eclipse.osgi/debug/filter" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.protocol/debug.model" value="false"/>
<mapEntry key="org.eclipse.debug.core/debug" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo.server.jdbc/debug" value="true"/>
<mapEntry key="org.eclipse.core.resources/debug" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.server.jdbc/debug" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/zipaccess" value="false"/>
<mapEntry key="org.eclipse.jem.util/debug/logtracefile" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo.server/debug.protocol" value="false"/>
<mapEntry key="org.eclipse.ui.browser/debug" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.server/debug.protocol" value="false"/>
<mapEntry key="org.eclipse.osgi/profile/impl" value="org.eclipse.osgi.internal.profile.DefaultProfileLogger"/>
-<mapEntry key="org.eclipse.update.core/debug/web" value="false"/>
<mapEntry key="org.eclipse.net4j.jms.server/debug.protocol" value="true"/>
+<mapEntry key="org.eclipse.update.core/debug/web" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/debug" value="false"/>
<mapEntry key="org.eclipse.help/debug" value="true"/>
<mapEntry key="org.eclipse.core.runtime/perf" value="false"/>
<mapEntry key="org.eclipse.osgi/trace/filters" value="trace.properties"/>
-<mapEntry key="org.eclipse.wst.sse.core/dom/adapter/notification/time" value="false"/>
<mapEntry key="org.eclipse.emf.ocl/debug/methods/entering" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.core/dom/adapter/notification/time" value="false"/>
<mapEntry key="org.eclipse.net4j/debug.channel" value="true"/>
<mapEntry key="org.eclipse.emf.cdo/debug.revision" value="true"/>
<mapEntry key="org.eclipse.emf.cdo/debug.view" value="true"/>
<mapEntry key="org.eclipse.ui/perf/part.listeners" value="200"/>
<mapEntry key="org.eclipse.debug.ui/debug/viewers/viewer" value="false"/>
-<mapEntry key="org.eclipse.ui/trace/keyBindings.verbose" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/dom/adapter/notification/time/criteria" value="10"/>
+<mapEntry key="org.eclipse.ui/trace/keyBindings.verbose" value="false"/>
<mapEntry key="org.eclipse.wst.common.environment/trace/data" value="true"/>
-<mapEntry key="org.eclipse.core.resources/restore/syncinfo" value="false"/>
<mapEntry key="org.eclipse.osgi/defaultprofile/buffersize" value="256"/>
-<mapEntry key="org.eclipse.ui/perf/page.listeners" value="200"/>
+<mapEntry key="org.eclipse.core.resources/restore/syncinfo" value="false"/>
<mapEntry key="org.eclipse.team.cvs.core/syncchangeevents" value="false"/>
-<mapEntry key="org.eclipse.emf.cdo.protocol/debug" value="true"/>
+<mapEntry key="org.eclipse.ui/perf/page.listeners" value="200"/>
<mapEntry key="org.eclipse.ocl/debug/exceptions/throwing" value="false"/>
+<mapEntry key="org.eclipse.emf.cdo.protocol/debug" value="true"/>
<mapEntry key="org.eclipse.emf.cdo/debug.resource" value="true"/>
<mapEntry key="org.eclipse.jet/debug/modelLoaderExtensions" value="false"/>
<mapEntry key="org.eclipse.wst.sse.core/debug" value="true"/>
@@ -427,23 +427,23 @@
<mapEntry key="org.eclipse.core.runtime/url/debug/cachelookup" value="false"/>
<mapEntry key="org.eclipse.ui/listeners/IWorkbenchWindow.IPartListener2" value="false"/>
<mapEntry key="org.eclipse.core.resources/build/delta" value="false"/>
-<mapEntry key="org.eclipse.jet/debug/pluginProjectMonitor" value="false"/>
<mapEntry key="org.eclipse.core.resources/build/interrupt" value="false"/>
+<mapEntry key="org.eclipse.jet/debug/pluginProjectMonitor" value="false"/>
<mapEntry key="org.eclipse.emf.validation/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.core.runtime/preferences/plugin" value="false"/>
<mapEntry key="org.eclipse.core.runtime/url/debug" value="false"/>
<mapEntry key="org.eclipse.osgi/resolver/cycles" value="false"/>
<mapEntry key="org.eclipse.ui/listeners/IWorkbenchWindow.IPartListener" value="false"/>
-<mapEntry key="org.eclipse.wst.sse.core/structuredmodel/locks" value="true"/>
<mapEntry key="org.eclipse.wst.sse.core/filebuffers/lifecycle" value="false"/>
+<mapEntry key="org.eclipse.wst.sse.core/structuredmodel/locks" value="true"/>
<mapEntry key="org.eclipse.jdt.core/debug/resolution" value="false"/>
<mapEntry key="org.eclipse.wst.common.environment/debug" value="true"/>
<mapEntry key="org.eclipse.update.configurator/debug" value="false"/>
-<mapEntry key="org.eclipse.debug.ui/debug/viewers/deltas" value="false"/>
<mapEntry key="org.eclipse.help.ui/debug" value="true"/>
+<mapEntry key="org.eclipse.debug.ui/debug/viewers/deltas" value="false"/>
<mapEntry key="org.eclipse.emf.query.ocl/debug/methods/exiting" value="false"/>
-<mapEntry key="org.eclipse.ocl/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.osgi/eclipseadaptor/debug/location" value="false"/>
+<mapEntry key="org.eclipse.ocl/debug/methods/exiting" value="false"/>
<mapEntry key="org.eclipse.wst.sse.ui/debug/reconcilerSpelling" value="false"/>
<mapEntry key="org.eclipse.emf.transaction/debug/methods/entering" value="false"/>
<mapEntry key="org.eclipse.ui.intro.universal/trace/logInfo" value="true"/>
diff --git a/plugins/org.eclipse.emf.cdo.ui/config/cdo.server.xml b/plugins/org.eclipse.emf.cdo.ui/config/cdo.server.xml
new file mode 100644
index 0000000..d25e659
--- /dev/null
+++ b/plugins/org.eclipse.emf.cdo.ui/config/cdo.server.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<repositoryManager>
+
+ <repository>
+ <name>repo1</name>
+ <store>
+ <type>db</type>
+ <instanceID>TEST0001</instanceID>
+ <dbAdapter>derby</dbAdapter>
+ <dataSource>
+ <driverClass>org.apache.derby.jdbc.EmbeddedDataSource</driverClass>
+ <databaseName>C:/temp/cdodb1</databaseName>
+ <createDatabase>create</createDatabase>
+ </dataSource>
+ <mappingStrategy>
+
+ </mappingStrategy>
+ </store>
+ </repository>
+
+</repositoryManager> \ No newline at end of file
diff --git a/plugins/org.eclipse.emf.cdo.ui/config/org.eclipse.emf.cdo.server.db.properties b/plugins/org.eclipse.emf.cdo.ui/config/org.eclipse.emf.cdo.server.db.properties
deleted file mode 100644
index cea6026..0000000
--- a/plugins/org.eclipse.emf.cdo.ui/config/org.eclipse.emf.cdo.server.db.properties
+++ /dev/null
@@ -1,6 +0,0 @@
-store.instanceID = TEST0001
-store.dbAdapter = derby
-
-datasource.driverClass = org.apache.derby.jdbc.EmbeddedDataSource
-datasource.databaseName = C:/temp/cdodb
-datasource.createDatabase = create
diff --git a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/bundle/OM.java b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/bundle/OM.java
index 08b4832..8e79e8f 100644
--- a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/bundle/OM.java
+++ b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/bundle/OM.java
@@ -10,9 +10,6 @@
**************************************************************************/
package org.eclipse.emf.cdo.internal.ui.bundle;
-import org.eclipse.emf.cdo.internal.server.store.NOOPStore;
-import org.eclipse.emf.cdo.server.IRepositoryManager;
-
import org.eclipse.net4j.util.om.OMBundle;
import org.eclipse.net4j.util.om.OMPlatform;
import org.eclipse.net4j.util.om.log.OMLogger;
@@ -39,28 +36,6 @@ public abstract class OM
public static final OMPreference<String[]> PREF_HISTORY_SELECT_PACKAGES = PREFS
.initArray("PREF_HISTORY_SELECT_PACKAGES");
- static void start() throws Exception
- {
- IRepositoryManager.INSTANCE.addRepository("repo1", new NOOPStore());
- // Properties properties = BUNDLE.getConfigProperties();
- // String repositories = properties.getProperty("repositories");
- // if (repositories != null)
- // {
- // StringTokenizer tokenizer = new StringTokenizer(repositories, ",");
- // while (tokenizer.hasMoreTokens())
- // {
- // String repositoryName = tokenizer.nextToken().trim();
- // String storeType = properties.getProperty(repositoryName + ".type");
- // IDBAdapter adapter = DBUtil.getDBAdapter("derby");
- // DataSource dataSource = DBUtil.createDataSource(properties,
- // repositoryName + ".dataSource");
- // CDODBStoreManager storeManager = new CDODBStoreManager(adapter,
- // dataSource);
- // IRepositoryManager.INSTANCE.addRepository("repo1", storeManager);
- // }
- // }
- }
-
/**
* @author Eike Stepper
*/
diff --git a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOEventHandler.java b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOEventHandler.java
index d50701d..ce455e2 100644
--- a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOEventHandler.java
+++ b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOEventHandler.java
@@ -11,7 +11,6 @@
package org.eclipse.emf.cdo.internal.ui.views;
import org.eclipse.emf.cdo.CDOSessionInvalidationEvent;
-import org.eclipse.emf.cdo.CDOSessionViewsEvent;
import org.eclipse.emf.cdo.CDOTransactionCommittedEvent;
import org.eclipse.emf.cdo.CDOTransactionDirtyEvent;
import org.eclipse.emf.cdo.CDOView;
@@ -19,6 +18,7 @@ import org.eclipse.emf.cdo.internal.ui.ItemsProcessor;
import org.eclipse.emf.cdo.protocol.CDOID;
import org.eclipse.net4j.util.container.IContainerDelta;
+import org.eclipse.net4j.util.container.IContainerEvent;
import org.eclipse.net4j.util.event.IEvent;
import org.eclipse.net4j.util.event.IListener;
import org.eclipse.net4j.util.lifecycle.ILifecycleEvent;
@@ -52,10 +52,10 @@ public class CDOEventHandler
sessionInvalidated(e.getDirtyOIDs());
}
}
- else if (event instanceof CDOSessionViewsEvent)
+ else if (event instanceof IContainerEvent)
{
- CDOSessionViewsEvent e = (CDOSessionViewsEvent)event;
- if (e.getView() == view && e.getDeltaKind() == IContainerDelta.Kind.REMOVED)
+ IContainerEvent e = (IContainerEvent)event;
+ if (e.getDeltaElement() == view && e.getDeltaKind() == IContainerDelta.Kind.REMOVED)
{
viewClosed();
}
diff --git a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOItemProvider.java b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOItemProvider.java
index 9ebf8b2..0bba1b1 100644
--- a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOItemProvider.java
+++ b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOItemProvider.java
@@ -135,7 +135,7 @@ public class CDOItemProvider extends ContainerItemProvider
return history.getEntries();
}
- return NO_CHILDREN;
+ return NO_ELEMENTS;
}
return super.getChildren(element);
diff --git a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOSessionsView.java b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOSessionsView.java
index 802eea7..9ef3388 100644
--- a/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOSessionsView.java
+++ b/plugins/org.eclipse.emf.cdo.ui/src/org/eclipse/emf/cdo/internal/ui/views/CDOSessionsView.java
@@ -6,7 +6,7 @@ import org.eclipse.emf.cdo.internal.ui.editor.CDOEditor;
import org.eclipse.emf.cdo.protocol.CDOProtocolConstants;
import org.eclipse.net4j.util.container.IManagedContainer;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.ui.actions.SafeAction;
import org.eclipse.net4j.util.ui.views.ContainerItemProvider;
import org.eclipse.net4j.util.ui.views.ContainerView;
@@ -30,7 +30,7 @@ public class CDOSessionsView extends ContainerView
@Override
protected IManagedContainer getContainer()
{
- return IPluginTransportContainer.INSTANCE;
+ return IPluginContainer.INSTANCE;
}
@Override
@@ -86,8 +86,8 @@ public class CDOSessionsView extends ContainerView
@Override
protected void doRun() throws Exception
{
- IPluginTransportContainer.INSTANCE.getElement(CDOSessionFactory.PRODUCT_GROUP,
- CDOProtocolConstants.PROTOCOL_NAME, "tcp://127.0.0.1:" + port + "/repo1");
+ IPluginContainer.INSTANCE.getElement(CDOSessionFactory.PRODUCT_GROUP, CDOProtocolConstants.PROTOCOL_NAME,
+ "tcp://127.0.0.1:" + port + "/repo1");
}
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.net4j.debug/src/org/eclipse/net4j/internal/debug/views/IntrospectorView.java b/plugins/org.eclipse.net4j.debug/src/org/eclipse/net4j/internal/debug/views/IntrospectorView.java
index a5e9805..71801f5 100644
--- a/plugins/org.eclipse.net4j.debug/src/org/eclipse/net4j/internal/debug/views/IntrospectorView.java
+++ b/plugins/org.eclipse.net4j.debug/src/org/eclipse/net4j/internal/debug/views/IntrospectorView.java
@@ -13,6 +13,9 @@ package org.eclipse.net4j.internal.debug.views;
import org.eclipse.net4j.internal.debug.bundle.OM;
import org.eclipse.net4j.util.ReflectUtil;
import org.eclipse.net4j.util.collection.Pair;
+import org.eclipse.net4j.util.event.EventUtil;
+import org.eclipse.net4j.util.event.IEvent;
+import org.eclipse.net4j.util.event.IListener;
import org.eclipse.jface.action.Action;
import org.eclipse.jface.action.IAction;
@@ -54,7 +57,7 @@ import java.util.Stack;
/**
* @author Eike Stepper
*/
-public class IntrospectorView extends ViewPart implements ISelectionListener, IDoubleClickListener
+public class IntrospectorView extends ViewPart implements ISelectionListener, IDoubleClickListener, IListener
{
private static final Object[] NO_ELEMENTS = {};
@@ -247,8 +250,14 @@ public class IntrospectorView extends ViewPart implements ISelectionListener, ID
}
}
+ public void notifyEvent(IEvent event)
+ {
+ refreshViewer();
+ }
+
private void setObject(Object object)
{
+ EventUtil.removeListener(object, this);
if (object != null)
{
if (!elements.isEmpty())
@@ -256,6 +265,7 @@ public class IntrospectorView extends ViewPart implements ISelectionListener, ID
Object element = elements.peek();
if (element != object)
{
+ EventUtil.removeListener(element, this);
elements.push(object);
}
}
@@ -273,6 +283,7 @@ public class IntrospectorView extends ViewPart implements ISelectionListener, ID
}
else
{
+ EventUtil.addListener(object, this);
String className = object.getClass().getName();
classLabel.setText(className);
diff --git a/plugins/org.eclipse.net4j.jms/src/org/eclipse/net4j/internal/jms/bundle/OM.java b/plugins/org.eclipse.net4j.jms/src/org/eclipse/net4j/internal/jms/bundle/OM.java
index 423e291..a313443 100644
--- a/plugins/org.eclipse.net4j.jms/src/org/eclipse/net4j/internal/jms/bundle/OM.java
+++ b/plugins/org.eclipse.net4j.jms/src/org/eclipse/net4j/internal/jms/bundle/OM.java
@@ -11,7 +11,7 @@
package org.eclipse.net4j.internal.jms.bundle;
import org.eclipse.net4j.jms.JMSUtil;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.om.OMBundle;
import org.eclipse.net4j.util.om.OMPlatform;
import org.eclipse.net4j.util.om.OSGiActivator;
@@ -35,7 +35,7 @@ public abstract class OM
static void start() throws Exception
{
- JMSUtil.setTransportContainer(IPluginTransportContainer.INSTANCE);
+ JMSUtil.setTransportContainer(IPluginContainer.INSTANCE);
}
/**
diff --git a/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/AcceptorsView.java b/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/AcceptorsView.java
index b0f24a7..f58f240 100644
--- a/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/AcceptorsView.java
+++ b/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/AcceptorsView.java
@@ -3,7 +3,7 @@ package org.eclipse.net4j.internal.ui.views;
import org.eclipse.net4j.IAcceptor;
import org.eclipse.net4j.Net4jUtil;
import org.eclipse.net4j.util.container.IManagedContainer;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.ui.actions.SafeAction;
import org.eclipse.net4j.util.ui.views.ContainerItemProvider;
import org.eclipse.net4j.util.ui.views.ContainerView;
@@ -20,7 +20,7 @@ public class AcceptorsView extends ContainerView
@Override
protected void doRun() throws Exception
{
- Net4jUtil.getAcceptor(IPluginTransportContainer.INSTANCE, "tcp", "0.0.0.0:2036");
+ Net4jUtil.getAcceptor(IPluginContainer.INSTANCE, "tcp", "0.0.0.0:2036");
}
};
@@ -30,7 +30,7 @@ public class AcceptorsView extends ContainerView
@Override
protected void doRun() throws Exception
{
- Net4jUtil.getAcceptor(IPluginTransportContainer.INSTANCE, "tcp", "0.0.0.0:2037");
+ Net4jUtil.getAcceptor(IPluginContainer.INSTANCE, "tcp", "0.0.0.0:2037");
}
};
@@ -41,7 +41,7 @@ public class AcceptorsView extends ContainerView
@Override
protected IManagedContainer getContainer()
{
- return IPluginTransportContainer.INSTANCE;
+ return IPluginContainer.INSTANCE;
}
@Override
diff --git a/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/ConnectorsView.java b/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/ConnectorsView.java
index 86edc0e..f47f867 100644
--- a/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/ConnectorsView.java
+++ b/plugins/org.eclipse.net4j.ui/src/org/eclipse/net4j/internal/ui/views/ConnectorsView.java
@@ -3,7 +3,7 @@ package org.eclipse.net4j.internal.ui.views;
import org.eclipse.net4j.IConnector;
import org.eclipse.net4j.Net4jUtil;
import org.eclipse.net4j.util.container.IManagedContainer;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.ui.actions.SafeAction;
import org.eclipse.net4j.util.ui.views.ContainerItemProvider;
import org.eclipse.net4j.util.ui.views.ContainerView;
@@ -19,7 +19,7 @@ public class ConnectorsView extends ContainerView
@Override
protected void doRun() throws Exception
{
- Net4jUtil.getConnector(IPluginTransportContainer.INSTANCE, "tcp", "127.0.0.1:2036");
+ Net4jUtil.getConnector(IPluginContainer.INSTANCE, "tcp", "127.0.0.1:2036");
}
};
@@ -30,7 +30,7 @@ public class ConnectorsView extends ContainerView
@Override
protected IManagedContainer getContainer()
{
- return IPluginTransportContainer.INSTANCE;
+ return IPluginContainer.INSTANCE;
}
@Override
diff --git a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/internal/ui/views/Net4jContainerView.java b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/internal/ui/views/Net4jContainerView.java
index cad7eee..819d087 100644
--- a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/internal/ui/views/Net4jContainerView.java
+++ b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/internal/ui/views/Net4jContainerView.java
@@ -1,7 +1,7 @@
package org.eclipse.net4j.util.internal.ui.views;
import org.eclipse.net4j.util.container.IManagedContainer;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.ui.views.ContainerItemProvider;
import org.eclipse.net4j.util.ui.views.ContainerView;
@@ -20,6 +20,6 @@ public class Net4jContainerView extends ContainerView
@Override
protected IManagedContainer getContainer()
{
- return IPluginTransportContainer.INSTANCE;
+ return IPluginContainer.INSTANCE;
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/StructuredContentProvider.java b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/StructuredContentProvider.java
index e5fcde7..ca2d49d 100644
--- a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/StructuredContentProvider.java
+++ b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/StructuredContentProvider.java
@@ -108,13 +108,36 @@ public abstract class StructuredContentProvider<INPUT> implements IStructuredCon
viewer.refresh(updateLabels);
}
}
- catch (Exception ignore)
+ catch (RuntimeException ignore)
{
}
}
});
}
- catch (Exception ignore)
+ catch (RuntimeException ignore)
+ {
+ }
+ }
+
+ protected void updateLabels(final Object elements)
+ {
+ try
+ {
+ getDisplay().asyncExec(new Runnable()
+ {
+ public void run()
+ {
+ try
+ {
+ viewer.update(elements, null);
+ }
+ catch (RuntimeException ignore)
+ {
+ }
+ }
+ });
+ }
+ catch (RuntimeException ignore)
{
}
}
@@ -131,13 +154,13 @@ public abstract class StructuredContentProvider<INPUT> implements IStructuredCon
{
viewer.reveal(element);
}
- catch (Exception ignore)
+ catch (RuntimeException ignore)
{
}
}
});
}
- catch (Exception ignore)
+ catch (RuntimeException ignore)
{
}
}
diff --git a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/views/ContainerItemProvider.java b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/views/ContainerItemProvider.java
index d1ed159..92052b2 100644
--- a/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/views/ContainerItemProvider.java
+++ b/plugins/org.eclipse.net4j.util.ui/src/org/eclipse/net4j/util/ui/views/ContainerItemProvider.java
@@ -12,6 +12,8 @@ package org.eclipse.net4j.util.ui.views;
import org.eclipse.net4j.internal.util.container.ContainerEventAdapter;
import org.eclipse.net4j.util.container.IContainer;
+import org.eclipse.net4j.util.event.EventUtil;
+import org.eclipse.net4j.util.event.IEvent;
import org.eclipse.net4j.util.event.IListener;
import org.eclipse.net4j.util.lifecycle.LifecycleUtil;
@@ -257,7 +259,7 @@ public class ContainerItemProvider<CONTAINER extends IContainer> extends ItemPro
Node node = addChild(getChildren(), element);
if (node != null)
{
- refreshElement(container, false);
+ refreshElement(container, true);
revealElement(element);
elementAdded(element, container);
}
@@ -274,11 +276,17 @@ public class ContainerItemProvider<CONTAINER extends IContainer> extends ItemPro
{
getChildren().remove(node);
node.dispose();
- refreshElement(container, false);
+ refreshElement(container, true);
elementRemoved(element, container);
}
}
}
+
+ @Override
+ protected void notifyOtherEvent(IEvent event)
+ {
+ updateLabels(event.getSource());
+ }
};
public ContainerNode(Node parent, IContainer container)
@@ -343,7 +351,7 @@ public class ContainerItemProvider<CONTAINER extends IContainer> extends ItemPro
/**
* @author Eike Stepper
*/
- public class LeafNode implements Node
+ public class LeafNode implements Node, IListener
{
private Node parent;
@@ -353,12 +361,14 @@ public class ContainerItemProvider<CONTAINER extends IContainer> extends ItemPro
{
this.parent = parent;
this.element = element;
+ EventUtil.addListener(element, this);
}
public void dispose()
{
- parent = null;
+ EventUtil.removeListener(element, this);
element = null;
+ parent = null;
}
public Node getParent()
@@ -376,6 +386,11 @@ public class ContainerItemProvider<CONTAINER extends IContainer> extends ItemPro
return Collections.EMPTY_LIST;
}
+ public void notifyEvent(IEvent event)
+ {
+ updateLabels(event.getSource());
+ }
+
@Override
public String toString()
{
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/bundle/OM.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/bundle/OM.java
index f70001c..f3ad536 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/bundle/OM.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/bundle/OM.java
@@ -10,7 +10,7 @@
**************************************************************************/
package org.eclipse.net4j.internal.util.bundle;
-import org.eclipse.net4j.internal.util.container.PluginTransportContainer;
+import org.eclipse.net4j.internal.util.container.PluginContainer;
import org.eclipse.net4j.internal.util.om.OSGiBundle;
import org.eclipse.net4j.internal.util.om.log.EclipseLoggingBridge;
import org.eclipse.net4j.internal.util.om.log.PrintLogHandler;
@@ -51,7 +51,7 @@ public abstract class OM
static void stop() throws Exception
{
- PluginTransportContainer.dispose();
+ PluginContainer.dispose();
}
/**
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/ManagedContainer.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/ManagedContainer.java
index 553400b..042a78d 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/ManagedContainer.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/ManagedContainer.java
@@ -239,23 +239,20 @@ public class ManagedContainer extends Lifecycle implements IManagedContainer
public Object getElement(String productGroup, String factoryType, String description)
{
- synchronized (elementRegistry)
+ ElementKey key = new ElementKey(productGroup, factoryType, description);
+ Object element = elementRegistry.get(key);
+ if (element == null)
{
- ElementKey key = new ElementKey(productGroup, factoryType, description);
- Object element = elementRegistry.get(key);
- if (element == null)
- {
- element = createElement(productGroup, factoryType, description);
- element = postProcessElement(productGroup, factoryType, description, element);
- LifecycleUtil.activate(element);
- EventUtil.addListener(element, elementListener);
- key.setID(++maxElementID);
- elementRegistry.put(key, element);
- fireEvent(new SingleDeltaContainerEvent(this, element, IContainerDelta.Kind.ADDED));
- }
-
- return element;
+ element = createElement(productGroup, factoryType, description);
+ element = postProcessElement(productGroup, factoryType, description, element);
+ LifecycleUtil.activate(element);
+ EventUtil.addListener(element, elementListener);
+ key.setID(++maxElementID);
+ elementRegistry.put(key, element);
+ fireEvent(new SingleDeltaContainerEvent(this, element, IContainerDelta.Kind.ADDED));
}
+
+ return element;
}
/**
@@ -264,21 +261,18 @@ public class ManagedContainer extends Lifecycle implements IManagedContainer
*/
public Object putElement(String productGroup, String factoryType, String description, Object element)
{
- synchronized (elementRegistry)
+ ContainerEvent event = new ContainerEvent(this);
+ ElementKey key = new ElementKey(productGroup, factoryType, description);
+ key.setID(++maxElementID);
+ Object oldElement = elementRegistry.put(key, element);
+ if (oldElement != null)
{
- ContainerEvent event = new ContainerEvent(this);
- ElementKey key = new ElementKey(productGroup, factoryType, description);
- key.setID(++maxElementID);
- Object oldElement = elementRegistry.put(key, element);
- if (oldElement != null)
- {
- event.addDelta(oldElement, IContainerDelta.Kind.REMOVED);
- }
-
- event.addDelta(element, IContainerDelta.Kind.ADDED);
- fireEvent(event);
- return oldElement;
+ event.addDelta(oldElement, IContainerDelta.Kind.REMOVED);
}
+
+ event.addDelta(element, IContainerDelta.Kind.ADDED);
+ fireEvent(event);
+ return oldElement;
}
public Object removeElement(String productGroup, String factoryType, String description)
@@ -289,65 +283,56 @@ public class ManagedContainer extends Lifecycle implements IManagedContainer
public void clearElements()
{
- synchronized (elementRegistry)
+ if (!elementRegistry.isEmpty())
{
- if (!elementRegistry.isEmpty())
+ ContainerEvent event = new ContainerEvent(this);
+ for (Object element : elementRegistry.values())
{
- ContainerEvent event = new ContainerEvent(this);
- for (Object element : elementRegistry.values())
- {
- event.addDelta(element, IContainerDelta.Kind.REMOVED);
- }
-
- elementRegistry.clear();
- fireEvent(event);
+ event.addDelta(element, IContainerDelta.Kind.REMOVED);
}
+
+ elementRegistry.clear();
+ fireEvent(event);
}
}
public void loadElements(InputStream stream) throws IOException
{
- synchronized (elementRegistry)
+ clearElements();
+ ObjectInputStream ois = new ObjectInputStream(stream);
+ int size = ois.readInt();
+ for (int i = 0; i < size; i++)
{
- clearElements();
- ObjectInputStream ois = new ObjectInputStream(stream);
- int size = ois.readInt();
- for (int i = 0; i < size; i++)
+ try
{
- try
- {
- ElementKey key = (ElementKey)ois.readObject();
- Object element = getElement(key.getProductGroup(), key.getFactoryType(), key.getDescription());
-
- boolean active = ois.readBoolean();
- if (active)
- {
- LifecycleUtil.activate(element);
- }
- }
- catch (ClassNotFoundException cannotHappen)
+ ElementKey key = (ElementKey)ois.readObject();
+ Object element = getElement(key.getProductGroup(), key.getFactoryType(), key.getDescription());
+
+ boolean active = ois.readBoolean();
+ if (active)
{
+ LifecycleUtil.activate(element);
}
}
-
- initMaxElementID();
+ catch (ClassNotFoundException cannotHappen)
+ {
+ }
}
+
+ initMaxElementID();
}
public void saveElements(OutputStream stream) throws IOException
{
- synchronized (elementRegistry)
- {
- ObjectOutputStream oos = new ObjectOutputStream(stream);
- List<Entry<ElementKey, Object>> entries = new ArrayList(elementRegistry.entrySet());
- Collections.sort(entries, new EntryComparator());
+ ObjectOutputStream oos = new ObjectOutputStream(stream);
+ List<Entry<ElementKey, Object>> entries = new ArrayList(elementRegistry.entrySet());
+ Collections.sort(entries, new EntryComparator());
- oos.writeInt(entries.size());
- for (Entry<ElementKey, Object> entry : entries)
- {
- oos.writeObject(entry.getKey());
- oos.writeBoolean(LifecycleUtil.isActive(entry.getValue()));
- }
+ oos.writeInt(entries.size());
+ for (Entry<ElementKey, Object> entry : entries)
+ {
+ oos.writeObject(entry.getKey());
+ oos.writeBoolean(LifecycleUtil.isActive(entry.getValue()));
}
}
@@ -418,16 +403,13 @@ public class ManagedContainer extends Lifecycle implements IManagedContainer
protected void initMaxElementID()
{
- synchronized (elementRegistry)
+ maxElementID = 0L;
+ for (ElementKey key : elementRegistry.keySet())
{
- maxElementID = 0L;
- for (ElementKey key : elementRegistry.keySet())
+ long id = key.getID();
+ if (maxElementID < id)
{
- long id = key.getID();
- if (maxElementID < id)
- {
- maxElementID = id;
- }
+ maxElementID = id;
}
}
}
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginTransportContainer.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginContainer.java
index d93e3b7..70b6e68 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginTransportContainer.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/internal/util/container/PluginContainer.java
@@ -13,7 +13,7 @@ package org.eclipse.net4j.internal.util.container;
import org.eclipse.net4j.internal.util.bundle.OM;
import org.eclipse.net4j.internal.util.factory.PluginFactoryRegistry;
import org.eclipse.net4j.util.container.IElementProcessor;
-import org.eclipse.net4j.util.container.IPluginTransportContainer;
+import org.eclipse.net4j.util.container.IPluginContainer;
import org.eclipse.net4j.util.factory.IFactory;
import org.eclipse.net4j.util.factory.IFactoryKey;
import org.eclipse.net4j.util.registry.IRegistry;
@@ -23,11 +23,11 @@ import java.util.List;
/**
* @author Eike Stepper
*/
-public class PluginTransportContainer extends ManagedContainer implements IPluginTransportContainer
+public class PluginContainer extends ManagedContainer implements IPluginContainer
{
- private static PluginTransportContainer instance;
+ private static PluginContainer instance;
- private PluginTransportContainer()
+ private PluginContainer()
{
}
@@ -52,11 +52,11 @@ public class PluginTransportContainer extends ManagedContainer implements IPlugi
}
}
- public static synchronized PluginTransportContainer getInstance()
+ public static synchronized PluginContainer getInstance()
{
if (instance == null)
{
- instance = new PluginTransportContainer();
+ instance = new PluginContainer();
try
{
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/ReflectUtil.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/ReflectUtil.java
index f18b316..4ff6036 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/ReflectUtil.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/ReflectUtil.java
@@ -284,7 +284,7 @@ public final class ReflectUtil
return null;
}
- return getSimpleClassName(c.getName());
+ return c.getSimpleName();
}
public static String getSimpleClassName(String name)
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginTransportContainer.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginContainer.java
index 9ff726e..1c0be54 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginTransportContainer.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/container/IPluginContainer.java
@@ -10,13 +10,13 @@
**************************************************************************/
package org.eclipse.net4j.util.container;
-import org.eclipse.net4j.internal.util.container.PluginTransportContainer;
+import org.eclipse.net4j.internal.util.container.PluginContainer;
/**
* @author Eike Stepper
* @since 0.8.0
*/
-public interface IPluginTransportContainer extends IManagedContainer
+public interface IPluginContainer extends IManagedContainer
{
- public static final IPluginTransportContainer INSTANCE = PluginTransportContainer.getInstance();
+ public static final IPluginContainer INSTANCE = PluginContainer.getInstance();
}
diff --git a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/io/NIOUtil.java b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/io/NIOUtil.java
index b87e918..cbcc04b 100644
--- a/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/io/NIOUtil.java
+++ b/plugins/org.eclipse.net4j.util/src/org/eclipse/net4j/util/io/NIOUtil.java
@@ -95,7 +95,7 @@ public final class NIOUtil
if (!src.isFile() || !src.exists())
throw new IllegalArgumentException("Source file '" + src.getAbsolutePath() + "' not found!");
if (dst.exists()) if (dst.isDirectory()) // Directory? -> use source file
- // name
+ // name
dst = new File(dst, src.getName());
else if (dst.isFile())
{
diff --git a/plugins/org.eclipse.net4j/src/org/eclipse/internal/net4j/Channel.java b/plugins/org.eclipse.net4j/src/org/eclipse/internal/net4j/Channel.java
index 43421b0..bb19214 100644
--- a/plugins/org.eclipse.net4j/src/org/eclipse/internal/net4j/Channel.java
+++ b/plugins/org.eclipse.net4j/src/org/eclipse/internal/net4j/Channel.java
@@ -23,6 +23,7 @@ import org.eclipse.net4j.internal.util.lifecycle.Lifecycle;
import org.eclipse.net4j.internal.util.om.trace.ContextTracer;
import org.eclipse.net4j.util.ObjectUtil;
import org.eclipse.net4j.util.concurrent.IWorkSerializer;
+import org.eclipse.net4j.util.lifecycle.LifecycleUtil;
import org.eclipse.internal.net4j.bundle.OM;
@@ -226,6 +227,9 @@ public class Channel extends Lifecycle implements IChannel, IBufferProvider
@Override
protected void doDeactivate() throws Exception
{
+ LifecycleUtil.deactivate(receiveHandler);
+ receiveHandler = null;
+
connector.removeChannel(this);
receiveSerializer = null;
if (sendQueue != null)