[][src]Trait statefun::io::kafka::KafkaEgress

pub trait KafkaEgress {
    fn kafka_egress<M: Message>(
        &mut self,
        identifier: EgressIdentifier,
        topic: &str,
        message: M
    );
fn kafka_keyed_egress<M: Message>(
        &mut self,
        identifier: EgressIdentifier,
        topic: &str,
        key: &str,
        message: M
    ); }

Extension trait for sending egress messages to Kafka using Effects.

Required methods

fn kafka_egress<M: Message>(
    &mut self,
    identifier: EgressIdentifier,
    topic: &str,
    message: M
)

Sends the given message to the Kafka topic topic via the egress specified using the EgressIdentifier.

fn kafka_keyed_egress<M: Message>(
    &mut self,
    identifier: EgressIdentifier,
    topic: &str,
    key: &str,
    message: M
)

Sends the given message to the Kafka topic topic via the egress specified using the EgressIdentifier.

This will set the given key on the message sent to record.

Loading content...

Implementors

impl KafkaEgress for Effects[src]

Loading content...