commit | 5227a57168b1be7018e4d11a7a3d7e17465cc9a7 | [log] [tgz] |
---|---|---|
author | xiaolong.ran <ranxiaolong716@gmail.com> | Thu Aug 01 11:20:31 2019 +0800 |
committer | xiaolong.ran <ranxiaolong716@gmail.com> | Thu Aug 01 11:20:31 2019 +0800 |
tree | 3cfaebbd623f39e296ab80b2dbc70efb2a2236d7 | |
parent | 7a9aa2b36371437b1c409cb21cb2056ded7f198d [diff] |
[issue:34] Fix zlib compress Decompress logic Signed-off-by: xiaolong.ran <ranxiaolong716@gmail.com>
Note: this library is still a work in progress. For production usage, please refer to the CGo based client library, documented at http://pulsar.apache.org/docs/en/client-libraries-go/
This projects is developing a pure-Go client library for Pulsar that does not depend on the C++ Pulsar library.
Once feature parity and stability are reached, this will supersede the current CGo based library.
Check the Projects page at https://github.com/apache/pulsar-client-go/projects for tracking the status and the progress.
Import the client library:
import "github.com/apache/pulsar-client-go/pulsar"
client, err := pulsar.NewClient(pulsar.ClientOptions{
URL: "pulsar://localhost:6650",
})
producer, err := client.CreateProducer(pulsar.ProducerOptions{
Topic: "my-topic",
})
err = producer.Send(context.Background(), &pulsar.ProducerMessage{
Payload: []byte("hello"),
})
if err == nil {
fmt.Println("Published message")
} else {
fmt.Println("Failed to publish message", err)
}
Name | Scope | |||
---|---|---|---|---|
users@pulsar.apache.org | User-related discussions | Subscribe | Unsubscribe | Archives |
dev@pulsar.apache.org | Development-related discussions | Subscribe | Unsubscribe | Archives |
Pulsar slack channel #dev-go
at https://apache-pulsar.slack.com/
You can self-register at https://apache-pulsar.herokuapp.com/
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0