From: Tuukka Lehtonen Date: Mon, 5 Sep 2016 20:47:11 +0000 (+0300) Subject: Include acorn db in db.client feature and make it the default db driver X-Git-Tag: v1.25.0~136 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F52%2F52%2F1;p=simantics%2Fplatform.git Include acorn db in db.client feature and make it the default db driver refs #6596 Change-Id: I3be497696e5f0876387de5e6b5fb05144df2670b --- diff --git a/bundles/org.simantics.acorn/META-INF/MANIFEST.MF b/bundles/org.simantics.acorn/META-INF/MANIFEST.MF index 24f576bdc..9152acafd 100644 --- a/bundles/org.simantics.acorn/META-INF/MANIFEST.MF +++ b/bundles/org.simantics.acorn/META-INF/MANIFEST.MF @@ -4,17 +4,13 @@ Bundle-Name: Acorn Database for Simantics Bundle-SymbolicName: org.simantics.acorn Bundle-Version: 1.1.2.qualifier Bundle-Vendor: Semantum Oy -Require-Bundle: org.apache.log4j;visibility:=reexport, - org.simantics.db;bundle-version="0.8.0";visibility:=reexport, - org.simantics.db.common;bundle-version="0.8.0";visibility:=reexport, - gnu.trove3;bundle-version="3.0.0", +Require-Bundle: gnu.trove3;bundle-version="3.0.0", gnu.trove2;bundle-version="2.0.4", org.simantics.db.impl;bundle-version="0.8.0", org.simantics.db.server;bundle-version="1.0.0", org.simantics.compressions;bundle-version="1.0.0", org.simantics.backup, org.eclipse.core.runtime;bundle-version="3.11.1", - org.simantics.fastlz;bundle-version="1.2.1", org.simantics.db.procore Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy diff --git a/bundles/org.simantics.acorn/OSGI-INF/component.xml b/bundles/org.simantics.acorn/OSGI-INF/component.xml index 75dd81fd9..5b88ac3c0 100644 --- a/bundles/org.simantics.acorn/OSGI-INF/component.xml +++ b/bundles/org.simantics.acorn/OSGI-INF/component.xml @@ -1,6 +1,6 @@ - + diff --git a/bundles/org.simantics.project/src/org/simantics/project/management/ServerManagerFactory.java b/bundles/org.simantics.project/src/org/simantics/project/management/ServerManagerFactory.java index 3bde5dc42..4a673b97d 100644 --- a/bundles/org.simantics.project/src/org/simantics/project/management/ServerManagerFactory.java +++ b/bundles/org.simantics.project/src/org/simantics/project/management/ServerManagerFactory.java @@ -33,8 +33,8 @@ public class ServerManagerFactory { public static ServerManager create(String databaseId, String address) throws IOException, DatabaseException { Driver driver = Manager.getDriver(databaseId); if (driver == null) - throw new IllegalArgumentException("Database driver for ID " + databaseId + " Could not be found!"); - System.out.println("ServerManagerFactory.create called with databaseId=" + databaseId + " and driver is " + driver.toString()); + throw new IllegalArgumentException("Database driver with ID " + databaseId + " could not be found!"); + System.out.println("ServerManagerFactory.create called with id " + databaseId + ", driver is " + driver.toString()); DatabaseUserAgent agent = Manager.getUserAgent(databaseId); if (agent != null) driver.setDatabaseUserAgent(address, agent); diff --git a/bundles/org.simantics.workbench/src/org/simantics/workbench/internal/SimanticsWorkbenchAdvisor.java b/bundles/org.simantics.workbench/src/org/simantics/workbench/internal/SimanticsWorkbenchAdvisor.java index 2d054eaa7..362102172 100644 --- a/bundles/org.simantics.workbench/src/org/simantics/workbench/internal/SimanticsWorkbenchAdvisor.java +++ b/bundles/org.simantics.workbench/src/org/simantics/workbench/internal/SimanticsWorkbenchAdvisor.java @@ -134,7 +134,7 @@ public class SimanticsWorkbenchAdvisor extends WorkbenchAdvisor { /** * Default database ID */ - private static final String DEFAULT_DATABASE_ID = "procore"; + private static final String DEFAULT_DATABASE_ID = "acorn"; /** * The arguments received by the application. diff --git a/bundles/org.simantics/src/org/simantics/SimanticsPlatform.java b/bundles/org.simantics/src/org/simantics/SimanticsPlatform.java index 89a5d3dbd..611cfa575 100644 --- a/bundles/org.simantics/src/org/simantics/SimanticsPlatform.java +++ b/bundles/org.simantics/src/org/simantics/SimanticsPlatform.java @@ -39,8 +39,6 @@ import org.eclipse.core.runtime.Platform; import org.eclipse.core.runtime.Status; import org.eclipse.core.runtime.SubMonitor; import org.eclipse.osgi.service.resolver.BundleDescription; -import org.simantics.SimanticsPlatform.OntologyRecoveryPolicy; -import org.simantics.SimanticsPlatform.RecoveryPolicy; import org.simantics.databoard.Bindings; import org.simantics.databoard.Databoard; import org.simantics.datatypes.literal.Font; @@ -286,7 +284,9 @@ public class SimanticsPlatform implements LifecycleListener { // Check hash of transferable graph to know whether to update or not. if (platformBundle.getHashcode() == existingBundle.getHashcode()) continue; - System.out.println("Ontology hashcodes does not match! platformBundle" + platformBundle.getName() + ".getHashCode()=" + platformBundle.getHashcode() + " existingBundle" + existingBundle.getName() + ".getHashCode()=" + existingBundle.getHashcode()); + System.out.println("Ontology hashcodes do not match: platform bundle=" + + platformBundle.getVersionedId() + ", hash=" + platformBundle.getHashcode() + + "; existing bundle=" + existingBundle.getVersionedId() + ", hash=" + existingBundle.getHashcode()); reinstallTGs.put(platformBundle, existingBundle); } } diff --git a/features/org.simantics.db.client.feature/feature.xml b/features/org.simantics.db.client.feature/feature.xml index d6101139c..14ecb0bf6 100644 --- a/features/org.simantics.db.client.feature/feature.xml +++ b/features/org.simantics.db.client.feature/feature.xml @@ -73,6 +73,13 @@ install-size="0" version="0.0.0"/> + + + +