Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ under the License.

### 4.19.2

- [improvement] Remove unused DSE Graph support and TinkerPop integration (#1028)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Minor] 🟡 Two things. This lands under ### 4.19.2, which is already released, while the working version is 4.19.2.2-SNAPSHOT - anyone diffing 4.19.2 against its published artifact sees an entry that was not in it. And [improvement] puts a binary-breaking change (CqlSession no longer implements GraphSession, 20 DseDriverOption constants deleted) in the same bucket as "Remove unnecessary locking in DefaultNettyOptions" - that tag is the signal users scan before a patch upgrade to decide whether they have to recompile.

- [bug] CASSJAVA-116: Retry or Speculative Execution with RequestIdGenerator throws "Duplicate Key"

### 4.19.1
Expand Down
22 changes: 1 addition & 21 deletions core-shaded/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -99,16 +99,6 @@
<artifactId>esri-geometry-api</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>gremlin-core</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>tinkergraph-gremlin</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.reactivestreams</groupId>
<artifactId>reactive-streams</artifactId>
Expand Down Expand Up @@ -316,16 +306,6 @@
<artifactId>lz4-java</artifactId>
<version>${lz4.version}</version>
</additionalDependency>
<additionalDependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>gremlin-core</artifactId>
<version>${tinkerpop.version}</version>
</additionalDependency>
<additionalDependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>tinkergraph-gremlin</artifactId>
<version>${tinkerpop.version}</version>
</additionalDependency>
<additionalDependency>
<groupId>com.esri.geometry</groupId>
<artifactId>esri-geometry-api</artifactId>
Expand Down Expand Up @@ -375,7 +355,7 @@
Note: dependencies marked as optional are by default included with optional
resolution in the manifest; we only need to manually set the resolution to
optional for dependencies declared as non-optional in the pom files.
-->jnr.*;resolution:=optional, com.esri.core.geometry.*;resolution:=optional,org.reactivestreams.*;resolution:=optional, org.apache.tinkerpop.*;resolution:=optional, org.javatuples.*;resolution:=optional, reactor.blockhound.*;resolution:=optional,
-->jnr.*;resolution:=optional, com.esri.core.geometry.*;resolution:=optional,org.reactivestreams.*;resolution:=optional, reactor.blockhound.*;resolution:=optional,
<!--
5) Don't import packages imported by shaded classes, if they are not used by the
driver bundle.
Expand Down
12 changes: 1 addition & 11 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,16 +88,6 @@
<artifactId>esri-geometry-api</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>gremlin-core</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.tinkerpop</groupId>
<artifactId>tinkergraph-gremlin</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
Expand Down Expand Up @@ -324,7 +314,7 @@
Note: dependencies marked as optional are by default included with optional
resolution in the manifest; we only need to manually set the resolution to
optional for dependencies declared as non-optional in the pom files.
-->jnr.*;resolution:=optional, com.esri.core.geometry.*;resolution:=optional, org.reactivestreams.*;resolution:=optional, org.apache.tinkerpop.*;resolution:=optional, org.javatuples.*;resolution:=optional, reactor.blockhound.*;resolution:=optional, *
-->jnr.*;resolution:=optional, com.esri.core.geometry.*;resolution:=optional, org.reactivestreams.*;resolution:=optional, reactor.blockhound.*;resolution:=optional, *
</Import-Package>
<Export-Package>com.datastax.oss.driver.*.core.*, com.datastax.dse.driver.*.core.*</Export-Package>
</instructions>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
*/
package com.datastax.dse.driver.api.core.auth;

import com.datastax.dse.driver.api.core.graph.GraphStatement;
import com.datastax.oss.driver.api.core.cql.Statement;
import com.datastax.oss.driver.shaded.guava.common.base.Charsets;
import com.datastax.oss.protocol.internal.util.collection.NullAllowingImmutableMap;
Expand Down Expand Up @@ -52,18 +51,6 @@ public static <StatementT extends Statement<StatementT>> StatementT executeAs(
addProxyExecuteEntry(statement.getCustomPayload(), userOrRole));
}

