Struct kinesis_firehose_producer::async_producer_pool::AsyncProducerPool [−][src]
pub struct AsyncProducerPool { /* fields omitted */ }
Expand description
The Producer Pool.
Create one with AsyncProducerPool::of_size
Panics
This can panic at pretty much any point if a member Producer throws an error. Currently there is an error channel which waits for errors and panics, but we could do something else here? If we get in that state, though, it’s likely the situation won’t benefit from additional retries. So what else would we do?
Implementations
Create a pool of size size
pub async fn of_size_with_client(
stream_name: String,
size: usize,
client: KinesisFirehoseClient
) -> Result<Self, Error>
pub async fn of_size_with_client(
stream_name: String,
size: usize,
client: KinesisFirehoseClient
) -> Result<Self, Error>
Create a pool of size size
with a given client
The client will be cloned for each pool member
Panics
If size < 1
Produce a message; send a string to a producer. Panics if the pool has been shutdown
Queue a flush for each of the members. Doesn’t wait for them to finish