RobertIndie commented on code in PR #17455:
URL: https://github.com/apache/pulsar/pull/17455#discussion_r963236192


##########
site2/docs/client-libraries-go.md:
##########
@@ -846,43 +868,43 @@ ctx := context.Background()
 
 // create producer
 producer, err := client.CreateProducer(pulsar.ProducerOptions{
-       Topic:           topic,
-       DisableBatching: true,
+    Topic:           topic,
+    DisableBatching: true,
 })
 if err != nil {
-       log.Fatal(err)
+    log.Fatal(err)
 }
 defer producer.Close()
 
 // send 10 messages
-msgIDs := [10]MessageID{}
+msgIDs := [10]pulsar.MessageID{}
 for i := 0; i < 10; i++ {
-       msgID, err := producer.Send(ctx, &pulsar.ProducerMessage{
-               Payload: []byte(fmt.Sprintf("hello-%d", i)),
-       })
-       assert.NoError(t, err)
-       assert.NotNil(t, msgID)
-       msgIDs[i] = msgID
+    msgID, _ := producer.Send(ctx, &pulsar.ProducerMessage{

Review Comment:
   +1 for removing them. It's hard to maintain the parameters detail in two 
places: the go doc and the pulsar doc website. Or we can provide some commonly 
used parameters in this doc and let's user jump to go doc for more detail.
   In fact, the java client doc also encourages the user to jump to the java 
doc to get more details. But leave the loadConf configuration which is 
generated from the code in the doc.



-- 
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]

Reply via email to