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

ADR: Domain Decomposition #162

Merged
merged 9 commits into from
Nov 2, 2020
Merged

ADR: Domain Decomposition #162

merged 9 commits into from
Nov 2, 2020

Conversation

brapse
Copy link
Contributor

@brapse brapse commented Jul 21, 2020

Domain Decomposition

[to address #326]

The objective here is to outline the dependency graph for the relayer that will facilitate

  • Reasonable error handling and failure cases
  • Testability
  • Correct by construction data types
    • Only produce verified data so downstream data consumers don't have to deal with proof

Still a work in progress, probably needs to be scoped down. But the ideas are ready for critique ☺️

rendered


For contributor use:

  • Unit tests written
  • Added test to CI if applicable
  • Updated CHANGELOG_PENDING.md
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Updated relevant documentation (docs/) and code comments
  • Re-reviewed Files changed in the Github PR explorer

### Connection

```rust
trait Connection {
Copy link
Member

Choose a reason for hiding this comment

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

Should these really be traits? IBC objects like Connection, Channel, Packet are all concrete types that don't vary across chains. Clients are more of an interface and do vary depending on the chain, so we end up with concrete types like the Tendermint Client, Grandpa Client, Local Client, etc.

Copy link
Member

Choose a reason for hiding this comment

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

Agreed, if those don't vary across chain then they should definitely be plain structs, and we leave it to the traits to abstract over operations, etc. rather than data.

@codecov-io
Copy link

codecov-io commented Oct 16, 2020

Codecov Report

Merging #162 into master will increase coverage by 21.4%.
The diff coverage is 63.2%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    #162      +/-   ##
=========================================
+ Coverage    13.6%   35.1%   +21.4%     
=========================================
  Files          69     137      +68     
  Lines        3752    8576    +4824     
  Branches     1374    2961    +1587     
=========================================
+ Hits          513    3012    +2499     
- Misses       2618    5374    +2756     
+ Partials      621     190     -431     
Impacted Files Coverage Δ
modules/src/events.rs 0.0% <0.0%> (ø)
modules/src/ics02_client/events.rs 0.0% <ø> (ø)
modules/src/ics02_client/raw.rs 0.0% <0.0%> (ø)
modules/src/ics03_connection/error.rs 13.6% <0.0%> (-19.7%) ⬇️
modules/src/ics04_channel/error.rs 75.0% <ø> (+50.0%) ⬆️
modules/src/ics04_channel/packet.rs 0.0% <0.0%> (ø)
modules/src/ics07_tendermint/client_def.rs 0.0% <0.0%> (ø)
modules/src/ics07_tendermint/error.rs 75.0% <ø> (+75.0%) ⬆️
modules/src/ics18_relayer/error.rs 0.0% <0.0%> (ø)
modules/src/ics26_routing/msgs.rs 0.0% <0.0%> (ø)
... and 254 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5cb7b3f...96b7d95. Read the comment docs.

@brapse brapse marked this pull request as ready for review October 16, 2020 09:26
@brapse brapse changed the title wip: sketch of domain decomposition ADR: Domain Decomposition Oct 16, 2020
@brapse
Copy link
Contributor Author

brapse commented Nov 2, 2020

This is implemented, can we go ahead and merge this @ancazamfir?

Copy link
Collaborator

@ancazamfir ancazamfir left a comment

Choose a reason for hiding this comment

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

Looks good at this point. I think we should update this along with the implementation.

@brapse brapse merged commit c677056 into master Nov 2, 2020
@brapse brapse deleted the brapse/adr-domain-decomposition branch November 2, 2020 13:52
hu55a1n1 pushed a commit to hu55a1n1/hermes that referenced this pull request Sep 13, 2022
* Initial sketch of domain decomposition

* Add dependencies outline

* Add potential components names next to operations

* update based on relayer spec

* Align with relayer-spike

* update the status

* fix typos and add the second foreign client

* Reviewed ADR 004

Co-authored-by: Romain Ruetschi <romain@informal.systems>
Co-authored-by: Anca Zamfir <zamfiranca@gmail.com>
Co-authored-by: Adi Seredinschi <adi@informal.systems>
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.

6 participants