(endpoint: &str, frame: &RequestFrame)
| 1414 | |
| 1415 | #[cfg(unix)] |
| 1416 | async fn exchange(endpoint: &str, frame: &RequestFrame) -> anyhow::Result<ResponseFrame> { |
| 1417 | let mut stream = tokio::net::UnixStream::connect(endpoint) |
| 1418 | .await |
| 1419 | .with_context(|| format!("database owner is not reachable at {endpoint}"))?; |
| 1420 | write_frame(&mut stream, frame).await?; |
| 1421 | read_frame(&mut stream).await |
| 1422 | } |
| 1423 | |
| 1424 | #[cfg(windows)] |
| 1425 | async fn exchange(endpoint: &str, frame: &RequestFrame) -> anyhow::Result<ResponseFrame> { |
no test coverage detected