pub struct IngressRouter { /* private fields */ }Expand description
An Application that routes incoming requests using the live Ingress rule table.
Finds the first matching IngressRule and forwards the request to
{service_name}.{namespace}.svc.cluster.local:{service_port} over HTTP/1.1.
Returns 404 Not Found when no rule matches.
Implementations§
Source§impl IngressRouter
impl IngressRouter
Sourcepub fn new(watcher: KubernetesIngressWatcher) -> Self
pub fn new(watcher: KubernetesIngressWatcher) -> Self
Wrap a watcher in an IngressRouter with default timeouts.
Sourcepub fn connect_timeout_ms(self, ms: u64) -> Self
pub fn connect_timeout_ms(self, ms: u64) -> Self
Override the TCP connect timeout (default: 5 000 ms).
Sourcepub fn read_timeout_ms(self, ms: u64) -> Self
pub fn read_timeout_ms(self, ms: u64) -> Self
Override the response read timeout (default: 30 000 ms).
Trait Implementations§
Source§impl Application for IngressRouter
impl Application for IngressRouter
Auto Trait Implementations§
impl Freeze for IngressRouter
impl RefUnwindSafe for IngressRouter
impl Send for IngressRouter
impl Sync for IngressRouter
impl Unpin for IngressRouter
impl UnsafeUnpin for IngressRouter
impl UnwindSafe for IngressRouter
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