mirror of
https://gitee.com/milvus-io/milvus.git
synced 2025-12-06 17:18:35 +08:00
issue: #33285 - optimize the message package - add interceptor package to achieve append operation intercepting. - add timetick interceptor to attach timetick properties for message. - add timetick background task to send timetick message. Signed-off-by: chyezh <chyezh@outlook.com>
33 lines
676 B
Go
33 lines
676 B
Go
//go:build test
|
|
// +build test
|
|
|
|
package walimplstest
|
|
|
|
import (
|
|
"github.com/milvus-io/milvus/pkg/streaming/util/message"
|
|
"github.com/milvus-io/milvus/pkg/streaming/walimpls"
|
|
"github.com/milvus-io/milvus/pkg/streaming/walimpls/registry"
|
|
)
|
|
|
|
const (
|
|
WALName = "test"
|
|
)
|
|
|
|
func init() {
|
|
// register the builder to the registry.
|
|
registry.RegisterBuilder(&openerBuilder{})
|
|
message.RegisterMessageIDUnmsarshaler(WALName, UnmarshalTestMessageID)
|
|
}
|
|
|
|
var _ walimpls.OpenerBuilderImpls = &openerBuilder{}
|
|
|
|
type openerBuilder struct{}
|
|
|
|
func (o *openerBuilder) Name() string {
|
|
return WALName
|
|
}
|
|
|
|
func (o *openerBuilder) Build() (walimpls.OpenerImpls, error) {
|
|
return &opener{}, nil
|
|
}
|