-
Notifications
You must be signed in to change notification settings - Fork 326
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
Relayer v2 architecture redesign and new packet worker MVP #2478
Conversation
✅ Deploy Preview for ibc-rs ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
relayer-framework-guide/docs/context-generic-programming/13-concrete-composition.md
Outdated
Show resolved
Hide resolved
relayer-framework-guide/docs/context-generic-programming/05-explicit-binding.md
Outdated
Show resolved
Hide resolved
relayer-framework-guide/docs/context-generic-programming/16-querier-consumer.md
Outdated
Show resolved
Hide resolved
relayer-framework-guide/docs/context-generic-programming/16-querier-consumer.md
Outdated
Show resolved
Hide resolved
relayer-framework-guide/docs/context-generic-programming/05-daytime-greeter.md
Outdated
Show resolved
Hide resolved
relayer-framework-guide/docs/context-generic-programming/04-greeter-component.md
Outdated
Show resolved
Hide resolved
Had a discussion with @adizere and @Farhad-Shabani regarding the need to validate Cosmos-Substrate relaying as part of the packet worker refactor. That work is tracked in ComposableFi/composable-ibc#78. This work will likely require us to expose Hermes APIs to be able to call into them from the Hyperspace front. In other words, this will help us with the Hermes librarification effort. |
73f7f68
to
9406de7
Compare
* Refactor OfaChain types into OfaChainTypes * Make Cosmos OfaIbcChain implementation slightly more generic * Introduce CosmosMessage trait * Isolate UpdateClient methods * Isolate connection handshake methods * Isolate channel handshake methods * Isolate CreateClient and ConsensusState methods * Isolate packet methods * Isolate client state and chain methods * Remove Self:: aliases in OFA chain implementation * Move some methods from OfaIbcChain to OfaChain * Add packet payload types * Add HasIbcPacketFields * Support ReceivePacket payload * Support AckPacket payload * Support TimeoutUnordered packet payload * Remove constraint that counterparty message has to be CosmosMessage
* Refactor spawn functions to call ChainHandle methods * Define CosmosUpdateClient message type * Add CosmosCreateClientMessage type * Add CosmosReceivePacketMessage type * Add CosmosAckPacketMessage type * Add CosmosTimeoutPacketMessage type * Add CosmosConnectionOpenInitMessage type * Add CosmosConnectionOpenTryMessage type * Add CosmosConnectionOpenAckMessage type * Fix packet message counterparty heights * Add CosmosConnectionOpenConfirmMessage type * Refactor payload fields in ConnectionOpenConfirm * Refactor ConnectionOpenTry message and payload fields * Refactor ConnectionOpenAck proof fields * Refactor counterparty message height to be for UpdateClient Previously it was for when the proofs were built * Refactor ReceivePacket proof fields * Refactor AckPacket proof fields * Refactor TimeoutPacket proof fields * Simplify ConnectionOpenTry handshake * Simplify ConnectionOpenAck handshake * Simplify ConnectionOpenConfirm handshake * Fix clippy and test * Add CosmosChannelOpenInitMessage type * Add CosmosChannelOpenTryMessage message type * Add CosmosChannelOpenAckMessage type * Add CosmosChannelOpenConfirmMessage type * Rearrange message modules
* Implement CanQueryPacketCommitments for relayer-next * Implement CanQueryUnreceivedPacketSequences for relayer-next * Implement CanQueryUnreceivedPacketEvents for relayer-next * Implement CanQueryUnreceivedPackets for relayer-next * Implement PacketClearerWithTarget for relayer-next * Fix clear_packets_with_target * Partial implementation of ClearPacketWorker for relayer-next * Remove PacketClearConfig * Rename channels to src/dst instead of using counterparty * Improve clear_receive_packets * Add test for packet clearing relayer-next * Fix and improve Clear packet implementation and tests for relayer-next * Add HasClearInterval trait for relayer-next * Remove Target from ClearPacketWorker in relayer-next * Update cargo lock * Fix 'query_unreceived_packet_sequences' and 'query_packet_commitments' for relayer-next * Add documentation to 'query_packet_commitments' * Rename 'CanQueryUnreceivedPackets' to 'CanQuerySendPacketsFromSequences' * Add documentation for 'height' used in 'query_unreceived_packets' * Clean 'packet_clear' test for relayer-next * Split CanQuerySendPacketsFromSequences into two traits * Add 'try_extract_send_packet_event' to relayer-cosmos methods module * Moved traits related to send packets in their own mod * Moved packet_clear traits to relayer-components * Moved send_packet impls to its own mod * Moved 'try_extract_write_acknowledgement_event' to the methods module
* Use component graph pattern for UpdateClientMessageBuilder * Use macros to derive component graph * Auto derive CanQueryChainStatus * Use components pattern for PacketRelayer * Use component graph for auto relayer * Attempt to define macros that derive the derive macros * Revert "Attempt to define macros that derive the derive macros" This reverts commit ca47c72. * Use component graph for consensus state querier * Use component graph for receive packet relayer * Use component graph for ack packet relayer * Use component graph for timeout unordered packet relayer * Use component graph for IbcMessageSender * Use component graph for mock components * Use component graph for packet filter * Use component graph for auto birelay * Rename impl modules to components for component-based impls
* Define ForwardComponent to auto forward component with less macros * Forward IBC message sender components * Auto derive from HasComponent for both provider and consumer traits. * Use new component pattern for chain status and consensus state querier * Use new component pattern for all other components * Remove HasComponents trait * Add forward_components! macro to forward multiple components at once * Reorder macro arguments and rename forward_component to delegate_component * Rename HasComponent to DelegateComponent * Separate out component graphs for each context * Remove generic Mode argument from AutoRelayer * Delegate event relayer component * Rearrange modules * Turn CreateClient into a component * Remove unused traits * Use component delegation for PacketClearer * Do not retry failed tests in CI * Use component delegation for chain builder * Use component delegation for RelayBuilder * Use component delegation for RelayFromChainsBuilder * Use component delegation for RelayWithBatchBuilder * Rearrange modules * Rearrange birelay traits * Use component delegation for BiRelayBuilder * Allow delegate_components! to match without trailing comma * Use component delegation for BiRelayFromRelayBuilder * Fix CI
* Implement runtime traits directly for TokioRuntimeContext * Use AfoRuntime directly * Remove OfaRuntime constructs * Rename Log to LogEntries * Implement telemetry traits directly * Remove OfaTelemetry * Slightly improve telemetry
* Use component delegation for chain MessageSender * Simplify nonce allocator design * Refactor nonce traits * Use component delegation for nonce allocator * Use component delegation for message as tx sender * Use component delegation for TxResponsePoller * Use component delegation for TxResponseQuerier * Use component delegation for TxFeeEstimator * Use component delegation for TxEncoder * Use component delegation for NonceQuerier * Use component delegation for TxSubmitter * Implement tx traits directly in CosmosTxContext * Remove OfaTxContext * Add proof for CosmosTxContext implementing CanSendMessages
* Add HasComponents trait * Remove DelegateComponents implementation in chain and transaction context * Add tx components closure * Use HasComponents for relay context * Construct closure for ExtraChainComponents * Building ExtraRelayComponents closure * More relay component closure * Done constructing packet relayer closure * Add packet relayer closure for ExtraRelayComponents * Use UseExtraChainComponents in UseExtraPacketRelayer * Add relay components closure traits * Add DefaultEventRelayer closure * Add DefaultAckPacketRelayer closure * Add ExtraAckPacketRelayer closure * Add ExtraEventRelayer closure
* Add default auto relayer closure * Add extra auto relayer closure * Make packet fields reader into a component * Use HasComponents to delegate builder context methods * Rename builder module to build * Construct closure for default builder components * Construct closure for extra builder components * Add closure for batch worker spawner * Use batch worker closure in extra builder components closure
This PR has been moved to the |
Description
The
cargo doc
documentation for this PR is available at https://ibc-rs.netlify.app/ibc_relayer_framework/.Rendered ADR
Concurrency Architectures (Excalidraw Diagrams)
PR author checklist:
unclog
.docs/
).Reviewer checklist:
Files changed
in the GitHub PR explorer.