Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion apps/quorum/Cargo.lock

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

2 changes: 1 addition & 1 deletion apps/quorum/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "quorum"
version = "0.2.1"
version = "0.2.2"
edition = "2021"

[dependencies]
Expand Down
6 changes: 6 additions & 0 deletions apps/quorum/src/api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use axum::{
Json, Router,
};
use axum_prometheus::{EndpointLabel, PrometheusMetricLayerBuilder};
use clap::crate_version;
use secp256k1::{
ecdsa::{RecoverableSignature, RecoveryId},
Message, Secp256k1,
Expand All @@ -27,6 +28,10 @@ use crate::{

pub type Payload<'a> = &'a RawMessage;

async fn root() -> String {
format!("Quorum API {}", crate_version!())
}

pub async fn run(listen_address: SocketAddr, state: State) -> anyhow::Result<()> {
tracing::info!("Starting server...");

Expand All @@ -38,6 +43,7 @@ pub async fn run(listen_address: SocketAddr, state: State) -> anyhow::Result<()>
.build_pair();

let routes = Router::new()
.route("/", get(root))
.route("/live", get(|| async { "OK" }))
.route("/observation", post(post_observation))
.route("/ws", get(ws_route_handler))
Expand Down
Loading