Skip to content

Commit 1ec6230

Browse files
committed
Correctly invoke update from CassandraBatchOperations.update.
Previously, we've called `insert` instead of `update`. Closes #1534
1 parent 8e9d9dc commit 1ec6230

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ default CassandraBatchOperations update(Object entity, WriteOptions options) {
159159

160160
Assert.notNull(entity, "Entity must not be null");
161161

162-
return insert(Collections.singleton(entity), options);
162+
return update(Collections.singleton(entity), options);
163163
}
164164

165165
/**

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ default ReactiveCassandraBatchOperations update(Object entity, WriteOptions opti
210210

211211
Assert.notNull(entity, "Entity must not be null");
212212

213-
return insert(Collections.singleton(entity), options);
213+
return update(Collections.singleton(entity), options);
214214
}
215215

216216
/**

0 commit comments

Comments
 (0)