Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoberto E. Escobar2014-12-08 22:17:44 +0000
committerAngel Avila2014-12-08 22:17:44 +0000
commit119e26fd1d956b646642a6f598be3425a4eda335 (patch)
treeba9c561ec4b0178ff9f4317c5a29e9718bbfbc64
parentec6358e83aead762af0ac8bf7d9a165c2cec09e0 (diff)
downloadorg.eclipse.osee-119e26fd1d956b646642a6f598be3425a4eda335.tar.gz
org.eclipse.osee-119e26fd1d956b646642a6f598be3425a4eda335.tar.xz
org.eclipse.osee-119e26fd1d956b646642a6f598be3425a4eda335.zip
feature[ats_ATS144309]: Move client OseeSql to skynet.core
-rw-r--r--plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java11
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactLoader.java6
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTransactionData.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/AttributeLoader.java10
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RelationLoader.java6
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java10
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTransactionData.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/OseeSql.java (renamed from plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/OseeSql.java)3
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/ServiceUtil.java12
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/accessors/DatabaseTransactionRecordAccessor.java6
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTransactionData.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ChangeManager.java8
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java12
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/RevisionChangeLoader.java8
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java14
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java17
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java14
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/BaseTransactionData.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/StoreSkynetTransactionOperation.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java7
20 files changed, 81 insertions, 75 deletions
diff --git a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
index 3eebf6e632..22607ee612 100644
--- a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
+++ b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
@@ -11,12 +11,11 @@
package org.eclipse.osee.framework.core.client;
import java.util.List;
+import java.util.Properties;
import org.eclipse.osee.framework.core.client.internal.InternalClientSessionManager;
import org.eclipse.osee.framework.core.data.IUserToken;
import org.eclipse.osee.framework.core.data.OseeSessionGrant;
import org.eclipse.osee.framework.core.exception.OseeAuthenticationRequiredException;
-import org.eclipse.osee.framework.database.core.OseeSql;
-import org.eclipse.osee.framework.jdk.core.type.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
/**
@@ -88,12 +87,8 @@ public class ClientSessionManager {
return getSessionGrant().getDatabaseInfo().isProduction();
}
- public static String getSql(OseeSql sqlEnum) throws OseeCoreException {
- String sql = getSessionGrant().getSqlProperties().getProperty(sqlEnum.toString());
- if (sql != null) {
- return sql;
- }
- throw new OseeArgumentException("Invalid sql key [%s]", sqlEnum.toString());
+ public static Properties getSqlProperties() {
+ return getSessionGrant().getSqlProperties();
}
public static List<String> getAuthenticationProtocols() {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactLoader.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactLoader.java
index 7fbcb4bf12..f0cc702ff3 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactLoader.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactLoader.java
@@ -21,7 +21,6 @@ import java.util.Map.Entry;
import java.util.Set;
import java.util.concurrent.locks.ReentrantLock;
import java.util.logging.Level;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IArtifactType;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.DeletionFlag;
@@ -32,13 +31,14 @@ import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.CompositeKeyHashMap;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.type.Pair;
import org.eclipse.osee.framework.jdk.core.util.Lib;
import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.framework.skynet.core.internal.Activator;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.utility.ArtifactJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -199,7 +199,7 @@ public final class ArtifactLoader {
String sql = null;
try {
- sql = ClientSessionManager.getSql(sqlKey);
+ sql = ServiceUtil.getSql(sqlKey);
chStmt.runPreparedQuery(fetchSize, sql, queryId);
int previousArtId = -1;
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTransactionData.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTransactionData.java
index d81c4c5a99..b29340ccf9 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTransactionData.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTransactionData.java
@@ -12,11 +12,11 @@ package org.eclipse.osee.framework.skynet.core.artifact;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.event.model.ArtifactEvent;
import org.eclipse.osee.framework.skynet.core.event.model.EventBasicGuidArtifact;
import org.eclipse.osee.framework.skynet.core.event.model.EventModType;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
import org.eclipse.osee.framework.skynet.core.transaction.BaseTransactionData;
/**
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/AttributeLoader.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/AttributeLoader.java
index 56f418ed08..64c04ff183 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/AttributeLoader.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/AttributeLoader.java
@@ -16,14 +16,12 @@ import static org.eclipse.osee.framework.core.enums.LoadLevel.RELATION_DATA;
import java.util.ArrayList;
import java.util.List;
import java.util.logging.Level;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IAttributeType;
import org.eclipse.osee.framework.core.enums.DeletionFlag;
import org.eclipse.osee.framework.core.enums.LoadLevel;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.CompositeKeyHashMap;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.util.Strings;
@@ -31,6 +29,8 @@ import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.framework.skynet.core.attribute.AttributeTypeManager;
import org.eclipse.osee.framework.skynet.core.attribute.BooleanAttribute;
import org.eclipse.osee.framework.skynet.core.attribute.EnumeratedAttribute;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
/**
* @author Ryan Schmitt
@@ -158,8 +158,8 @@ public class AttributeLoader {
Level.WARNING,
"multiple attribute version for attribute id [%d] artifact id[%d] branch[%d] previousGammaId[%s] currentGammaId[%s] previousModType[%s] currentModType[%s]",
- current.attrId, current.artifactId, current.branchUuid, previous.gammaId, current.gammaId, previous.modType,
- current.modType);
+ current.attrId, current.artifactId, current.branchUuid, previous.gammaId, current.gammaId,
+ previous.modType, current.modType);
}
}
@@ -198,6 +198,6 @@ public class AttributeLoader {
sqlKey = OseeSql.LOAD_CURRENT_ATTRIBUTES;
}
- return ClientSessionManager.getSql(sqlKey);
+ return ServiceUtil.getSql(sqlKey);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RelationLoader.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RelationLoader.java
index f1ad02e235..2e2cbb8898 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RelationLoader.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RelationLoader.java
@@ -13,15 +13,15 @@ package org.eclipse.osee.framework.skynet.core.artifact;
import static org.eclipse.osee.framework.core.enums.LoadLevel.ARTIFACT_AND_ATTRIBUTE_DATA;
import static org.eclipse.osee.framework.core.enums.LoadLevel.ARTIFACT_DATA;
import java.util.Collection;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.LoadLevel;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.type.RelationType;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.relation.RelationManager;
import org.eclipse.osee.framework.skynet.core.relation.RelationTypeManager;
@@ -41,7 +41,7 @@ class RelationLoader {
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- String sqlQuery = ClientSessionManager.getSql(OseeSql.LOAD_RELATIONS);
+ String sqlQuery = ServiceUtil.getSql(OseeSql.LOAD_RELATIONS);
chStmt.runPreparedQuery(artifacts.size() * 8, sqlQuery, joinQueryId);
while (chStmt.next()) {
int relationId = chStmt.getInt("rel_link_id");
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
index 069768243e..6acf4e001c 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
@@ -15,7 +15,6 @@ import java.util.ArrayList;
import java.util.Collection;
import java.util.HashSet;
import org.eclipse.core.runtime.Platform;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.enums.TxChange;
import org.eclipse.osee.framework.core.model.Branch;
@@ -23,11 +22,12 @@ import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.DbTransaction;
import org.eclipse.osee.framework.database.core.IOseeStatement;
import org.eclipse.osee.framework.database.core.OseeConnection;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.util.Collections;
import org.eclipse.osee.framework.jdk.core.util.Lib;
import org.eclipse.osee.framework.skynet.core.artifact.search.ArtifactQuery;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.utility.ArtifactJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -190,7 +190,7 @@ public class UpdateMergeBranch extends DbTransaction {
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.MERGE_GET_ARTIFACTS_FOR_BRANCH), branch.getUuid());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.MERGE_GET_ARTIFACTS_FOR_BRANCH), branch.getUuid());
while (chStmt.next()) {
artSet.add(chStmt.getInt("art_id"));
}
@@ -200,7 +200,7 @@ public class UpdateMergeBranch extends DbTransaction {
time = System.currentTimeMillis();
}
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.MERGE_GET_ATTRIBUTES_FOR_BRANCH), branch.getUuid());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.MERGE_GET_ATTRIBUTES_FOR_BRANCH), branch.getUuid());
while (chStmt.next()) {
artSet.add(chStmt.getInt("art_id"));
}
@@ -210,7 +210,7 @@ public class UpdateMergeBranch extends DbTransaction {
time = System.currentTimeMillis();
}
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.MERGE_GET_RELATIONS_FOR_BRANCH), branch.getUuid());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.MERGE_GET_RELATIONS_FOR_BRANCH), branch.getUuid());
while (chStmt.next()) {
artSet.add(chStmt.getInt("a_art_id"));
artSet.add(chStmt.getInt("b_art_id"));
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTransactionData.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTransactionData.java
index d2e38c89b6..1a9bff00a0 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTransactionData.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTransactionData.java
@@ -14,12 +14,12 @@ import org.eclipse.osee.framework.core.exception.OseeExceptions;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.core.util.HttpProcessor;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.util.Strings;
import org.eclipse.osee.framework.skynet.core.artifact.Attribute;
import org.eclipse.osee.framework.skynet.core.attribute.utils.AttributeURL;
import org.eclipse.osee.framework.skynet.core.event.model.ArtifactEvent;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
import org.eclipse.osee.framework.skynet.core.transaction.BaseTransactionData;
/**
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/OseeSql.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/OseeSql.java
index 7673092c30..ff8612a37d 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/OseeSql.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/OseeSql.java
@@ -8,13 +8,14 @@
* Contributors:
* Boeing - initial API and implementation
*******************************************************************************/
-package org.eclipse.osee.framework.database.core;
+package org.eclipse.osee.framework.skynet.core.internal;
import java.sql.DatabaseMetaData;
import java.util.Properties;
import org.eclipse.osee.framework.core.enums.ConflictStatus;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.enums.TxChange;
+import org.eclipse.osee.framework.database.core.SupportedDatabase;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
/**
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/ServiceUtil.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/ServiceUtil.java
index a746d46475..070b307c2c 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/ServiceUtil.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/ServiceUtil.java
@@ -10,14 +10,17 @@
*******************************************************************************/
package org.eclipse.osee.framework.skynet.core.internal;
+import java.util.Properties;
import java.util.logging.Level;
import org.eclipse.core.runtime.Platform;
import org.eclipse.osee.cache.admin.CacheAdmin;
+import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.model.TransactionRecordFactory;
import org.eclipse.osee.framework.core.services.IOseeCachingService;
import org.eclipse.osee.framework.core.services.IOseeModelFactoryService;
import org.eclipse.osee.framework.core.translation.IDataTranslationService;
import org.eclipse.osee.framework.database.IOseeDatabaseService;
+import org.eclipse.osee.framework.jdk.core.type.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.util.Conditions;
import org.eclipse.osee.framework.logging.OseeLog;
@@ -97,4 +100,13 @@ public final class ServiceUtil {
}
return getService(AccessPolicy.class);
}
+
+ public static String getSql(OseeSql sqlEnum) throws OseeCoreException {
+ Properties properties = ClientSessionManager.getSqlProperties();
+ String sql = properties.getProperty(sqlEnum.toString());
+ if (sql != null) {
+ return sql;
+ }
+ throw new OseeArgumentException("Invalid sql key [%s]", sqlEnum.toString());
+ }
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/accessors/DatabaseTransactionRecordAccessor.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/accessors/DatabaseTransactionRecordAccessor.java
index 3705d0028f..14118e480b 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/accessors/DatabaseTransactionRecordAccessor.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/internal/accessors/DatabaseTransactionRecordAccessor.java
@@ -2,7 +2,6 @@ package org.eclipse.osee.framework.skynet.core.internal.accessors;
import java.util.Collection;
import java.util.Date;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.TransactionDetailsType;
import org.eclipse.osee.framework.core.enums.TransactionVersion;
@@ -14,10 +13,11 @@ import org.eclipse.osee.framework.core.model.cache.ITransactionDataAccessor;
import org.eclipse.osee.framework.core.model.cache.TransactionCache;
import org.eclipse.osee.framework.database.IOseeDatabaseService;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.MutableInteger;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.type.OseeStateException;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.utility.IdJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -170,7 +170,7 @@ public class DatabaseTransactionRecordAccessor implements ITransactionDataAccess
@Override
public TransactionRecord getHeadTransaction(TransactionCache cache, Branch branch) throws OseeCoreException {
- String query = ClientSessionManager.getSql(OseeSql.TX_GET_MAX_AS_LARGEST_TX);
+ String query = ServiceUtil.getSql(OseeSql.TX_GET_MAX_AS_LARGEST_TX);
return cache.getOrLoad(oseeDatabaseService.runPreparedQueryFetchObject(-1, query, branch.getUuid()));
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTransactionData.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTransactionData.java
index 92c22b3e6c..eb09d143b7 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTransactionData.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTransactionData.java
@@ -14,10 +14,10 @@ import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.core.model.event.DefaultBasicUuidRelation;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.event.model.ArtifactEvent;
import org.eclipse.osee.framework.skynet.core.event.model.EventBasicGuidRelation;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
import org.eclipse.osee.framework.skynet.core.transaction.BaseTransactionData;
/**
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ChangeManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ChangeManager.java
index db33c0e49c..250a0f948d 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ChangeManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ChangeManager.java
@@ -13,7 +13,6 @@ package org.eclipse.osee.framework.skynet.core.revision;
import java.util.ArrayList;
import java.util.Collection;
import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.BranchArchivedState;
import org.eclipse.osee.framework.core.enums.BranchType;
@@ -23,7 +22,6 @@ import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.core.operation.IOperation;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.CompositeKeyHashMap;
import org.eclipse.osee.framework.jdk.core.type.HashCollection;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
@@ -31,6 +29,8 @@ import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.BranchManager;
import org.eclipse.osee.framework.skynet.core.change.ArtifactDelta;
import org.eclipse.osee.framework.skynet.core.change.Change;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.transaction.TransactionManager;
import org.eclipse.osee.framework.skynet.core.utility.ArtifactJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -122,7 +122,7 @@ public final class ChangeManager {
joinQuery.store();
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(joinQuery.size() * 2, ClientSessionManager.getSql(OseeSql.CHANGE_TX_MODIFYING),
+ chStmt.runPreparedQuery(joinQuery.size() * 2, ServiceUtil.getSql(OseeSql.CHANGE_TX_MODIFYING),
joinQuery.getQueryId());
while (chStmt.next()) {
Branch branch = BranchManager.getBranch(chStmt.getLong("branch_id"));
@@ -165,7 +165,7 @@ public final class ChangeManager {
joinQuery.store();
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(joinQuery.size() * 2, ClientSessionManager.getSql(OseeSql.CHANGE_BRANCH_MODIFYING),
+ chStmt.runPreparedQuery(joinQuery.size() * 2, ServiceUtil.getSql(OseeSql.CHANGE_BRANCH_MODIFYING),
joinQuery.getQueryId());
while (chStmt.next()) {
if (chStmt.getInt("tx_count") > 0) {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
index ddd9946ffc..d90da7f94a 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
@@ -19,7 +19,6 @@ import java.util.LinkedList;
import java.util.List;
import java.util.Set;
import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.ConflictStatus;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.exception.BranchMergeException;
@@ -27,7 +26,6 @@ import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
@@ -38,6 +36,8 @@ import org.eclipse.osee.framework.skynet.core.conflict.AttributeConflict;
import org.eclipse.osee.framework.skynet.core.conflict.AttributeConflictBuilder;
import org.eclipse.osee.framework.skynet.core.conflict.Conflict;
import org.eclipse.osee.framework.skynet.core.conflict.ConflictBuilder;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.transaction.TransactionManager;
import org.eclipse.osee.framework.skynet.core.utility.ArtifactJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -65,7 +65,7 @@ public class ConflictManagerInternal {
ArrayList<Conflict> conflicts = new ArrayList<Conflict>();
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CONFLICT_GET_HISTORICAL_ATTRIBUTES),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CONFLICT_GET_HISTORICAL_ATTRIBUTES),
commitTransaction.getId());
while (chStmt.next()) {
AttributeConflict attributeConflict =
@@ -112,10 +112,10 @@ public class ConflictManagerInternal {
TransactionRecord commonTransaction = findCommonTransaction(sourceBranch, destinationBranch);
- loadArtifactVersionConflicts(ClientSessionManager.getSql(OseeSql.CONFLICT_GET_ARTIFACTS_DEST), sourceBranch,
+ loadArtifactVersionConflicts(ServiceUtil.getSql(OseeSql.CONFLICT_GET_ARTIFACTS_DEST), sourceBranch,
destinationBranch, baselineTransaction, conflictBuilders, artIdSet, artIdSetDontShow, artIdSetDontAdd,
monitor, commonTransaction);
- loadArtifactVersionConflicts(ClientSessionManager.getSql(OseeSql.CONFLICT_GET_ARTIFACTS_SRC), sourceBranch,
+ loadArtifactVersionConflicts(ServiceUtil.getSql(OseeSql.CONFLICT_GET_ARTIFACTS_SRC), sourceBranch,
destinationBranch, baselineTransaction, conflictBuilders, artIdSet, artIdSetDontShow, artIdSetDontAdd,
monitor, commonTransaction);
loadAttributeConflictsNew(sourceBranch, destinationBranch, baselineTransaction, conflictBuilders, artIdSet,
@@ -229,7 +229,7 @@ public class ConflictManagerInternal {
int commonTransactionNumber = transactionId != null ? transactionId.getId() : 0;
long commonBranchId = transactionId != null ? transactionId.getBranchId() : 0;
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CONFLICT_GET_ATTRIBUTES), sourceBranch.getUuid(),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CONFLICT_GET_ATTRIBUTES), sourceBranch.getUuid(),
sourceBranch.getBaseTransaction().getId(), destinationBranch.getUuid(), commonBranchId,
commonTransactionNumber);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/RevisionChangeLoader.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/RevisionChangeLoader.java
index e04a7682f2..cc07aca606 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/RevisionChangeLoader.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/RevisionChangeLoader.java
@@ -19,14 +19,12 @@ import java.util.Map.Entry;
import java.util.Set;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.DeletionFlag;
import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.CompositeKeyHashMap;
import org.eclipse.osee.framework.jdk.core.type.HashCollection;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
@@ -41,6 +39,8 @@ import org.eclipse.osee.framework.skynet.core.change.Change;
import org.eclipse.osee.framework.skynet.core.change.ChangeBuilder;
import org.eclipse.osee.framework.skynet.core.change.RelationChange;
import org.eclipse.osee.framework.skynet.core.change.RelationChangeBuilder;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.revision.acquirer.ArtifactChangeAcquirer;
import org.eclipse.osee.framework.skynet.core.revision.acquirer.AttributeChangeAcquirer;
import org.eclipse.osee.framework.skynet.core.revision.acquirer.RelationChangeAcquirer;
@@ -97,14 +97,14 @@ public final class RevisionChangeLoader {
private void loadTransactions(Branch branch, Artifact artifact, TransactionRecord transactionId, Set<TransactionRecord> transactionIds) throws OseeCoreException {
IOseeStatement chStmt = ConnectionHandler.getStatement();
try {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.LOAD_REVISION_HISTORY_TRANSACTION_ATTR),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.LOAD_REVISION_HISTORY_TRANSACTION_ATTR),
artifact.getArtId(), branch.getUuid(), transactionId.getId());
while (chStmt.next()) {
transactionIds.add(TransactionManager.getTransactionId(chStmt.getInt("transaction_id")));
}
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.LOAD_REVISION_HISTORY_TRANSACTION_REL),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.LOAD_REVISION_HISTORY_TRANSACTION_REL),
artifact.getArtId(), artifact.getArtId(), branch.getUuid(), transactionId.getId());
while (chStmt.next()) {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
index 9136371d54..2e46a47585 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/ArtifactChangeAcquirer.java
@@ -15,19 +15,19 @@ import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.TransactionDelta;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.ArtifactTypeManager;
import org.eclipse.osee.framework.skynet.core.change.ArtifactChangeBuilder;
import org.eclipse.osee.framework.skynet.core.change.ChangeBuilder;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.transaction.TransactionManager;
/**
@@ -56,18 +56,18 @@ public class ArtifactChangeAcquirer extends ChangeAcquirer {
fromTransactionId = getSourceBranch().getBaseTransaction();
toTransactionId = TransactionManager.getHeadTransaction(getSourceBranch());
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_BRANCH_ARTIFACT),
- getSourceBranch().getUuid(), fromTransactionId.getId());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_BRANCH_ARTIFACT), getSourceBranch().getUuid(),
+ fromTransactionId.getId());
} else { //Changes per a transaction
toTransactionId = getTransaction();
if (getSpecificArtifact() != null) {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_TX_ARTIFACT_FOR_SPECIFIC_ARTIFACT),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ARTIFACT_FOR_SPECIFIC_ARTIFACT),
toTransactionId.getBranchId(), toTransactionId.getId(), getSpecificArtifact().getArtId());
fromTransactionId = toTransactionId;
} else {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_TX_ARTIFACT),
- toTransactionId.getBranchId(), toTransactionId.getId());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ARTIFACT), toTransactionId.getBranchId(),
+ toTransactionId.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransactionId);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
index 1f89871006..bc18c9c468 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/AttributeChangeAcquirer.java
@@ -16,7 +16,6 @@ import java.util.HashSet;
import java.util.Map;
import java.util.Set;
import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IArtifactType;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.ModificationType;
@@ -27,7 +26,6 @@ import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.core.model.type.AttributeType;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.ArtifactTypeManager;
@@ -35,6 +33,8 @@ import org.eclipse.osee.framework.skynet.core.attribute.AttributeTypeManager;
import org.eclipse.osee.framework.skynet.core.change.ArtifactChangeBuilder;
import org.eclipse.osee.framework.skynet.core.change.AttributeChangeBuilder;
import org.eclipse.osee.framework.skynet.core.change.ChangeBuilder;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.transaction.TransactionManager;
import org.eclipse.osee.framework.skynet.core.utility.ArtifactJoinQuery;
import org.eclipse.osee.framework.skynet.core.utility.JoinUtility;
@@ -71,20 +71,19 @@ public class AttributeChangeAcquirer extends ChangeAcquirer {
if (hasBranch) {
fromTransactionId = getSourceBranch().getBaseTransaction();
toTransaction = TransactionManager.getHeadTransaction(getSourceBranch());
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_BRANCH_ATTRIBUTE_IS),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_BRANCH_ATTRIBUTE_IS),
getSourceBranch().getUuid(), fromTransactionId.getId());
}//Changes per transaction number
else {
toTransaction = getTransaction();
if (hasSpecificArtifact) {
- chStmt.runPreparedQuery(
- ClientSessionManager.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS_FOR_SPECIFIC_ARTIFACT),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS_FOR_SPECIFIC_ARTIFACT),
toTransaction.getBranchId(), toTransaction.getId(), getSpecificArtifact().getArtId());
fromTransactionId = getTransaction();
} else {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS),
- toTransaction.getBranchId(), toTransaction.getId());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_IS), toTransaction.getBranchId(),
+ toTransaction.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransaction);
}
}
@@ -168,11 +167,11 @@ public class AttributeChangeAcquirer extends ChangeAcquirer {
if (hasBranch) {
wasValueBranch = sourceBranch;
- sql = ClientSessionManager.getSql(OseeSql.CHANGE_BRANCH_ATTRIBUTE_WAS);
+ sql = ServiceUtil.getSql(OseeSql.CHANGE_BRANCH_ATTRIBUTE_WAS);
sqlParamter = wasValueBranch.getUuid();
} else {
wasValueBranch = transactionId.getBranch();
- sql = ClientSessionManager.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_WAS);
+ sql = ServiceUtil.getSql(OseeSql.CHANGE_TX_ATTRIBUTE_WAS);
sqlParamter = transactionId.getId();
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
index ef452ac7ef..6f184a5f84 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/acquirer/RelationChangeAcquirer.java
@@ -13,19 +13,19 @@ package org.eclipse.osee.framework.skynet.core.revision.acquirer;
import java.util.ArrayList;
import java.util.Set;
import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.TransactionDelta;
import org.eclipse.osee.framework.core.model.TransactionRecord;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.ArtifactTypeManager;
import org.eclipse.osee.framework.skynet.core.change.ChangeBuilder;
import org.eclipse.osee.framework.skynet.core.change.RelationChangeBuilder;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.relation.RelationTypeManager;
import org.eclipse.osee.framework.skynet.core.transaction.TransactionManager;
@@ -54,19 +54,19 @@ public class RelationChangeAcquirer extends ChangeAcquirer {
if (hasBranch) {
fromTransactionId = getSourceBranch().getBaseTransaction();
toTransactionId = TransactionManager.getHeadTransaction(getSourceBranch());
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_BRANCH_RELATION),
- getSourceBranch().getUuid(), fromTransactionId.getId());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_BRANCH_RELATION), getSourceBranch().getUuid(),
+ fromTransactionId.getId());
} else {//Changes per a transaction
toTransactionId = getTransaction();
if (getSpecificArtifact() != null) {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_TX_RELATION_FOR_SPECIFIC_ARTIFACT),
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_RELATION_FOR_SPECIFIC_ARTIFACT),
toTransactionId.getBranchId(), toTransactionId.getId(), getSpecificArtifact().getArtId(),
getSpecificArtifact().getArtId());
fromTransactionId = toTransactionId;
} else {
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.CHANGE_TX_RELATION),
- toTransactionId.getBranchId(), toTransactionId.getId());
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.CHANGE_TX_RELATION), toTransactionId.getBranchId(),
+ toTransactionId.getId());
fromTransactionId = TransactionManager.getPriorTransaction(toTransactionId);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/BaseTransactionData.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/BaseTransactionData.java
index d9d9ff430d..d78833c656 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/BaseTransactionData.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/BaseTransactionData.java
@@ -13,9 +13,9 @@ package org.eclipse.osee.framework.skynet.core.transaction;
import org.eclipse.osee.framework.core.enums.ModificationType;
import org.eclipse.osee.framework.core.enums.TxChange;
import org.eclipse.osee.framework.core.model.TransactionRecord;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.skynet.core.event.model.ArtifactEvent;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
/**
* @author Jeff C. Phillips
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/StoreSkynetTransactionOperation.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/StoreSkynetTransactionOperation.java
index c1748817a7..92e401a624 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/StoreSkynetTransactionOperation.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/StoreSkynetTransactionOperation.java
@@ -21,7 +21,6 @@ import java.util.Set;
import java.util.logging.Level;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.enums.BranchState;
import org.eclipse.osee.framework.core.enums.TxChange;
import org.eclipse.osee.framework.core.model.Branch;
@@ -44,6 +43,7 @@ import org.eclipse.osee.framework.skynet.core.event.OseeEventManager;
import org.eclipse.osee.framework.skynet.core.event.model.ArtifactEvent;
import org.eclipse.osee.framework.skynet.core.event.model.EventModifiedBasicGuidArtifact;
import org.eclipse.osee.framework.skynet.core.internal.Activator;
+import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.transaction.BaseTransactionData.InsertDataCollector;
/**
@@ -173,7 +173,7 @@ public final class StoreSkynetTransactionOperation extends AbstractOperation imp
private static void fetchTxNotCurrent(OseeConnection connection, Branch branch, BaseTransactionData transactionData, List<Object[]> results) throws OseeCoreException {
IOseeStatement chStmt = ConnectionHandler.getStatement(connection);
try {
- String query = ClientSessionManager.getSql(transactionData.getSelectTxNotCurrentSql());
+ String query = ServiceUtil.getSql(transactionData.getSelectTxNotCurrentSql());
chStmt.runPreparedQuery(query, transactionData.getItemId(), branch.getUuid());
while (chStmt.next()) {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
index bd3abd0464..bf083f587a 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
@@ -18,7 +18,6 @@ import java.util.Collection;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
-import org.eclipse.osee.framework.core.client.ClientSessionManager;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.enums.TransactionDetailsType;
import org.eclipse.osee.framework.core.exception.TransactionDoesNotExist;
@@ -31,13 +30,13 @@ import org.eclipse.osee.framework.core.services.IOseeCachingService;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
import org.eclipse.osee.framework.database.core.OseeConnection;
-import org.eclipse.osee.framework.database.core.OseeSql;
import org.eclipse.osee.framework.jdk.core.type.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.util.Conditions;
import org.eclipse.osee.framework.jdk.core.util.GUID;
import org.eclipse.osee.framework.jdk.core.util.time.GlobalTime;
import org.eclipse.osee.framework.skynet.core.User;
import org.eclipse.osee.framework.skynet.core.artifact.BranchManager;
+import org.eclipse.osee.framework.skynet.core.internal.OseeSql;
import org.eclipse.osee.framework.skynet.core.internal.ServiceUtil;
import org.eclipse.osee.framework.skynet.core.types.IArtifact;
@@ -170,7 +169,7 @@ public final class TransactionManager {
public static TransactionRecord getHeadTransaction(IOseeBranch branch) throws OseeCoreException {
long branchUuid = branch.getUuid();
int transactionNumber =
- ConnectionHandler.runPreparedQueryFetchInt(-1, ClientSessionManager.getSql(OseeSql.TX_GET_MAX_AS_LARGEST_TX),
+ ConnectionHandler.runPreparedQueryFetchInt(-1, ServiceUtil.getSql(OseeSql.TX_GET_MAX_AS_LARGEST_TX),
branchUuid);
if (transactionNumber == -1) {
throw new TransactionDoesNotExist("No transactions where found in the database for branch: %d", branchUuid);
@@ -256,7 +255,7 @@ public final class TransactionManager {
try {
if (useLocalConnection) {
chStmt = ConnectionHandler.getStatement();
- chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.TX_GET_ALL_TRANSACTIONS), txId);
+ chStmt.runPreparedQuery(ServiceUtil.getSql(OseeSql.TX_GET_ALL_TRANSACTIONS), txId);
if (!chStmt.next()) {
throw new TransactionDoesNotExist("The transaction id %d does not exist in the databse.", txId);
}

Back to the top