mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-10-06 14:31:57 +02:00
rename functions
This commit is contained in:
1 parent
d9bd343055
commit
d0d24f1e40
2 files changed
+3
-3
No files matched your search
@@ -21,12 +21,12 @@ func (p *TopicPublisher) doConnect(partition *mq_pb.Partition, brokerAddress str
|
||||
return publishClient, fmt.Errorf("dial broker %s: %v", brokerAddress, err)
|
||||
}
|
||||
brokerClient := mq_pb.NewSeaweedMessagingClient(grpcConnection)
|
||||
stream, err := brokerClient.SubscribeMessage(context.Background())
|
||||
stream, err := brokerClient.PublishMessage(context.Background())
|
||||
if err != nil {
|
||||
return publishClient, fmt.Errorf("create publish client: %v", err)
|
||||
}
|
||||
publishClient = &PublishClient{
|
||||
SeaweedMessaging_PublishClient: stream,
|
||||
SeaweedMessaging_PublishMessageClient: stream,
|
||||
Broker: brokerAddress,
|
||||
}
|
||||
if err = publishClient.Send(&mq_pb.PublishMessageRequest{
|
||||
|
||||
@@ -17,7 +17,7 @@ type PublisherConfiguration struct {
|
||||
}
|
||||
|
||||
type PublishClient struct {
|
||||
mq_pb.SeaweedMessaging_PublishClient
|
||||
mq_pb.SeaweedMessaging_PublishMessageClient
|
||||
Broker string
|
||||
Err error
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user