Struct kube::Service [−][src]
Abstracts how Client
communicates with the Kubernetes API server.
The default service uses hyper::Client
and can be created from Config
with Service::try_from
.
Implementations
impl Service
[src]
pub fn new<S>(inner: S) -> Self where
S: Service<Request<Body>, Response = Response<Body>, Error = BoxError> + Send + 'static,
S::Future: Send + 'static,
[src]
S: Service<Request<Body>, Response = Response<Body>, Error = BoxError> + Send + 'static,
S::Future: Send + 'static,
Create a custom Service
.
Trait Implementations
impl Clone for Service
[src]
impl Service<Request<Body>> for Service
[src]
type Error = <Buffer<BoxService<Request<Body>, Response<Body>, BoxError>, Request<Body>> as Service<Request<Body>>>::Error
Errors produced by the service.
type Future = <Buffer<BoxService<Request<Body>, Response<Body>, BoxError>, Request<Body>> as Service<Request<Body>>>::Future
The future response value.
type Response = <Buffer<BoxService<Request<Body>, Response<Body>, BoxError>, Request<Body>> as Service<Request<Body>>>::Response
Responses given by the service.
fn poll_ready(&mut self, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>>
[src]
fn call(&mut self, req: Request<Body>) -> Self::Future
[src]
impl TryFrom<Config> for Service
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Service
impl Send for Service
impl Sync for Service
impl Unpin for Service
impl !UnwindSafe for Service
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, Request> ServiceExt<Request> for T where
T: Service<Request> + ?Sized,
[src]
T: Service<Request> + ?Sized,
pub fn ready(&mut self) -> Ready<'_, Self, Request>
[src]
pub fn ready_and(&mut self) -> Ready<'_, Self, Request>
[src]
pub fn ready_oneshot(self) -> ReadyOneshot<Self, Request>
[src]
pub fn oneshot(self, req: Request) -> Oneshot<Self, Request>
[src]
pub fn call_all<S>(self, reqs: S) -> CallAll<Self, S> where
S: Stream<Item = Request>,
Self::Error: Into<Box<dyn Error + 'static + Sync + Send, Global>>,
[src]
S: Stream<Item = Request>,
Self::Error: Into<Box<dyn Error + 'static + Sync + Send, Global>>,
pub fn and_then<F>(self, f: F) -> AndThen<Self, F> where
F: Clone,
[src]
F: Clone,
pub fn map_response<F, Response>(self, f: F) -> MapResponse<Self, F> where
F: FnOnce(Self::Response) -> Response + Clone,
[src]
F: FnOnce(Self::Response) -> Response + Clone,
pub fn map_err<F, Error>(self, f: F) -> MapErr<Self, F> where
F: FnOnce(Self::Error) -> Error + Clone,
[src]
F: FnOnce(Self::Error) -> Error + Clone,
pub fn map_result<F, Response, Error>(self, f: F) -> MapResult<Self, F> where
Error: From<Self::Error>,
F: FnOnce(Result<Self::Response, Self::Error>) -> Result<Response, Error> + Clone,
[src]
Error: From<Self::Error>,
F: FnOnce(Result<Self::Response, Self::Error>) -> Result<Response, Error> + Clone,
pub fn map_request<F, NewRequest>(self, f: F) -> MapRequest<Self, F> where
F: FnMut(NewRequest) -> Request + Clone,
[src]
F: FnMut(NewRequest) -> Request + Clone,
pub fn then<F, Response, Error, Fut>(self, f: F) -> Then<Self, F> where
Error: From<Self::Error>,
F: FnOnce(Result<Self::Response, Self::Error>) -> Fut + Clone,
Fut: Future<Output = Result<Response, Error>>,
[src]
Error: From<Self::Error>,
F: FnOnce(Result<Self::Response, Self::Error>) -> Fut + Clone,
Fut: Future<Output = Result<Response, Error>>,
pub fn map_future<F, Fut, Response, Error>(self, f: F) -> MapFuture<Self, F> where
Error: From<Self::Error>,
F: FnMut(Self::Future) -> Fut,
Fut: Future<Output = Result<Response, Error>>,
[src]
Error: From<Self::Error>,
F: FnMut(Self::Future) -> Fut,
Fut: Future<Output = Result<Response, Error>>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,