alanwang67 commented on code in PR #4583:
URL: https://github.com/apache/cassandra/pull/4583#discussion_r2989936125


##########
src/java/org/apache/cassandra/cql3/statements/TransactionStatement.java:
##########
@@ -556,6 +560,36 @@ public ResultMessage execute(QueryState state, 
QueryOptions options, Dispatcher.
             checkTrue(returningSelect.select.getLimit(options) == 
DataLimits.NO_LIMIT, NO_PARTITION_IN_CLAUSE_WITH_LIMIT, "SELECT", 
returningSelect.select.source);
         }
 
+        // check that within a transaction we don't have multiple updates to 
the same primary key, column pair
+        HashMap<RowKey, Columns> seenRegularColumns = new HashMap<>();
+        HashMap<DecoratedKey, Columns> seenStaticColumns = new HashMap<>();
+
+        for (ModificationStatement statement : updates)
+        {
+            List<RowKey> rowKeys = 
statement.getRowKeys(state.getClientState(), options);

Review Comment:
   Just refactored to reuse the `TxnWrite.Fragment` for the `PartitionUpdate` 
and the `Clustering` columns. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to