mirror of
https://github.com/hanzoai/tasks.git
synced 2026-10-04 02:04:03 +00:00
## What changed? - Use archetypeID everywhere in history service and pass them to persistence ## Why? - Required for separate ID space work. ## How did you test it? - [x] built - [ ] run locally and tested manually - [x] covered by existing tests - [x] added new unit test(s) - [ ] added new functional test(s)
43 lines
852 B
Go
43 lines
852 B
Go
//go:generate mockgen -package $GOPACKAGE -source $GOFILE -destination library_mock.go
|
|
|
|
package chasm
|
|
|
|
import (
|
|
"google.golang.org/grpc"
|
|
)
|
|
|
|
type (
|
|
Library interface {
|
|
Name() string
|
|
Components() []*RegistrableComponent
|
|
Tasks() []*RegistrableTask
|
|
RegisterServices(server *grpc.Server)
|
|
|
|
mustEmbedUnimplementedLibrary()
|
|
}
|
|
|
|
UnimplementedLibrary struct{}
|
|
|
|
namer interface {
|
|
Name() string
|
|
}
|
|
)
|
|
|
|
func (UnimplementedLibrary) Components() []*RegistrableComponent {
|
|
return nil
|
|
}
|
|
|
|
func (UnimplementedLibrary) Tasks() []*RegistrableTask {
|
|
return nil
|
|
}
|
|
|
|
// RegisterServices Registers the gRPC calls to the handlers of the library.
|
|
func (UnimplementedLibrary) RegisterServices(_ *grpc.Server) {
|
|
}
|
|
|
|
func (UnimplementedLibrary) mustEmbedUnimplementedLibrary() {}
|
|
|
|
func fullyQualifiedName(libName, name string) string {
|
|
return libName + "." + name
|
|
}
|