Stellar1999 commented on issue #16184:
URL: https://github.com/apache/pulsar/issues/16184#issuecomment-1673020101
I am trying to see what will be printed on stdout when the producer sends a
message, so I wrote code like this:
`public class Producer {
public static void main(String[] args) throws PulsarClientException {
PulsarClient client = PulsarClient.builder()
.serviceUrl("pulsar://localhost:6650")
.build();
org.apache.pulsar.client.api.Producer<String> producer =
client.newProducer(Schema.STRING)
.topic("my-topic")
.create();
// You can then send messages to the broker and topic you specified:
producer.send("My message");
producer.close();
client.close();
}
}
`
However, I see nothing in stdout. Is there anything wrong here?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]