[
https://issues.apache.org/jira/browse/ZOOKEEPER-4362?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated ZOOKEEPER-4362:
--------------------------------------
Labels: pull-request-available (was: )
> ZKDatabase.txnCount logged non transactional requests
> -----------------------------------------------------
>
> Key: ZOOKEEPER-4362
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-4362
> Project: ZooKeeper
> Issue Type: Bug
> Components: server
> Reporter: LiAoNan
> Priority: Major
> Labels: pull-request-available
> Time Spent: 10m
> Remaining Estimate: 0h
>
> ZKDatabase.txnCount logged non transactional requests
> {code:java}
> public boolean append(Request si) throws IOException {
> txnCount.incrementAndGet();
> return this.snapLog.append(si);
> }
> {code}
> snaplog.append may return false, but txnCount increased
> maybe it would be better
> {code:java}
> public boolean append(Request si) throws IOException {
> if (this.snapLog.append(si)) {
> txnCount.incrementAndGet();
> return true;
> }
> return false;
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)