pub struct App { /* private fields */ }Expand description
Client for the gestalt.provider.v1.App service.
Implementations§
Source§impl App
impl App
Sourcepub fn with_timeout(self, timeout: Duration) -> Self
pub fn with_timeout(self, timeout: Duration) -> Self
Sets a deadline applied to every unary call; calls that run past it fail with DEADLINE_EXCEEDED. Streaming calls are unaffected.
Sourcepub fn with_context(self, context: RequestContext) -> Self
pub fn with_context(self, context: RequestContext) -> Self
Sets the default request context, injected into outgoing requests that do not carry one.
Sourcepub async fn connect() -> Result<Self, GestaltError>
pub async fn connect() -> Result<Self, GestaltError>
Connects to the app host service described by the environment.
Sourcepub async fn connect_named(name: &str) -> Result<Self, GestaltError>
pub async fn connect_named(name: &str) -> Result<Self, GestaltError>
Connects to the named app host-service binding.
Sourcepub async fn invoke(
&mut self,
app: String,
operation: String,
params: Option<Map<String, Value>>,
options: AppInvokeOptions,
) -> Result<Value, InvokeError>
pub async fn invoke( &mut self, app: String, operation: String, params: Option<Map<String, Value>>, options: AppInvokeOptions, ) -> Result<Value, InvokeError>
Calls gestalt.provider.v1.App.Invoke.
The result decodes with the standard JSON operation envelope
semantics; payload failures surface as InvokeError.
Sourcepub async fn invoke_raw(
&mut self,
request: AppInvokeRequest,
) -> Result<OperationResult, GestaltError>
pub async fn invoke_raw( &mut self, request: AppInvokeRequest, ) -> Result<OperationResult, GestaltError>
Calls gestalt.provider.v1.App.Invoke with the full request and response messages.
Sourcepub async fn invoke_stream(
&mut self,
request: AppInvokeRequest,
) -> Result<AppInvokeStreamStream, GestaltError>
pub async fn invoke_stream( &mut self, request: AppInvokeRequest, ) -> Result<AppInvokeStreamStream, GestaltError>
InvokeStream is the streaming counterpart of Invoke. It is gRPC-only (no REST binding) and shares Invoke’s request shape, authorization, and signature policy. The first response frame is always InvokeMetadata; subsequent frames carry data bytes from the operation’s stream response. A mid-stream error may emit a trailing metadata frame with an error status followed by a JSON error body, after which the stream ends.
Calls gestalt.provider.v1.App.InvokeStream, returning a stream of converted frames.
Sourcepub async fn invoke_graphql(
&mut self,
app: String,
document: String,
options: AppInvokeGraphQLOptions,
) -> Result<OperationResult, GestaltError>
pub async fn invoke_graphql( &mut self, app: String, document: String, options: AppInvokeGraphQLOptions, ) -> Result<OperationResult, GestaltError>
Calls gestalt.provider.v1.App.InvokeGraphQL.
Sourcepub async fn invoke_graphql_raw(
&mut self,
request: AppInvokeGraphQLRequest,
) -> Result<OperationResult, GestaltError>
pub async fn invoke_graphql_raw( &mut self, request: AppInvokeGraphQLRequest, ) -> Result<OperationResult, GestaltError>
Calls gestalt.provider.v1.App.InvokeGraphQL with the full request and response messages.
Auto Trait Implementations§
impl !Freeze for App
impl !RefUnwindSafe for App
impl !UnwindSafe for App
impl Send for App
impl Sync for App
impl Unpin for App
impl UnsafeUnpin for App
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
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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>
T in a tonic::Request