接口的使用
org.apache.pulsar.client.api.Producer
使用Producer的程序包
程序包
说明
Pulsar Client API.
Pulsar interceptors.
-
org.apache.pulsar.client.api中Producer的使用
返回变量类型为Producer的类型的org.apache.pulsar.client.api中的方法修饰符和类型方法说明ProducerBuilder.createAsync()Finalize the creation of theProducerinstance in asynchronous mode.参数类型为Producer的org.apache.pulsar.client.api中的方法修饰符和类型方法说明ProducerInterceptor.beforeSend(Producer<T> producer, Message<T> message) 已过时。This is called fromsend(Object)andsendAsync(Object)methods, before send the message to the brokers.voidProducerInterceptor.onSendAcknowledgement(Producer<T> producer, Message<T> message, MessageId msgId, Throwable exception) 已过时。This method is called when the message sent to the broker has been acknowledged, or when sending the message fails. -
org.apache.pulsar.client.api.interceptor中Producer的使用
修饰符和类型方法说明ProducerInterceptor.beforeSend(Producer producer, Message message) This is called fromsend(Object)andsendAsync(Object)methods, before send the message to the brokers.ProducerInterceptorWrapper.beforeSend(Producer producer, Message message) voidProducerInterceptor.onSendAcknowledgement(Producer producer, Message message, MessageId msgId, Throwable exception) This method is called when the message sent to the broker has been acknowledged, or when sending the message fails.voidProducerInterceptorWrapper.onSendAcknowledgement(Producer producer, Message message, MessageId msgId, Throwable exception)