Struct rdkafka::client::DefaultClientContext
source · pub struct DefaultClientContext;
Expand description
An empty ClientContext
that can be used when no customizations are
needed.
Uses the default callback implementations provided by ClientContext
.
Trait Implementations§
source§impl ClientContext for DefaultClientContext
impl ClientContext for DefaultClientContext
source§const ENABLE_REFRESH_OAUTH_TOKEN: bool = false
const ENABLE_REFRESH_OAUTH_TOKEN: bool = false
Whether to periodically refresh the SASL
OAUTHBEARER
token
by calling ClientContext::generate_oauth_token
. Read moresource§fn log(&self, level: RDKafkaLogLevel, fac: &str, log_message: &str)
fn log(&self, level: RDKafkaLogLevel, fac: &str, log_message: &str)
Receives log lines from librdkafka. Read more
source§fn stats(&self, statistics: Statistics)
fn stats(&self, statistics: Statistics)
Receives the decoded statistics of the librdkafka client. To enable, the
statistics.interval.ms
configuration parameter must be specified. Read moresource§fn stats_raw(&self, statistics: &[u8])
fn stats_raw(&self, statistics: &[u8])
Receives the JSON-encoded statistics of the librdkafka client. To
enable, the
statistics.interval.ms
configuration parameter must be
specified. Read moresource§fn error(&self, error: KafkaError, reason: &str)
fn error(&self, error: KafkaError, reason: &str)
Receives global errors from the librdkafka client. Read more
source§fn generate_oauth_token(
&self,
_oauthbearer_config: Option<&str>
) -> Result<OAuthToken, Box<dyn Error>>
fn generate_oauth_token( &self, _oauthbearer_config: Option<&str> ) -> Result<OAuthToken, Box<dyn Error>>
Generates an OAuth token from the provided configuration. Read more
source§impl Clone for DefaultClientContext
impl Clone for DefaultClientContext
source§fn clone(&self) -> DefaultClientContext
fn clone(&self) -> DefaultClientContext
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for DefaultClientContext
impl Debug for DefaultClientContext
source§impl Default for DefaultClientContext
impl Default for DefaultClientContext
source§fn default() -> DefaultClientContext
fn default() -> DefaultClientContext
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for DefaultClientContext
impl Send for DefaultClientContext
impl Sync for DefaultClientContext
impl Unpin for DefaultClientContext
impl UnwindSafe for DefaultClientContext
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