Files
tasks/chasm/library.go
Yichao YangandGitHub 63839f1a9d CHASM: Propagate ArchetypeID (#8693)
## 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)
2025-11-26 16:04:44 -08:00

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
}