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

refactor: remove committed_topology from block #4880

Merged
merged 3 commits into from
Jul 24, 2024

Conversation

Erigara
Copy link
Contributor

@Erigara Erigara commented Jul 23, 2024

Description

  • committed topology is removed from block
  • committed topology for latest and previous blocks are stored in the state
    • it's required for blocks sync
    • and for initializing state from the snapshot + block store
  • initial topology in the genesis block is passed as transaction with Register<Peer> instructions
  • trusted peers are removed from World constructor

Linked issue

Closes #4879

Benefits

Less space used in the block store, easier to derive block hash.

How to test

Run, try to submit new blocks, try restart peers check that iroha operates as usual.

@Erigara Erigara added the Refactor Improvement to overall code quality label Jul 23, 2024
@Erigara Erigara self-assigned this Jul 23, 2024
@github-actions github-actions bot added the api-changes Changes in the API for client libraries label Jul 23, 2024
core/src/state.rs Outdated Show resolved Hide resolved
core/src/sumeragi/main_loop.rs Show resolved Hide resolved
@Erigara Erigara force-pushed the no_topology_in_block branch 2 times, most recently from 7ed6b07 to 5558ab0 Compare July 23, 2024 14:20
mversic
mversic previously approved these changes Jul 23, 2024
Copy link
Contributor

@mversic mversic left a comment

Choose a reason for hiding this comment

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

This makes me very happy

@mversic mversic self-assigned this Jul 23, 2024
@mversic mversic enabled auto-merge (squash) July 24, 2024 14:35
nxsaken
nxsaken previously approved these changes Jul 24, 2024
core/src/block.rs Outdated Show resolved Hide resolved
@nxsaken
Copy link
Contributor

nxsaken commented Jul 24, 2024

Compilation fails, and something's wrong with the commit sign-off

Signed-off-by: Shanin Roman <shanin1000@yandex.ru>
Signed-off-by: Shanin Roman <shanin1000@yandex.ru>
@Erigara Erigara dismissed stale reviews from nxsaken and mversic via 04cb719 July 24, 2024 15:17
mversic
mversic previously approved these changes Jul 24, 2024
Signed-off-by: Shanin Roman <shanin1000@yandex.ru>
@mversic mversic merged commit 336fadd into hyperledger-iroha:main Jul 24, 2024
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api-changes Changes in the API for client libraries Refactor Improvement to overall code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

refactor: remove committed_topology field from blocks
3 participants