MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / call

Method call

crates/openshell-core/src/grpc_client.rs:111–122  ·  view source on GitHub ↗
(
        &mut self,
        mut req: tonic::Request<()>,
    )

Source from the content-addressed store, hash-verified

109
110impl tonic::service::Interceptor for AuthInterceptor {
111 fn call(
112 &mut self,
113 mut req: tonic::Request<()>,
114 ) -> std::result::Result<tonic::Request<()>, Status> {
115 let bearer = self
116 .bearer
117 .read()
118 .expect("auth interceptor token slot poisoned")
119 .clone();
120 req.metadata_mut().insert("authorization", bearer);
121 Ok(req)
122 }
123}
124
125/// Build the plain (un-intercepted) gRPC channel.

Callers

nothing calls this directly

Calls 1

readMethod · 0.45

Tested by

no test coverage detected