Skip to content

Commit

Permalink
fix documentation for server module
Browse files Browse the repository at this point in the history
  • Loading branch information
intarga committed Oct 12, 2023
1 parent b18a0be commit c20766d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@
//! Ok(())
//! }
//! ```
//#![warn(missing_docs)]
#![warn(missing_docs)]

mod dag;
#[warn(missing_docs)]
pub mod data_switch;
mod harness;
mod scheduler;
Expand All @@ -100,11 +100,6 @@ pub use dag::Dag;

pub use scheduler::Scheduler;

/// Starts up a gRPC server to process QC run requests
///
/// Takes a [socket address](std::net::SocketAddr) to listen on, a
/// [data switch](data_switch::DataSwitch) to provide access to data sources,
/// and a [dag](dag::Dag) to encode dependencies between tests
pub use server::start_server;

#[doc(hidden)]
Expand Down
8 changes: 8 additions & 0 deletions src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,9 @@ async fn start_server_inner(
Ok(())
}

/// Equivalent to `start_server`, but using a unix listener instead of listening
/// on a socket, to enable more deterministic integration testing.
#[doc(hidden)]
pub async fn start_server_unix_listener(
stream: UnixListenerStream,
data_switch: DataSwitch<'static>,
Expand All @@ -184,6 +187,11 @@ pub async fn start_server_unix_listener(
start_server_inner(ListenerType::UnixListener(stream), data_switch, dag).await
}

/// Starts up a gRPC server to process QC run requests
///
/// Takes a [socket address](std::net::SocketAddr) to listen on, a
/// [data switch](DataSwitch) to provide access to data sources,
/// and a [dag](Dag) to encode dependencies between tests
pub async fn start_server(
addr: SocketAddr,
data_switch: DataSwitch<'static>,
Expand Down

0 comments on commit c20766d

Please sign in to comment.