Skip to content

Commit 06b1f1a

Browse files
committed
Correctly invoke update from CassandraBatchOperations.update.
Previously, we've called `insert` instead of `update`. Closes #1534
1 parent 40e1bc0 commit 06b1f1a

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
@@ -116,7 +116,7 @@ default CassandraBatchOperations update(Object entity, WriteOptions options) {
116116

117117
Assert.notNull(entity, "Entity must not be null");
118118

119-
return insert(Collections.singleton(entity), options);
119+
return update(Collections.singleton(entity), options);
120120
}
121121

122122
/**

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
@@ -139,7 +139,7 @@ default ReactiveCassandraBatchOperations update(Object entity, WriteOptions opti
139139

140140
Assert.notNull(entity, "Entity must not be null");
141141

142-
return insert(Collections.singleton(entity), options);
142+
return update(Collections.singleton(entity), options);
143143
}
144144

145145
/**

0 commit comments

Comments
 (0)