mirror of
https://gitee.com/milvus-io/milvus.git
synced 2025-12-28 22:45:26 +08:00
issue: #33285 - add streaming node grpc client wrapper - add unittest for streaming node grpc client side - fix binary unsafe bug for message --------- Signed-off-by: chyezh <chyezh@outlook.com>
23 lines
532 B
Go
23 lines
532 B
Go
package assignment
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/milvus-io/milvus/pkg/streaming/util/types"
|
|
)
|
|
|
|
var _ Watcher = (*watcherImpl)(nil)
|
|
|
|
// Watcher is the interface for the channel assignment.
|
|
type Watcher interface {
|
|
// Get gets the channel assignment.
|
|
Get(ctx context.Context, channel string) *types.PChannelInfoAssigned
|
|
|
|
// Watch watches the channel assignment.
|
|
// Block until new term is coming.
|
|
Watch(ctx context.Context, channel string, previous *types.PChannelInfoAssigned) error
|
|
|
|
// Close stop the watcher.
|
|
Close()
|
|
}
|