aweisberg commented on code in PR #3694:
URL: https://github.com/apache/cassandra/pull/3694#discussion_r1853080608
##########
src/java/org/apache/cassandra/cql3/statements/TransactionStatement.java:
##########
@@ -346,10 +340,7 @@ public Txn createTxn(ClientState state, QueryOptions
options)
List<TxnNamedRead> reads = createNamedReads(options, state, null,
keySet::add);
Keys txnKeys = toKeys(keySet);
TxnKeyRead read = createTxnRead(reads, null);
- Txn.Kind kind = txnKeys.size() == 1
- && transactionalModeForSingleKey(txnKeys) ==
TransactionalMode.full
- &&
DatabaseDescriptor.getAccordEphemeralReadEnabledEnabled()
- ? EphemeralRead : Read;
+ Txn.Kind kind = shouldReadEphemerally(txnKeys,
Schema.instance.getTableMetadata(((AccordRoutableKey)
txnKeys.get(0)).table()).params, Read);
Review Comment:
In the process of setting up and routing an operation we fetch the table
parameters repeatedly from the cluster metadata. In a lot of cases we have
already fetched them from the `ClusterMetadata` and could re-use them. I don't
really have a preference since in the big picture this isn't the thing that is
making C* slow.
--
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]