pub struct InfraQueueClient { /* private fields */ }Implementations§
Source§impl InfraQueueClient
impl InfraQueueClient
pub fn new(base_url: String, api_key: Option<String>) -> Result<Self>
pub fn from_env() -> Result<Self>
pub async fn enqueue(&self, msg: InfraQueueMessage) -> Result<()>
pub async fn dequeue(&self, topic: &str) -> Result<Option<InfraQueueMessage>>
pub async fn dequeue_with_visibility( &self, topic: &str, visibility_ms: Option<u64>, ) -> Result<Option<DequeueResponse>>
pub async fn ack(&self, topic: &str, receipt: &str) -> Result<()>
pub async fn nack( &self, topic: &str, receipt: &str, policy: &RetryPolicy, ) -> Result<NackOutcome>
pub async fn heartbeat( &self, topic: &str, consumer_id: &str, ttl_seconds: u64, ) -> Result<()>
Auto Trait Implementations§
impl Freeze for InfraQueueClient
impl !RefUnwindSafe for InfraQueueClient
impl Send for InfraQueueClient
impl Sync for InfraQueueClient
impl Unpin for InfraQueueClient
impl UnsafeUnpin for InfraQueueClient
impl !UnwindSafe for InfraQueueClient
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