/**
* Adds proxy authentication information to a graph statement.
*
* @see #executeAs(String, Statement)
*/
@NonNull
public static <StatementT extends GraphStatement<StatementT>> StatementT executeAs(
@NonNull String userOrRole, @NonNull StatementT statement) {
return statement.setCustomPayload(
addProxyExecuteEntry(statement.getCustomPayload(), userOrRole));
}

private static Map<String, ByteBuffer> addProxyExecuteEntry(
Map<String, ByteBuffer> currentPayload, @NonNull String userOrRole) {
NullAllowingImmutableMap.Builder<String, ByteBuffer> builder =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,131 +125,13 @@ public enum DseDriverOption implements DriverOption {
CONTINUOUS_PAGING_METRICS_SESSION_CQL_REQUESTS_INTERVAL(
"advanced.metrics.session.continuous-cql-requests.refresh-interval"),

/**
* The read consistency level to use for graph statements.
*
* <p>Value type: {@link String}
*/
GRAPH_READ_CONSISTENCY_LEVEL("basic.graph.read-consistency-level"),
/**
* The write consistency level to use for graph statements.
*
* <p>Value type: {@link String}
*/
GRAPH_WRITE_CONSISTENCY_LEVEL("basic.graph.write-consistency-level"),
/**
* The traversal source to use for graph statements.
*
* <p>Value type: {@link String}
*/
GRAPH_TRAVERSAL_SOURCE("basic.graph.traversal-source"),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Blocker] 🔴 Public enum constants removed with no deprecation cycle, in a 4th-component version (4.19.2.2-SNAPSHOT).

Beyond source compatibility: OptionsMap.SerializationProxy serializes Map<DriverOption, Object> directly and Java serializes enums by name, so any OptionsMap written by a <=4.19.2 driver fails to deserialize with InvalidObjectException: enum constant GRAPH_TRAVERSAL_SOURCE does not exist in class DseDriverOption. fillWithDriverDefaults put this constant unconditionally, so it is every serialized instance - which is the distributed-config case the Serializable contract exists for.

revapi will not catch it here: the verify log shows Comparing [] against [com.scylladb:java-driver-core:jar:4.19.2.2-SNAPSHOT], so the old artifact never resolves and core/revapi.json is inert.

Suggest keeping the constants @Deprecated and removing only the implementation, the way RESOLVE_CONTACT_POINTS was handled. Same for the ~20 TypedDriverOption fields, DseNodeMetric, the two DseSessionMetric constants, and dropping GraphSession/ReactiveGraphSession from CqlSession.

/**
* The sub-protocol the driver will use to communicate with DSE Graph, on top of the Cassandra
* native protocol.
*
* <p>Value type: {@link String}
*/
GRAPH_SUB_PROTOCOL("advanced.graph.sub-protocol"),
/**
* Whether a script statement represents a system query.
*
* <p>Value type: boolean
*/
GRAPH_IS_SYSTEM_QUERY("basic.graph.is-system-query"),
/**
* The name of the graph targeted by graph statements.
*
* <p>Value type: {@link String}
*/
GRAPH_NAME("basic.graph.name"),
/**
* How long the driver waits for a graph request to complete.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
GRAPH_TIMEOUT("basic.graph.timeout"),

/**
* Whether to send events for Insights monitoring.
*
* <p>Value type: boolean
*/
MONITOR_REPORTING_ENABLED("advanced.monitor-reporting.enabled"),

/**
* Whether to enable paging for Graph queries.
*
* <p>Value type: {@link String}
*/
GRAPH_PAGING_ENABLED("advanced.graph.paging-enabled"),

/**
* The page size for Graph continuous paging.
*
* <p>Value type: int
*/
GRAPH_CONTINUOUS_PAGING_PAGE_SIZE("advanced.graph.paging-options.page-size"),

/**
* The maximum number of Graph continuous pages to return.
*
* <p>Value type: int
*/
GRAPH_CONTINUOUS_PAGING_MAX_PAGES("advanced.graph.paging-options.max-pages"),
/**
* The maximum number of Graph continuous pages per second.
*
* <p>Value type: int
*/
GRAPH_CONTINUOUS_PAGING_MAX_PAGES_PER_SECOND(
"advanced.graph.paging-options.max-pages-per-second"),
/**
* The maximum number of Graph continuous pages that can be stored in the local queue.
*
* <p>Value type: int
*/
GRAPH_CONTINUOUS_PAGING_MAX_ENQUEUED_PAGES("advanced.graph.paging-options.max-enqueued-pages"),
/**
* The largest latency that we expect to record for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_SESSION_GRAPH_REQUESTS_HIGHEST("advanced.metrics.session.graph-requests.highest-latency"),
/**
* The number of significant decimal digits to which internal structures will maintain for graph
* requests.
*
* <p>Value-type: int
*/
METRICS_SESSION_GRAPH_REQUESTS_DIGITS(
"advanced.metrics.session.graph-requests.significant-digits"),
/**
* The interval at which percentile data is refreshed for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_SESSION_GRAPH_REQUESTS_INTERVAL(
"advanced.metrics.session.graph-requests.refresh-interval"),
/**
* The largest latency that we expect to record for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_NODE_GRAPH_MESSAGES_HIGHEST("advanced.metrics.node.graph-messages.highest-latency"),
/**
* The number of significant decimal digits to which internal structures will maintain for graph
* requests.
*
* <p>Value-type: int
*/
METRICS_NODE_GRAPH_MESSAGES_DIGITS("advanced.metrics.node.graph-messages.significant-digits"),
/**
* The interval at which percentile data is refreshed for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_NODE_GRAPH_MESSAGES_INTERVAL("advanced.metrics.node.graph-messages.refresh-interval"),

/**
* The shortest latency that we expect to record for continuous requests.
*
Expand All @@ -265,49 +147,6 @@ public enum DseDriverOption implements DriverOption {
CONTINUOUS_PAGING_METRICS_SESSION_CQL_REQUESTS_SLO(
"advanced.metrics.session.continuous-cql-requests.slo"),

/**
* The shortest latency that we expect to record for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_SESSION_GRAPH_REQUESTS_LOWEST("advanced.metrics.session.graph-requests.lowest-latency"),
/**
* Optional service-level objectives to meet, as a list of latencies to track.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_SESSION_GRAPH_REQUESTS_SLO("advanced.metrics.session.graph-requests.slo"),

/**
* The shortest latency that we expect to record for graph requests.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_NODE_GRAPH_MESSAGES_LOWEST("advanced.metrics.node.graph-messages.lowest-latency"),
/**
* Optional service-level objectives to meet, as a list of latencies to track.
*
* <p>Value-type: {@link java.time.Duration Duration}
*/
METRICS_NODE_GRAPH_MESSAGES_SLO("advanced.metrics.node.graph-messages.slo"),
/**
* Optional list of percentiles to publish for graph-requests metric. Produces an additional time
* series for each requested percentile. This percentile is computed locally, and so can't be
* aggregated with percentiles computed across other dimensions (e.g. in a different instance).
*
* <p>Value type: {@link java.util.List List}&#60;{@link Double}&#62;
*/
METRICS_SESSION_GRAPH_REQUESTS_PUBLISH_PERCENTILES(
"advanced.metrics.session.graph-requests.publish-percentiles"),
/**
* Optional list of percentiles to publish for node graph-messages metric. Produces an additional
* time series for each requested percentile. This percentile is computed locally, and so can't be
* aggregated with percentiles computed across other dimensions (e.g. in a different instance).
*
* <p>Value type: {@link java.util.List List}&#60;{@link Double}&#62;
*/
METRICS_NODE_GRAPH_MESSAGES_PUBLISH_PERCENTILES(
"advanced.metrics.node.graph-messages.publish-percentiles"),
/**
* Optional list of percentiles to publish for continuous paging requests metric. Produces an
* additional time series for each requested percentile. This percentile is computed locally, and
Expand Down

This file was deleted.

Loading
Loading