aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKajur, Harish (vk250x) <vk250x@att.com>2019-04-02 14:04:19 -0400
committerKajur, Harish (vk250x) <vk250x@att.com>2019-04-02 14:04:24 -0400
commitf2bf2ab992260d1896d0f4b6f947bbf80b82eb07 (patch)
treec338618a6e4d4e2617c42d42c94fac016d00335c
parent0338683186c994d579b1ec297604dba59df73dff (diff)
Add cql driver support for champ
Issue-ID: AAI-2308 Change-Id: I0a610eecb6b6dffe8df8f6458ee2184a763d343a Signed-off-by: Kajur, Harish (vk250x) <vk250x@att.com>
-rw-r--r--champ-lib/champ-janus/pom.xml28
-rw-r--r--champ-lib/champ-janus/src/main/java/org/onap/aai/champjanus/graph/impl/JanusChampGraphImpl.java7
-rw-r--r--champ-service-deps-janus/pom.xml68
3 files changed, 101 insertions, 2 deletions
diff --git a/champ-lib/champ-janus/pom.xml b/champ-lib/champ-janus/pom.xml
index 6d714df..94da7d0 100644
--- a/champ-lib/champ-janus/pom.xml
+++ b/champ-lib/champ-janus/pom.xml
@@ -89,6 +89,34 @@ limitations under the License.
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.janusgraph</groupId>
+ <artifactId>janusgraph-cql</artifactId>
+ <version>0.2.0</version>
+ <optional>true</optional>
+ <exclusions>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.tinkerpop</groupId>
+ <artifactId>gremlin-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.tinkerpop</groupId>
+ <artifactId>gremlin-groovy</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
<dependency>
<groupId>org.janusgraph</groupId>
diff --git a/champ-lib/champ-janus/src/main/java/org/onap/aai/champjanus/graph/impl/JanusChampGraphImpl.java b/champ-lib/champ-janus/src/main/java/org/onap/aai/champjanus/graph/impl/JanusChampGraphImpl.java
index f150b44..ea90ce9 100644
--- a/champ-lib/champ-janus/src/main/java/org/onap/aai/champjanus/graph/impl/JanusChampGraphImpl.java
+++ b/champ-lib/champ-janus/src/main/java/org/onap/aai/champjanus/graph/impl/JanusChampGraphImpl.java
@@ -50,6 +50,7 @@ import java.util.stream.StreamSupport;
public final class JanusChampGraphImpl extends AbstractTinkerpopChampGraph {
private static final Logger LOGGER = LoggerFactory.getLogger(JanusChampGraphImpl.class);
private static final String JANUS_CASSANDRA_KEYSPACE = "storage.cassandra.keyspace";
+ private static final String JANUS_CQL_KEYSPACE = "storage.cql.keyspace";
private static final String JANUS_HBASE_TABLE = "storage.hbase.table";
private static final String JANUS_UNIQUE_SUFFIX = "graph.unique-instance-id-suffix";
private static final ChampSchemaEnforcer SCHEMA_ENFORCER = new DefaultChampSchemaEnforcer();
@@ -87,8 +88,10 @@ public final class JanusChampGraphImpl extends AbstractTinkerpopChampGraph {
"cassandrathrift".equals(storageBackend) ||
"astyanax".equals(storageBackend) ||
"embeddedcassandra".equals(storageBackend)) {
-
- janusGraphBuilder.set(JANUS_CASSANDRA_KEYSPACE, builder.graphName);
+
+ janusGraphBuilder.set(JANUS_CASSANDRA_KEYSPACE, builder.graphName);
+ } else if("cql".equals(storageBackend)){
+ janusGraphBuilder.set(JANUS_CQL_KEYSPACE, builder.graphName);
} else if ("hbase".equals(storageBackend)) {
janusGraphBuilder.set(JANUS_HBASE_TABLE, builder.graphName);
} else if ("berkleyje".equals(storageBackend)) {
diff --git a/champ-service-deps-janus/pom.xml b/champ-service-deps-janus/pom.xml
index 05f4977..1fa571f 100644
--- a/champ-service-deps-janus/pom.xml
+++ b/champ-service-deps-janus/pom.xml
@@ -201,6 +201,74 @@ limitations under the License.
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.janusgraph</groupId>
+ <artifactId>janusgraph-cql</artifactId>
+ <version>0.2.0</version>
+ <optional>true</optional>
+ <exclusions>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.tinkerpop</groupId>
+ <artifactId>gremlin-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.tinkerpop</groupId>
+ <artifactId>gremlin-groovy</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpclient</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpcore</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.google.guava</groupId>
+ <artifactId>guava</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>javax.validation</groupId>
+ <artifactId>validation-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate-validator</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>net.jpountz.lz4</groupId>
+ <artifactId>lz4</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
<dependency>
<groupId>org.janusgraph</groupId>