sanjeet006py commented on code in PR #2064:
URL: https://github.com/apache/phoenix/pull/2064#discussion_r1931978491


##########
phoenix-core-client/src/main/java/org/apache/phoenix/execute/MutationState.java:
##########
@@ -1530,7 +1531,7 @@ public List<Mutation> getMutationList() {
                         // REPLAY_ONLY_INDEX_WRITES for first batch
                         // only in case of 1121 SQLException
                         itrListMutation.remove();
-
+                        mutationBatchSuccessCounter++;

Review Comment:
   Got it. I agree when commit call has failed then our interest will be in 
knowing why it failed instead of knowing batch count. 
   Regarding existing `batchCount` variable, I didn't use it because its shared 
at MutationState object level. So, if multiple application threads are using 
one Phoenix connection then they all will increment it and we will end up 
double counting the number of batches. Though I don't think anyone should use 
Phoenix connection across multiple application threads but there is nothing 
stopping them.
   
   I will change to capturing no. of batches computed per commit call. Thanks



-- 
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: issues-unsubscr...@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to