CalvinConfluent commented on code in PR #19355:
URL: https://github.com/apache/kafka/pull/19355#discussion_r2056904119


##########
core/src/main/scala/kafka/coordinator/transaction/TransactionStateManager.scala:
##########
@@ -343,6 +345,9 @@ class TransactionStateManager(brokerId: Int,
             false
           } else if (filterDurationMs >= 0 && (now - 
txnMetadata.txnStartTimestamp) <= filterDurationMs) {
             false
+          } else if (!filterTransactionalIdPattern.isEmpty &&
+            
!Pattern.compile(filterTransactionalIdPattern).matcher(txnMetadata.transactionalId).matches())
 {

Review Comment:
   Sounds good.



##########
clients/src/main/java/org/apache/kafka/clients/admin/ListTransactionsOptions.java:
##########
@@ -70,6 +71,19 @@ public ListTransactionsOptions filterOnDuration(long 
durationMs) {
         return this;
     }
 
+    /**
+     * Filter only the transactions that match with the given transactional ID 
pattern.
+     * If no filter is specified or if the passed string is empty,

Review Comment:
   Good catch! 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: jira-unsubscr...@kafka.apache.org

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

Reply via email to