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
1 change: 0 additions & 1 deletion quest/m2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,6 @@ lite-07; bitrate enforcement is not part of this release.

- [Publisher timeliness at relay ingest](/quest/m2/qos-publisher-timeliness.md) - follow-on capability after the release contract is stable

- [Auth serve bound address](/quest/m2/auth-serve-bound-addr.md) - `moq auth serve` logs the port it actually bound
- [H.264 parsing with maintained crates](/quest/m2/h264-reader.md) - moq-mux parses SPS VUI with h264-reader and shares one bit reader across codec config parsers
- [Relay metrics through prometheus-client](/quest/m2/relay-prometheus-client.md) - `/metrics` renders through the maintained client with the same series
- [moq-transport finish interop](/quest/m2/ietf-finish.md) - the interop `finish` case runs on every even moq-transport draft instead of being skipped
Expand Down
13 changes: 0 additions & 13 deletions quest/m2/auth-serve-bound-addr.md

This file was deleted.

3 changes: 3 additions & 0 deletions rs/moq-cli/src/auth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -577,6 +577,7 @@ impl Serve {
let listener = tokio::net::TcpListener::bind(addr)
.await
.with_context(|| format!("failed to bind {addr}"))?;
let addr = listener.local_addr().context("failed to read the bound address")?;
tracing::info!(%addr, url = ?self.mesh_url, "mesh coordinator listening");
mesh = Some((coordinator.clone(), listener));
server = server.with_mesh(coordinator);
Expand All @@ -593,6 +594,8 @@ impl Serve {
let listener = tokio::net::TcpListener::bind(addr)
.await
.with_context(|| format!("failed to bind {addr}"))?;
// Log the bound address, so `--listen 127.0.0.1:0` reports the port the OS picked.
let addr = listener.local_addr().context("failed to read the bound address")?;
tracing::info!(%addr, "auth server listening");
server.serve(listener).await?;
}
Expand Down
8 changes: 8 additions & 0 deletions rs/moq-cli/tests/integration/auth_serve.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@ async fn stops_on(signal: libc::c_int) {
kio::clock::timeout(TIMEOUT, async {
while let Some(line) = lines.next_line().await.expect("read stderr") {
if line.contains("auth server listening") {
// The line names the port the OS assigned, not the requested port 0.
let port = line
.split("127.0.0.1:")
.nth(1)
.and_then(|rest| rest.split(|c: char| !c.is_ascii_digit()).next())
.and_then(|port| port.parse::<u16>().ok())
.unwrap_or_else(|| panic!("no bound address in {line:?}"));
assert_ne!(port, 0, "logged the requested port instead of the bound one: {line:?}");
return;
}
}
Expand Down