diff --git a/beacon_node/rest_api/Cargo.toml b/beacon_node/rest_api/Cargo.toml index 82bf535b75..77c032051b 100644 --- a/beacon_node/rest_api/Cargo.toml +++ b/beacon_node/rest_api/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "rest_api" version = "0.1.0" -authors = ["Luke Anderson "] +authors = ["Paul Hauner ", "Luke Anderson "] edition = "2018" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/beacon_node/rest_api/src/config.rs b/beacon_node/rest_api/src/config.rs index 68f23d1c7a..d52d3eaed9 100644 --- a/beacon_node/rest_api/src/config.rs +++ b/beacon_node/rest_api/src/config.rs @@ -3,9 +3,6 @@ use serde::{Deserialize, Serialize}; use std::net::Ipv4Addr; /// Defines the encoding for the API -/// -/// The validator client can speak to the beacon node in a number of encodings. Currently both JSON -/// and YAML are supported. #[derive(Clone, Serialize, Deserialize, Copy)] pub enum ApiEncodingFormat { JSON, diff --git a/beacon_node/rest_api/src/lib.rs b/beacon_node/rest_api/src/lib.rs index bea1ccbb9f..8970453a5b 100644 --- a/beacon_node/rest_api/src/lib.rs +++ b/beacon_node/rest_api/src/lib.rs @@ -59,9 +59,10 @@ pub fn start_server( eth2_config: Eth2Config, log: slog::Logger, ) -> Result<(exit_future::Signal, SocketAddr), hyper::Error> { - // Define the function that will build the request handler. let inner_log = log.clone(); let eth2_config = Arc::new(eth2_config); + + // Define the function that will build the request handler. let make_service = make_service_fn(move |_socket: &AddrStream| { let beacon_chain = beacon_chain.clone(); let log = inner_log.clone(); diff --git a/beacon_node/rest_api/src/metrics.rs b/beacon_node/rest_api/src/metrics.rs index 77447a479d..fbf36f116c 100644 --- a/beacon_node/rest_api/src/metrics.rs +++ b/beacon_node/rest_api/src/metrics.rs @@ -57,7 +57,7 @@ pub fn get_prometheus( beacon_chain::scrape_for_metrics(&beacon_chain); encoder - .encode(&lighthouse_metrics::gather()[..], &mut buffer) + .encode(&lighthouse_metrics::gather(), &mut buffer) .unwrap(); String::from_utf8(buffer)