Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix underReplicatedLedgerTotalSize calculate problem. (#3337)
Descriptions of the changes in this PR: ``` LongAdder underReplicatedSize = new LongAdder(); FutureUtils.processList( Lists.newArrayList(ledgers), ledgerId -> ledgerManager.readLedgerMetadata(ledgerId).whenComplete((metadata, exception) -> { if (exception == null) { underReplicatedSize.add(metadata.getValue().getLength()); } }), null); underReplicatedLedgerTotalSize.registerSuccessfulValue(underReplicatedSize.longValue()); ``` `FutureUtils.processList` is async process, should record `underReplicatedLedgerTotalSize` when it completed.
- Loading branch information