Page MenuHomePhabricator

rpc: Expose g_is_mempool_loaded via getmempoolinfo
ClosedPublic

Authored by fpelliccioni on Oct 11 2019, 21:08.

Details

Summary

And use it to fix a race condition in mempool_persist.py:
https://travis-ci.org/Empact/bitcoin/jobs/487577243

Backport of Bitcoin Core PR15323
https://github.com/bitcoin/bitcoin/pull/15323

Depends on D4234 and D4266.

Test Plan
ninja check-all
  • Read the docs.

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

fpelliccioni created this revision.Oct 11 2019, 21:08
Herald added a reviewer: Restricted Project. · View Herald TranscriptOct 11 2019, 21:08
fpelliccioni planned changes to this revision.Oct 11 2019, 21:09
fpelliccioni edited the test plan for this revision. (Show Details)

I have to fix the squash

fpelliccioni edited the summary of this revision. (Show Details)Tue, Oct 15, 13:46
fpelliccioni edited the test plan for this revision. (Show Details)
fpelliccioni updated this revision to Diff 13562.Tue, Oct 15, 14:05
fpelliccioni edited the test plan for this revision. (Show Details)

fix the rebase

Fabien requested changes to this revision.Wed, Oct 16, 15:20
Fabien added inline comments.
src/validation.cpp
5641 ↗(On Diff #13562)

Part of the PR is missing here.

This revision now requires changes to proceed.Wed, Oct 16, 15:20
fpelliccioni added inline comments.Wed, Oct 16, 15:47
src/validation.cpp
5641 ↗(On Diff #13562)

I tracked these changes to this commit:
https://github.com/jasonbcox/bitcoin/commit/26fee4f6b

It's very old, I guess it hasn't been backported on purpose.

I think you got the dependency reversed.

I think you got the dependency reversed.

I ordered the dependencies based on the date of the log:

12aa2ac98 - Merge #15323: rpc: Expose g_is_mempool_loaded via getmempoolinfo (2019-05-01 ~ 5 months ago) <MarcoFalke>
3515612e0 - Merge #15473: bench: Benchmark MempoolToJSON (2019-03-06 ~ 7 months ago) <MarcoFalke>
fpelliccioni requested review of this revision.Fri, Oct 18, 14:26
deadalnix requested changes to this revision.Wed, Oct 23, 01:45

Please rebase, otherwise LGTM.

src/validation.cpp
5641 ↗(On Diff #13562)

You need to rebase on top of that patch.

This revision now requires changes to proceed.Wed, Oct 23, 01:45
deadalnix requested changes to this revision.Thu, Oct 24, 01:07

Actually do the rebase an the backport, not just run the git rebase command.

This revision now requires changes to proceed.Thu, Oct 24, 01:07

Actually do the rebase an the backport, not just run the git rebase command.

Sorry for not clarifying what I did:
D4266 was landed...
Then I rebased from master: git rebase -i master
... and then from the D4234 branch: git rebase -i arcpatch-D4234

fpelliccioni requested review of this revision.Thu, Oct 24, 19:12

Please see my previous comment clarifying how I made the rebase.

deadalnix requested changes to this revision.Fri, Oct 25, 01:05
deadalnix added inline comments.
src/validation.cpp
5647 ↗(On Diff #13673)

here

This revision now requires changes to proceed.Fri, Oct 25, 01:05
fpelliccioni updated this revision to Diff 13701.Fri, Oct 25, 14:58

Applies backport changes.

Fabien accepted this revision.Sat, Oct 26, 06:53
deadalnix accepted this revision.Mon, Oct 28, 00:02
This revision is now accepted and ready to land.Mon, Oct 28, 00:02
fpelliccioni updated this revision to Diff 13740.Tue, Oct 29, 14:28

rebase from master