pub struct BatchConsumerConfig {
pub server_url: String,
pub app_id: String,
pub batch_size: usize,
pub timeout_ms: u64,
pub compress: bool,
pub auto_flush: bool,
pub interval_secs: u64,
pub cache_capacity: usize,
}Expand description
Configuration for BatchConsumer, mirroring the Go SDK’s
TDBatchConfig.
Fields§
§server_url: StringReceiver URL, e.g. https://receiver.thinkingdata.io. The path is
always rewritten to /sync_server.
app_id: StringThinkingData APP ID.
batch_size: usizeEvent count threshold for triggering a flush; 0 selects
DEFAULT_BATCH_SIZE, values above MAX_BATCH_SIZE are clamped.
timeout_ms: u64Request deadline in milliseconds; 0 selects DEFAULT_TIMEOUT_MS.
compress: boolWhether to gzip-compress request bodies (default: enabled).
auto_flush: boolWhether a background task flushes on a fixed interval.
interval_secs: u64Auto flush spacing in seconds; 0 selects DEFAULT_INTERVAL_SECS.
cache_capacity: usizeMaximum number of cached (undelivered) batches; 0 selects
DEFAULT_CACHE_CAPACITY.
Trait Implementations§
Source§impl Clone for BatchConsumerConfig
impl Clone for BatchConsumerConfig
Source§impl Debug for BatchConsumerConfig
impl Debug for BatchConsumerConfig
Auto Trait Implementations§
impl Forget for BatchConsumerConfig
impl Freeze for BatchConsumerConfig
impl Move for BatchConsumerConfig
impl RefUnwindSafe for BatchConsumerConfig
impl Send for BatchConsumerConfig
impl Sync for BatchConsumerConfig
impl Unpin for BatchConsumerConfig
impl UnsafeUnpin for BatchConsumerConfig
impl UnwindSafe for BatchConsumerConfig
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