Skip to content

Commit 5dc484e

Browse files
committed
Remove ListenableFuture support.
Closes #1548
1 parent 1dac7aa commit 5dc484e

28 files changed

+9
-6794
lines changed

spring-data-cassandra/src/main/java/org/springframework/data/cassandra/core/cql/AsyncResultStream.java

+3-4
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
import java.util.stream.Collector;
2323

2424
import org.springframework.util.Assert;
25-
import org.springframework.util.concurrent.ListenableFuture;
2625

2726
import com.datastax.oss.driver.api.core.cql.AsyncResultSet;
2827
import com.datastax.oss.driver.api.core.cql.Row;
@@ -75,7 +74,7 @@ <R> AsyncResultStream<R> map(RowMapper<R> mapper) {
7574

7675
/**
7776
* Performs a mutable reduction operation on the elements of this stream using a {@link Collector} resulting in a
78-
* {@link ListenableFuture}.
77+
* {@link CompletableFuture}.
7978
* <p>
8079
* This is a terminal operation.
8180
*
@@ -97,7 +96,7 @@ <R, A> CompletableFuture<R> collect(Collector<? super T, A, R> collector) {
9796
}
9897

9998
/**
100-
* Performs an action for each element of this stream. This method returns a {@link ListenableFuture} that completes
99+
* Performs an action for each element of this stream. This method returns a {@link CompletableFuture} that completes
101100
* without a value ({@code null}) once all elements have been processed.
102101
* <p>
103102
* This is a terminal operation.
@@ -177,7 +176,7 @@ void forEachAsync(CompletableFuture<Void> target, AsyncResultSet resultSet) {
177176
class CollectState<A, R> {
178177

179178
private final AtomicInteger rowNumber = new AtomicInteger();
180-
private volatile A intermediate;
179+
private final A intermediate;
181180
private final Collector<? super T, A, R> collector;
182181

183182
CollectState(Collector<? super T, A, R> collector) {

spring-data-cassandra/src/main/java/org/springframework/data/cassandra/core/cql/legacy/AsyncCqlOperations.java

-743
This file was deleted.

0 commit comments

Comments
 (0)