Versions in this module Expand all Collapse all v2 v2.0.0 Jul 31, 2024 Changes in this version + type Hooks struct + OnDaemonConfigUpdate func(ctx context.Context, s State, config types.DaemonConfig) error + OnHeartbeat func(ctx context.Context, s State) error + OnNewMember func(ctx context.Context, s State, newMember types.ClusterMemberLocal) error + OnStart func(ctx context.Context, s State) error + PostBootstrap func(ctx context.Context, s State, initConfig map[string]string) error + PostJoin func(ctx context.Context, s State, initConfig map[string]string) error + PostRemove func(ctx context.Context, s State, force bool) error + PreBootstrap func(ctx context.Context, s State, initConfig map[string]string) error + PreJoin func(ctx context.Context, s State, initConfig map[string]string) error + PreRemove func(ctx context.Context, s State, force bool) error + type InternalState struct + Context context.Context + Endpoints *endpoints.Endpoints + Extensions extensions.Extensions + Hooks *Hooks + InternalAddress func() *api.URL + InternalClusterCert func() *shared.CertInfo + InternalDatabase *db.DqliteDB + InternalExtensionServers func() []string + InternalFileSystem func() *sys.OS + InternalName func() string + InternalRemotes func() *trust.Remotes + InternalServerCert func() *shared.CertInfo + InternalVersion func() string + LocalConfig func() *internalConfig.DaemonConfig + ReadyCh chan struct{} + ReloadCert func(name types.CertificateName) error + ShutdownDoneCh chan error + StartAPI func(ctx context.Context, bootstrap bool, initConfig map[string]string, ...) error + Stop func() (exit func(), stopErr error) + StopListeners func() error + UpdateServers func() error + func ToInternal(s State) (*InternalState, error) + func (s *InternalState) Address() *api.URL + func (s *InternalState) Cluster(isNotification bool) (client.Cluster, error) + func (s *InternalState) ClusterCert() *shared.CertInfo + func (s *InternalState) Database() db.DB + func (s *InternalState) ExtensionServers() []string + func (s *InternalState) FileSystem() *sys.OS + func (s *InternalState) HasExtension(ext string) bool + func (s *InternalState) Leader() (*client.Client, error) + func (s *InternalState) Name() string + func (s *InternalState) Remotes() *trust.Remotes + func (s *InternalState) ServerCert() *shared.CertInfo + func (s *InternalState) Version() string + type State interface + Address func() *api.URL + Cluster func(isNotification bool) (client.Cluster, error) + ClusterCert func() *shared.CertInfo + Database func() db.DB + ExtensionServers func() []string + FileSystem func() *sys.OS + HasExtension func(ext string) bool + Leader func() (*client.Client, error) + Name func() string + Remotes func() *trust.Remotes + ServerCert func() *shared.CertInfo + Version func() string Other modules containing this package github.com/masnax/microtest