@Internal public class TopicProducerRegister extends Object implements Closeable
Constructor and Description |
---|
TopicProducerRegister(SinkConfiguration sinkConfiguration) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
<T> org.apache.pulsar.client.api.TypedMessageBuilder<T> |
createMessageBuilder(String topic,
org.apache.pulsar.client.api.Schema<T> schema)
Create a TypedMessageBuilder which could be sent to Pulsar directly.
|
void |
flush()
Flush all the messages buffered in the client and wait until all messages have been
successfully persisted.
|
List<PulsarCommittable> |
prepareCommit()
Convert the transactions into a committable list for Pulsar Committer.
|
public TopicProducerRegister(SinkConfiguration sinkConfiguration)
public <T> org.apache.pulsar.client.api.TypedMessageBuilder<T> createMessageBuilder(String topic, org.apache.pulsar.client.api.Schema<T> schema)
public List<PulsarCommittable> prepareCommit()
public void flush() throws IOException
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.