Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decouple block producing, submission and confirming #776

Merged
merged 139 commits into from
Sep 22, 2022

Conversation

blckngm
Copy link
Contributor

@blckngm blckngm commented Aug 2, 2022

Don't wait for the confirmation of the previous L2 block before generating or submitting the next block.

New config introduced in this PR:

# Block producing and submission.
[block_producer]
# Max number of local blocks.
local_limit = 3
# Max number of submitted (but not confirmed) blocks.
submitted_limit = 3
# Minimal delay between blocks.
block_interval_secs = 7

# Deposit collection criteria.
[mem_pool.mem_block]
deposit_block_timeout = 150
deposit_timestamp_timeout = 1200000
deposit_epoch_timeout = 1
deposit_minimal_blocks = 0

# P2P network identification and authentication.
[p2p_network_config]
secret_key_path = "path to p2p secret key"
allowed_peer_ids = ["peer1", "peer2"]

blckngm added 30 commits June 7, 2022 19:46
instead of producing block.
Tests still do not pass
Just use FinalizedCustodianCapacity
And update last confirmed/submitted transaction when syncing from L1
@gw-bot
Copy link

gw-bot bot commented Sep 20, 2022

Running integration test

Workflow Run Id: 3087062311

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

A node become not live if it hasn't produced, received, submitted or
confirmed a block in a while.
@gw-bot
Copy link

gw-bot bot commented Sep 21, 2022

Running integration test

Workflow Run Id: 3095672858

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

crates/block-producer/src/block_sync_client.rs Outdated Show resolved Hide resolved
crates/block-producer/src/psc.rs Show resolved Hide resolved
crates/p2p-network/client-key Outdated Show resolved Hide resolved
node_mode = "fullnode"

[p2p_network_config]
listen = "/ip4/0.0.0.0/tcp/9999"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace the example with a p2p multiaddr version?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have added doc about authentication (including key generation, peer id calculation and related configurations).

@gw-bot
Copy link

gw-bot bot commented Sep 21, 2022

Running integration test

Workflow Run Id: 3097432976

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

@gw-bot
Copy link

gw-bot bot commented Sep 21, 2022

Running integration test

Workflow Run Id: 3097610689

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

crates/chain/src/chain.rs Outdated Show resolved Hide resolved
zeroqn
zeroqn previously approved these changes Sep 22, 2022
@gw-bot
Copy link

gw-bot bot commented Sep 22, 2022

Running integration test

Workflow Run Id: 3103162638

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

@gw-bot
Copy link

gw-bot bot commented Sep 22, 2022

Running integration test

Workflow Run Id: 3103419873

Components:

Manually running integration test

Post a comment contains

/itest
[prebuilds: tag]
[godwoken: branch/ref]
[scripts: branch/ref]
[polyjuice: branch/ref]
[web3: branch/ref]
[kicker: branch/ref]
[tests: branch/ref]

Note: [] means optional, for example

/itest
prebuilds: dev-202203280240
godwoken: develop
scripts: 81676d9d53ffdf5bbaa60483928d07da16eb4a88
polyjuice: e37553b9

Run Result

success

@jjyr
Copy link
Collaborator

jjyr commented Sep 22, 2022

@sopium Please resolve conflicts

@blckngm
Copy link
Contributor Author

blckngm commented Sep 22, 2022

@sopium Please resolve conflicts

Github UI and local git merge are not showing any conflicts?

@jjyr jjyr merged commit 1a049b6 into develop Sep 22, 2022
@jjyr jjyr deleted the decouple-block-producing-and-submitting branch September 22, 2022 12:49
@jjyr
Copy link
Collaborator

jjyr commented Sep 22, 2022

@sopium Please resolve conflicts

Github UI and local git merge are not showing any conflicts?

Right, GitHub display conflicts under the option 'rebase and merge', but we can create a new merge. Congratulate @sopium !, finally get it done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants