pub struct GrpcAdapter { /* private fields */ }Expand description
Adapts Service to the generated gRPC trait, enforcing namespace-scoped
auth (ADR 0015) per call from the request’s bearer metadata.
Implementations§
Trait Implementations§
Source§impl Gonzalo for GrpcAdapter
impl Gonzalo for GrpcAdapter
fn get<'life0, 'async_trait>(
&'life0 self,
req: Request<GetRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GetResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn put<'life0, 'async_trait>(
&'life0 self,
req: Request<PutRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<PutResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete<'life0, 'async_trait>(
&'life0 self,
req: Request<DeleteRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<DeleteResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
req: Request<ListRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<ListResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn get_raw<'life0, 'async_trait>(
&'life0 self,
req: Request<GetRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GetResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_raw<'life0, 'async_trait>(
&'life0 self,
req: Request<GetRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GetResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Replication surface (gonzalo#203). Raw reads include tombstones; PutRaw
stores a record verbatim (revision never re-stamped; the author is kept
only for an admin principal (including open mode’s implicit admin), per
ADR 0015); Purge is the only physical removal and requires an admin.
GetRaw/ListRaw/PutRaw reuse the Get/List/Put messages: the shapes are
identical, only the store call differs.
fn list_raw<'life0, 'async_trait>(
&'life0 self,
req: Request<ListRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<ListResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn put_raw<'life0, 'async_trait>(
&'life0 self,
req: Request<PutRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<PutResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn purge<'life0, 'async_trait>(
&'life0 self,
req: Request<PurgeRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<PurgeResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn ticket_sync<'life0, 'async_trait>(
&'life0 self,
req: Request<TicketSyncRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<TicketSyncResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn graph_definitions<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphLocatedResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn graph_definitions<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphLocatedResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Code graph queries (EPIC C). Each selects a view by (repo, view_id).
fn graph_references_to<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphLocatedResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn graph_callers_of<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphNamesResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn graph_callees<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphNamesResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn graph_impact<'life0, 'async_trait>(
&'life0 self,
req: Request<GraphQueryRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GraphNamesResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn put_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<PutBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<PutBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn put_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<PutBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<PutBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Content-addressed blobs (gonzalo#184). Bodies ride as raw bytes, not JSON.
fn get_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<GetBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<GetBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn has_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<HasBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<HasBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn has_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<HasBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<HasBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Presence only, so a writer confirming its referenced blobs survived a
commit does not download them (ADR 0028, gonzalo#329).
fn list_blobs<'life0, 'async_trait>(
&'life0 self,
req: Request<ListBlobsRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<ListBlobsResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_blob<'life0, 'async_trait>(
&'life0 self,
req: Request<DeleteBlobRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<DeleteBlobResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl !RefUnwindSafe for GrpcAdapter
impl !UnwindSafe for GrpcAdapter
impl Freeze for GrpcAdapter
impl Send for GrpcAdapter
impl Sync for GrpcAdapter
impl Unpin for GrpcAdapter
impl UnsafeUnpin for GrpcAdapter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request