pub struct NotificationProducer { /* private fields */ }Expand description
已冻结 provider 目录的队列生产能力。
Implementations§
Source§impl NotificationProducer
impl NotificationProducer
Sourcepub fn route(&self, provider_ref: &str) -> Option<AlertRoute>
pub fn route(&self, provider_ref: &str) -> Option<AlertRoute>
业务作用:在启动期把名称解析为可在热路径直接使用的队列路由。
参数说明:
provider_ref:必须来自经过校验的冻结配置。
返回:对应路由;未知 provider 返回 None。
Sourcepub fn default_route(&self) -> Option<AlertRoute>
pub fn default_route(&self) -> Option<AlertRoute>
业务作用:取得使用进程通知实现的非阻塞路由,未初始化时通知不进入队列。
参数说明:无。
返回:目录包含默认路由时返回生产能力;其它目录返回 None,不增建 provider 或指标维度。
Sourcepub fn metrics(&self) -> Arc<QueueMetrics> ⓘ
pub fn metrics(&self) -> Arc<QueueMetrics> ⓘ
业务作用:交出只持有原子单元的统一指标源。
参数说明:无。
返回:与生产端、worker 同源的指标句柄。
Trait Implementations§
Auto Trait Implementations§
impl Forget for NotificationProducer
impl Freeze for NotificationProducer
impl Move for NotificationProducer
impl RefUnwindSafe for NotificationProducer
impl Send for NotificationProducer
impl Sync for NotificationProducer
impl Unpin for NotificationProducer
impl UnsafeUnpin for NotificationProducer
impl UnwindSafe for NotificationProducer
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