public interface ProducerInterceptor
ProducerInterceptor
is used to intercept send operations of producer.
The interceptor is able to view or modify the message being transmitted and collect the send record.
Modifier and Type | Method and Description |
---|---|
void |
postSend(Message message,
Context attributes)
Invoked immediately after the successful send invocation.
|
void |
preSend(Message message,
Context attributes)
Invoked before the message is actually sent to the network.
|
void preSend(Message message, Context attributes)
This allows for modification of the message if necessary.
message
- a message will be sent.attributes
- the extensible attributes delivered to the intercept thread.Copyright © 2017–2020 OpenMessaging. All rights reserved.