Jude Nelson
|
4843cc6ec4
|
refactor: create block builder settings should be a function of the config
|
2021-08-31 18:44:39 -04:00 |
|
Jude Nelson
|
f4018764b3
|
fix: fix failing integration tests because we now need a positive tx fee
|
2021-08-31 16:41:56 -04:00 |
|
Jude Nelson
|
aa35cf35d1
|
refactor: only pass one tx into todo in iterate_candidates(), and also, keep going until we reach the end of the list of origins
|
2021-08-31 16:41:22 -04:00 |
|
Jude Nelson
|
bc18248ad6
|
refactor: only one tx will be passed per call to iterate_candidates
|
2021-08-31 16:40:52 -04:00 |
|
Jude Nelson
|
bee409cfc9
|
fix: make size-check integration test a little more forgiving of non-determinism
|
2021-08-30 22:28:21 -04:00 |
|
Jude Nelson
|
4e8839c772
|
fix: don't keep iterating through candidates in the mempool if we stop considering new ones
|
2021-08-30 22:27:42 -04:00 |
|
Jude Nelson
|
3a39b1916d
|
Merge branch 'fix/2772' of https://github.com/blockstack/stacks-blockchain into fix/2772
|
2021-08-30 18:17:44 -04:00 |
|
Jude Nelson
|
f59542cd27
|
chore: fix integration test with new mempool walk
|
2021-08-30 18:17:07 -04:00 |
|
Aaron Blankstein
|
6e3b87314a
|
Merge branch 'develop' into fix/2772
2.0.11.3.0-rc1
|
2021-08-30 16:52:34 -05:00 |
|
Jude Nelson
|
e45b21392f
|
chore: run new integration test for mempool mining fairness
|
2021-08-30 17:51:07 -04:00 |
|
Jude Nelson
|
0672e26603
|
feat: add a test that verifies that origin address consideration is fair -- i.e. all origins that meet the minimum tx fee are considered in a round-robin fashion
|
2021-08-30 17:50:38 -04:00 |
|
Jude Nelson
|
18db0b0b3b
|
refactor: remove unused done flag, and instead have iterate_candidates() return the number of transactions considered
|
2021-08-30 17:50:05 -04:00 |
|
Jude Nelson
|
fe192dbde9
|
feat: try iterating through the mempool over and over again as more and more transactions become available, until either no transactions are minable, or we're out of time
|
2021-08-30 17:49:19 -04:00 |
|
Aaron Blankstein
|
56740c2842
|
Merge pull request #2824 from blockstack/feat/bullseye-dockerfiles
Build: buster -> bullseye in rust testing dockerfiles
|
2021-08-30 16:11:27 -05:00 |
|
Jude Nelson
|
410a26be9c
|
fix: only consider each origin address *once* per mempool walk; update the unit test to reflect this
|
2021-08-30 15:07:53 -04:00 |
|
Jude Nelson
|
b93b63047c
|
chore: changelog entry should be "Not Yet Released"
|
2021-08-30 15:06:53 -04:00 |
|
Jude Nelson
|
eb0009b5a2
|
chore: add mining section to the README that describes the new mining parameters
|
2021-08-30 12:48:08 -04:00 |
|
Jude Nelson
|
48a84eb2c8
|
chore: run new integration tests in CI
|
2021-08-30 12:47:52 -04:00 |
|
Jude Nelson
|
aaed25111b
|
refactor: remove min_cumulative_fee since it's not used anymore
|
2021-08-30 12:47:35 -04:00 |
|
Jude Nelson
|
2f77d56a8e
|
fix: remove sleep_before_tenure since it's no longer used
|
2021-08-30 12:47:20 -04:00 |
|
Jude Nelson
|
6ce86c3615
|
fix: remove cumulative tx fee setting
|
2021-08-30 12:45:57 -04:00 |
|
Jude Nelson
|
6a0ec8e6cb
|
fix: prioritize mempool transactions by tx fee, not cumulative tx fee, and expose timeouts as debug-level log messages
|
2021-08-30 12:45:28 -04:00 |
|
Jude Nelson
|
d921635f41
|
chore: add changelog entry for new mining behavior
|
2021-08-30 12:45:00 -04:00 |
|
Aaron Blankstein
|
3a5871644a
|
build: buster -> bullseye in rust testing dockerfiles
|
2021-08-30 09:26:39 -05:00 |
|
Jude Nelson
|
f5f7e9549c
|
fix: fix failing integration test due to mempool walk timeout
|
2021-08-28 01:00:42 -04:00 |
|
Jude Nelson
|
382e5d0fdc
|
chore: remove commented-out code
|
2021-08-28 01:00:26 -04:00 |
|
Jude Nelson
|
d55d60aa75
|
fix: remove now-unneeded config item for mining
|
2021-08-28 01:00:10 -04:00 |
|
Jude Nelson
|
4c6c4b1d88
|
fix: iterate through *all* transactions sent by a given origin address, and report the total number of transactions iterated through (as well as total number of origins considered). This fixes an early return bug.
|
2021-08-28 00:59:32 -04:00 |
|
Jude Nelson
|
86b788064c
|
fix: fix failing test with better fee
|
2021-08-28 00:58:55 -04:00 |
|
Jude Nelson
|
ba771ad035
|
feat: always try and mine a new block immediately after committing to an empty block, and always try to mine if the burnchain tip changes
|
2021-08-27 23:03:43 +00:00 |
|
Jude Nelson
|
5ef53c8423
|
chore: cargo fmt
|
2021-08-27 23:03:16 +00:00 |
|
Jude Nelson
|
918127c7a5
|
chore: cargo fmt
|
2021-08-27 23:02:56 +00:00 |
|
EC2 Default User
|
3611b13d19
|
feat: log more details on block-building
|
2021-08-27 23:00:34 +00:00 |
|
Jude Nelson
|
98abd88f7f
|
feat: use the miner config's first and subsequent maximum mining times to determine how much time to spend trying to mine an anchored block. Also, rework the RunTenure() relayer thread case so that the node unconditionally tries to mine a block if it notices that there's a new burnchain (i.e. don't wait for a tenure timeout)
|
2021-08-26 23:01:47 -04:00 |
|
Jude Nelson
|
19e1c0645e
|
feat: add config items for the miner to decide how much time to spend buiding the first block versus subsequent blocks
|
2021-08-26 22:59:59 -04:00 |
|
Jude Nelson
|
4e521bebfd
|
refactor: set timeout for walking the mempool, not deadline
|
2021-08-26 22:53:27 -04:00 |
|
Jude Nelson
|
2d00a82ba2
|
refactor: don't set deadline in mempool settings; use a timeout and calculate the deadline dynamically
|
2021-08-26 22:52:41 -04:00 |
|
Jude Nelson
|
c792bec867
|
feat: have the mempool walk settings take a miner-imposed deadline so that mempool transaction iteration can be interrupted even if there are lots and lots of transactions to consider
|
2021-08-26 16:58:44 -04:00 |
|
Jude Nelson
|
3ceaab486a
|
feat: propagate miner deadline to mempool's iterate_candidates in order to make iteration interruptable
|
2021-08-26 16:57:52 -04:00 |
|
Jude Nelson
|
82aa428ad6
|
feat: add two new integration tests: one to verify that low-fee transactions are ignored by the miner, and one to verify that a maximum miner time of 0ms results in empty blocks (since the node doesn't have time to mine any transactions)
|
2021-08-26 13:25:57 -04:00 |
|
Jude Nelson
|
bd175693fb
|
refactor: use new BlockBuilderSettings struct
|
2021-08-26 13:25:46 -04:00 |
|
Jude Nelson
|
6347b2bc3a
|
refactor: use new BlockBuilderSettings struct
|
2021-08-26 13:25:28 -04:00 |
|
Jude Nelson
|
8b7ae76e8a
|
feat: pass through new [miner] config file settings to the block-building logic
|
2021-08-26 13:24:53 -04:00 |
|
Jude Nelson
|
43070b262e
|
feat: Add a [miner] config file section that allows the node operator to fill in BlockBuilderSettings and MemPoolWalkSettings structs to control how their nodes mine blocks
|
2021-08-26 13:24:16 -04:00 |
|
Jude Nelson
|
7966e534ed
|
refactor: update the API calls to building blocks to use the new BlockBuilderSettings interface
|
2021-08-26 13:23:54 -04:00 |
|
Jude Nelson
|
d3855b9918
|
feat: update try-mine command to take a minimum tx fee and a maximum miner time
|
2021-08-26 13:23:28 -04:00 |
|
Jude Nelson
|
775e5f202b
|
feat: iterate through transactions in the mempool from highest-fee to lowest-fee, and then order by origin and sponsor nonce. Only consider transactions if they have nonces that can be mined. Update existing unit tests with the new API, and expand them to make sure that low-fee transactions are ignored during iteration.
|
2021-08-26 13:22:07 -04:00 |
|
Jude Nelson
|
f01183c2da
|
feat: introduce BlockBuilderSettings struct as a future-proof way to control how blocks get mined. Right now, this includes making the block-builder and microblock-builder *interruptable* so that they only take up to a given amount of milliseconds (+/- one transaction). The struct also provides hints on how to walk the mempool, so as to consider only transactions with a sufficiently-high fee. This patch also adds a unit test to verify that (trivially) the block-builder will only build a block with a Coinbase transaction if its maximum miner time is 0ms. In addition, this patch refactors the call to MemPoolDB::iterate_candidates() to take the Clarity connection, so ::iterate_candidates() can filter out transactions that cannot be mined.
|
2021-08-26 13:19:18 -04:00 |
|
Jude Nelson
|
3786d6f9e3
|
refactor: use BlockBuilderSettings
|
2021-08-26 13:18:57 -04:00 |
|
Jude Nelson
|
dbf18d2abe
|
refactor: use BlockBuilderSettings
|
2021-08-26 13:18:29 -04:00 |
|