Skip to content

Commit

Permalink
Added ability for sources to publish messages on their own just like …
Browse files Browse the repository at this point in the history
…their function counterparts (#6941)

Co-authored-by: Sanjeev Kulkarni <sanjeevk@splunk.com>
  • Loading branch information
srkukarni and Sanjeev Kulkarni authored May 13, 2020
1 parent 7a8b935 commit 5d6ca6d
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@

import org.apache.kafka.clients.consumer.ConsumerConfig;
import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.apache.pulsar.client.api.PulsarClientException;
import org.apache.pulsar.client.api.Schema;
import org.apache.pulsar.client.api.TypedMessageBuilder;
import org.apache.pulsar.io.core.SourceContext;
import org.apache.pulsar.io.kafka.KafkaAbstractSource;
import org.apache.pulsar.io.kafka.KafkaSourceConfig;
Expand Down Expand Up @@ -158,6 +161,11 @@ public ByteBuffer getState(String key) {
public CompletableFuture<ByteBuffer> getStateAsync(String key) {
return null;
}

@Override
public <O> TypedMessageBuilder<O> newOutputMessage(String topicName, Schema<O> schema) throws PulsarClientException {
return null;
}
};
Map<String, Object> config = new HashMap<>();
ThrowingRunnable openAndClose = ()->{
Expand Down

0 comments on commit 5d6ca6d

Please sign in to comment.