Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type InventoryService ¶
type InventoryService interface { RegisterService(name string, protocol string) (model.Service, error) UnregisterService(name string) (deleted bool, referer []string, err error) GetService(name string) (model.Service, bool, error) GetServiceNames() ([]string, error) AddServiceDependency(serviceName string, dependServiceNames string, egressPort uint32) error RemoveServiceDependency(serviceName string, dependServiceNames string) (bool, error) GetRefferersOf(serviceName string) ([]string, error) RegisterHost(serviceName, hostName, ingressAddr, substanceAddr, egressHost string) (model.Host, error) UnregisterHost(serviceName string, hostName string) (bool, error) GetHostByName(name string) (model.Host, bool, error) GetHostNames() ([]string, error) GetHostsOfService(serviceName string) ([]model.Host, error) UpdateHost(serviceName string, hostName string, ingressAddr, substanceAddr, egressHost *string) (host model.Host, err error) IdempotentService(serviceName string, param model.IdempotentServiceParam) (changed bool, err error) }
InventoryService is domain service shich manages meshem inventories.
func NewInventoryService ¶
func NewInventoryService( repo repository.InventoryRepository, discoery repository.DiscoveryRepository, versionGen VersionGenerator, logger *logrus.Logger, ) InventoryService
NewInventoryService creates an InventoryService instance.
type MockedVersionGen ¶
MockedVersionGen is mock generator for testing
func (*MockedVersionGen) New ¶
func (gen *MockedVersionGen) New() model.Version
type VersionGenerator ¶
func NewCurrentTimeGenerator ¶
func NewCurrentTimeGenerator() VersionGenerator
Click to show internal directories.
Click to hide internal directories.