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

feat(batch): batch message request #2121

Merged
merged 17 commits into from
Apr 9, 2024
Merged

feat(batch): batch message request #2121

merged 17 commits into from
Apr 9, 2024

Conversation

haiyizxx
Copy link
Contributor

@haiyizxx haiyizxx commented Mar 6, 2024

Description

Introduce a new message typeBatchRequest that suppresses execution errors messages, preventing them from causing the entire batch to fail.

Todos

  • Unit tests
  • Manual tests
  • Documentation
  • Connect epics/issues
  • Tag type of change
  • Upgrade handler

Steps to Test

Expected Behaviour

Other Notes

@haiyizxx haiyizxx added the enhancement New feature or request label Mar 6, 2024
@xyuanatbgraph
Copy link
Contributor

xyuanatbgraph commented Mar 6, 2024

Is it possible to put feature to chain txs? Specify event and field from one output and use this for specify input field in next tx?

Example, call x/axelarnet LinkRequest and x/bank Send in one batch, use first output for second input?

If it help I can contribute some design

edit: It seems maybe mutate sdk.Msg is too difficult for here

@haiyizxx haiyizxx force-pushed the batcher branch 3 times, most recently from 5f09dee to 2e61459 Compare March 7, 2024 02:44
Copy link

codecov bot commented Mar 7, 2024

Codecov Report

Attention: Patch coverage is 78.09524% with 23 lines in your changes are missing coverage. Please review.

Project coverage is 48.28%. Comparing base (1199688) to head (bbf3cbc).

Files Patch % Lines
x/auxiliary/types/msg_batch.go 60.97% 13 Missing and 3 partials ⚠️
x/ante/batch.go 81.81% 2 Missing and 2 partials ⚠️
x/auxiliary/types/codec.go 0.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2121      +/-   ##
==========================================
+ Coverage   48.06%   48.28%   +0.22%     
==========================================
  Files         263      267       +4     
  Lines       15928    16033     +105     
==========================================
+ Hits         7656     7742      +86     
- Misses       7683     7696      +13     
- Partials      589      595       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@haiyizxx haiyizxx marked this pull request as ready for review March 7, 2024 02:52
@haiyizxx haiyizxx requested a review from a team as a code owner March 7, 2024 02:52
@cgorenflo
Copy link
Contributor

Is it possible to put feature to chain txs? Specify event and field from one output and use this for specify input field in next tx?

Example, call x/axelarnet LinkRequest and x/bank Send in one batch, use first output for second input?

If it help I can contribute some design

edit: It seems maybe mutate sdk.Msg is too difficult for here

You will be able to do that with a cosmwasm contract once we've fully rolled out the feature

app/app.go Outdated Show resolved Hide resolved
proto/axelar/batcher/v1beta1/tx.proto Outdated Show resolved Hide resolved
proto/axelar/batcher/v1beta1/tx.proto Outdated Show resolved Hide resolved
x/batcher/keeper/msg_server.go Outdated Show resolved Hide resolved
x/batcher/keeper/msg_server.go Outdated Show resolved Hide resolved
app/app.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
proto/axelar/batch/v1beta1/tx.proto Outdated Show resolved Hide resolved
x/batch/keeper/msg_server.go Outdated Show resolved Hide resolved
app/app.go Outdated Show resolved Hide resolved
x/ante/batch.go Outdated Show resolved Hide resolved
x/ante/batch.go Outdated Show resolved Hide resolved
x/ante/batch.go Outdated Show resolved Hide resolved
x/batch/types/key.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
x/batch/types/msg_batch.go Outdated Show resolved Hide resolved
@haiyizxx haiyizxx changed the title feat(batcher): batch message request feat(batch): batch message request Mar 26, 2024
Copy link
Contributor

@cgorenflo cgorenflo left a comment

Choose a reason for hiding this comment

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

I want to have a test case with {some messages, batch, some more messages} to check that all messages are in the correct order and none gets missed. Apart from that we still need to come up with a module name, but the rest looks good

x/auxiliary/types/msg_batch.go Outdated Show resolved Hide resolved
x/auxiliary/types/msg_batch.go Outdated Show resolved Hide resolved
x/auxiliary/keeper/msg_server.go Outdated Show resolved Hide resolved
x/ante/batch.go Outdated Show resolved Hide resolved
x/ante/batch.go Outdated Show resolved Hide resolved
x/ante/batch.go Show resolved Hide resolved
@haiyizxx haiyizxx merged commit 85c6fe3 into main Apr 9, 2024
8 of 9 checks passed
@haiyizxx haiyizxx deleted the batcher branch April 9, 2024 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants