directory
3.0.0-alpha9+incompatible
Repository: https://github.com/opensvc/om3.git
Documentation: pkg.go.dev

# Packages

Package api provides primitives to interact with the openapi HTTP API.
Package ccfg is responsible for the cluster config It subscribes on msgbus.ConfigFileUpdated for cluster to provide: cluster configuration reload: => cluster.ConfigData update => .cluster.config => clusternode update (for node selector, clusternodes dereference) => publication of msgbus.ClusterConfigUpdated for local node.
cstat is responsible of the cluster status It provides: .cluster.status.
Package daemon provide the subdaemon main responsible ot other opensvc daemons It is responsible for other sub daemons (listener, discover, scheduler, hb...) */.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Package daemondata implements daemon journaled data import "opensvc.com/opensvc/daemon/daemondata" cmdC, cancel := daemondata.Start(context.Background()) defer cancel() dataBus := daemondata.New(cmdC) status := dataBus.ClusterData() // retrieve daemon data bus.ApplyFull("remote-1", remoteNodeStatus) bus.ApplyPatch("remote-1", patchMsg) bus.CommitPending(context.Background()) status = bus.ClusterData() localNodeStatus := bus.GetLocalNodeStatus() */.
No description provided by the author
Package daemonhelper is a helper for daemon components tests.
No description provided by the author
Package discover implements object discovery for daemon It watches config filesystem to create initial instance config worker when config file is created.
dns is responsible of the cluster dns zone.
Package draincommand is a helper for daemon drain commands.
No description provided by the author
No description provided by the author
No description provided by the author
Package hbcache manage []cluster.HeartbeatStream cache localnode This cache will be populated from: - heartbeat status # It provides the heartbeat for sub.hb.heartbeat The cache must be started with Start(ctx).
Package icfg is responsible for local instance.Config instConfig are created by daemon discover.
Package imon is responsible for of local instance state It provides the cluster data: ["cluster", "node", <localhost>, "services", "status", <instance>, "monitor"] ["cluster", "node", <localhost>, "services", "imon", <instance>] imon are created by the local instcfg, with parent context instcfg context.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Package nmon is responsible for the local node states It provides the cluster data: .cluster.node.<localhost>.monitor .cluster.node.<localhost>.stats .cluster.node.<localhost>.status (except gen) # It maintains the nodesinfo.json The worker watches local status updates and clear reached status => unsetStatusWhenReached => orchestrate => pub new state if change The worker watches remote nmon updates and converge global expects => convergeGlobalExpectFromRemote => orchestrate => pub new state if change.
Package omon is responsible for of object.Status It provides the cluster data cluster.objects.<path> worker ends when context is done or when no more service instance config exist worker is responsible for local imon startup when local instance config is detected worker watch on instance status, monitor, config updates to refresh object.Status.
No description provided by the author
No description provided by the author
Package remoteconfig defines functions to fetch object config file from api TODO move daemon/remoteconfig to core/remoteconfig since it is not anymore dedicated to daemon ?.
Package routinehelper provides counter for goroutines Example: type ( T struct { routinehelper.TT } ) func New() *T { return &T{TT: *routinehelper.NewTracer()} } func (t *T) fooRoutineLoop(nb int) { done := make(chan bool) running := make(chan bool) for i := 0; i < nb; i++ { go func() { defer t.Trace("foo")() // foo routine code }() go func() { defer t.Trace("bar")() // bar routine code }() } } func (t *T) ShowStats() routinehelper.Stat { return t.TraceRDump() } */.
No description provided by the author
Package subDaemon provides main and sub daemon management features Start, Stop, Restart 1 go routines is used to serialize Start/Stop/Restart A subdaemon can have subdaemons */.