You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2019/08/20 06:51:41 UTC
[GitHub] [pulsar-client-go] wolfstudy commented on issue #57: the function
Send() performance
wolfstudy commented on issue #57: the function Send() performance
URL: https://github.com/apache/pulsar-client-go/issues/57#issuecomment-522879959
I use the built-in perf tool to test, the configuration information is as follows:
```
INFO[12:22:41.044] Producer config: {
"Topic": "topic-1",
"Rate": 1000000,
"BatchingTimeMillis": 1,
"MessageSize": 1000,
"ProducerQueueSize": 50000
}
```
The test output is as follows:
```
INFO[12:22:51.083] Stats - Publish rate: 246900.1 msg/s - 1883.7 Mbps - Latency ms: 50% 13.7 - 95% 91.7 - 99% 149.9 - 99.9% 149.9 - max 149.9
INFO[12:23:01.083] Stats - Publish rate: 265570.9 msg/s - 2026.1 Mbps - Latency ms: 50% 23.8 - 95% 144.5 - 99% 746.2 - 99.9% 746.2 - max 746.2
INFO[12:23:11.083] Stats - Publish rate: 252799.7 msg/s - 1928.7 Mbps - Latency ms: 50% 13.2 - 95% 39.9 - 99% 625.0 - 99.9% 625.0 - max 625.0
INFO[12:23:21.078] Stats - Publish rate: 65036.2 msg/s - 496.2 Mbps - Latency ms: 50% 2.0 - 95% 3.0 - 99% 77.0 - 99.9% 77.0 - max 77.0
INFO[12:23:31.074] Stats - Publish rate: 57996.1 msg/s - 442.5 Mbps - Latency ms: 50% 1.9 - 95% 3.0 - 99% 546.3 - 99.9% 546.3 - max 546.3
```
You can try sending it using `sendAsync`:
```
producer.SendAsync(context.Background(), &ProducerMessage{
Payload: []byte("hello"),
}, func(id MessageID, message *ProducerMessage, e error) {
// ...
})
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services