-
Notifications
You must be signed in to change notification settings - Fork 389
feat(aggregation-mode): integrate proof aggregator with db #2186
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
Open
MarcosNicolau
wants to merge
12
commits into
staging
Choose a base branch
from
feat/integrate-agg-mode-with-db
base: staging
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
29747b5
feat: initial structs for db integration
MarcosNicolau 0419233
feat: db types and tasks selection
MarcosNicolau 3309e31
feat: basic fetcher flow
MarcosNicolau d7d8362
feat: selecting proofs and aggregating working
MarcosNicolau 0df9e0e
chore: remove dead code from fast mode
MarcosNicolau 6ce9f1e
feat: store merkle paths and mark as verified after submitting proof
MarcosNicolau 220a73e
chore: reactivate docker in build
MarcosNicolau c90d9f4
chore: address clippy warnings
MarcosNicolau 7a1e04c
refactor: juli's comments
MarcosNicolau 91279ce
Merge remote-tracking branch 'origin/staging' into feat/integrate-agg…
MarcosNicolau ea5d13e
fix: compilation errors
MarcosNicolau d4c454a
fix: ethereum package error when sending agg proof verification tx
MarcosNicolau File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| [package] | ||
| name = "agg_mode_db" | ||
| name = "db" | ||
| version = "0.1.0" | ||
| edition = "2021" | ||
|
|
||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| pub mod types; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| use sqlx::{ | ||
| prelude::FromRow, | ||
| types::{BigDecimal, Uuid}, | ||
| Type, | ||
| }; | ||
|
|
||
| #[derive(Debug, Clone, Copy, PartialEq, Eq, Type)] | ||
| #[sqlx(type_name = "task_status", rename_all = "lowercase")] | ||
| pub enum TaskStatus { | ||
| Pending, | ||
| Processing, | ||
| Verified, | ||
| } | ||
|
|
||
| #[derive(Debug, Clone, FromRow)] | ||
| pub struct Task { | ||
| pub task_id: Uuid, | ||
| pub address: String, | ||
| pub proving_system_id: i32, | ||
| pub proof: Vec<u8>, | ||
| pub program_commitment: Vec<u8>, | ||
| pub merkle_path: Option<Vec<u8>>, | ||
| pub status: TaskStatus, | ||
| } | ||
|
|
||
| #[derive(Debug, Clone, FromRow)] | ||
| pub struct Payment { | ||
| pub payment_event_id: Uuid, | ||
| pub address: String, | ||
| pub amount: i32, | ||
| pub started_at: BigDecimal, | ||
| pub valid_until: BigDecimal, | ||
| pub tx_hash: String, | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
aggregation_mode/proof_aggregator/abi/AlignedLayerServiceManager.json
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This type should match the one used to query the DB on
get_pending_tasks_and_mark_them_as_processed(i64). I understand that in the Database the value is an integer, but we should keep a common type to represent it.