Gleiphir2769 commented on code in PR #17789:
URL: https://github.com/apache/pulsar/pull/17789#discussion_r1005465097
##########
site2/docs/client-libraries-go.md:
##########
@@ -204,6 +204,34 @@ for i := 0; i < 10; i++ {
}
```
+#### How to use chunking in producer
+
+```go
+client, err := pulsar.NewClient(pulsar.ClientOptions{
+ URL: serviceURL,
+})
+
+if err != nil {
+ log.Fatal(err)
+}
+defer client.Close()
+
+// The message chunking feature is OFF by default.
+// By default, producer chunks the large message based on max message size
(maxMessageSize) configured at broker (eg: 5MB).
Review Comment:
Good suggestion, thx!
##########
site2/docs/client-libraries-go.md:
##########
@@ -204,6 +204,34 @@ for i := 0; i < 10; i++ {
}
```
+#### How to use chunking in producer
+
+```go
+client, err := pulsar.NewClient(pulsar.ClientOptions{
+ URL: serviceURL,
+})
+
+if err != nil {
+ log.Fatal(err)
+}
+defer client.Close()
+
+// The message chunking feature is OFF by default.
+// By default, producer chunks the large message based on max message size
(maxMessageSize) configured at broker (eg: 5MB).
+// Client can also configure max chunked size using producer configuration
ChunkMaxMessageSize.
Review Comment:
Good suggestion, thx!
##########
site2/docs/client-libraries-go.md:
##########
@@ -204,6 +204,34 @@ for i := 0; i < 10; i++ {
}
```
+#### How to use chunking in producer
+
+```go
+client, err := pulsar.NewClient(pulsar.ClientOptions{
+ URL: serviceURL,
+})
+
+if err != nil {
+ log.Fatal(err)
+}
+defer client.Close()
+
+// The message chunking feature is OFF by default.
+// By default, producer chunks the large message based on max message size
(maxMessageSize) configured at broker (eg: 5MB).
+// Client can also configure max chunked size using producer configuration
ChunkMaxMessageSize.
+// Attention, to enable chunking, you need to disable batching
(DisableBatching=true) concurrently.
Review Comment:
Good suggestion, thx!
--
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]