pub struct IngestBridge { /* private fields */ }Expand description
The bridge.
Implementations§
Source§impl IngestBridge
impl IngestBridge
Sourcepub fn new(
registry: Arc<TokenRegistry>,
router: Arc<dyn StoreRouter>,
budget: RateBudget,
cfg: BridgeConfig,
) -> Arc<Self> ⓘ
pub fn new( registry: Arc<TokenRegistry>, router: Arc<dyn StoreRouter>, budget: RateBudget, cfg: BridgeConfig, ) -> Arc<Self> ⓘ
Bridge over registry and router.
Sourcepub fn has_route(&self, b: &InstanceBinding) -> bool
pub fn has_route(&self, b: &InstanceBinding) -> bool
True if a store owner is known for b.
Sourcepub fn stats(&self) -> &BridgeStats
pub fn stats(&self) -> &BridgeStats
Counters.
Sourcepub async fn bind(
self: &Arc<Self>,
addr: SocketAddr,
scope: BridgeScope,
) -> Result<BridgeHandle, IngestError>
pub async fn bind( self: &Arc<Self>, addr: SocketAddr, scope: BridgeScope, ) -> Result<BridgeHandle, IngestError>
Bind addr and serve scope. A non-loopback address is refused
unless the config allows it and the scope is one instance.
Auto Trait Implementations§
impl !Freeze for IngestBridge
impl !RefUnwindSafe for IngestBridge
impl !UnwindSafe for IngestBridge
impl Send for IngestBridge
impl Sync for IngestBridge
impl Unpin for IngestBridge
impl UnsafeUnpin for IngestBridge
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
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more