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: switching to axum, adding swagger UI #84

Merged
merged 2 commits into from
Jul 20, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
240 changes: 238 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ key_transparency = []
ci = []

[dependencies]
axum = "0.6"
tower-http = { version = "0.4", features = ["cors"] }
utoipa = { version = "3.3", features = ["axum_extras"] }
utoipa-swagger-ui = { version = "3.1", features = ["axum"] }
crypto-hash = "0.3.4"
async-trait = "0.1.68"
serde = { version = "1.0.151", features = ["derive"] }
Expand Down
5 changes: 3 additions & 2 deletions src/node_types/sequencer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,9 @@ impl NodeType for Sequencer {

let main_loop = self.clone().main_loop();
let da_loop = self.clone().da_loop();
let ws = self.clone().ws.start(self.clone());

let ws_self = self.clone();
let ws = ws_self.ws.start(self.clone());

tokio::select! {
_ = main_loop => Ok(()),
Expand Down Expand Up @@ -201,7 +203,6 @@ impl Sequencer {
};

self.db.set_epoch(&epoch)?;
self.db.reset_epoch_operation_counter()?;

// add the commitment for the operations ran since the last epoch
let current_commitment = self
Expand Down
Loading
Loading