plugin-cluster-manager
v1.1.18
Published
Cluster node tracking, task orchestration, worker management, and package distribution
Readme
plugin-cluster-manager
Overview
Monitor and operate NocoBase cluster nodes, async tasks, workflow executions, event queues, locks, caches, Redis metrics, container workers, and worker package installation.
Features
- Cluster Nodes: Realtime view of active app, worker, task, and sandbox nodes through Redis heartbeats.
- Task And Workflow Monitoring: Inspect async tasks and workflow executions, including the node that processed each execution.
- Runtime Monitors: Inspect Redis, event queue, distributed locks, ACL cache, and cache manager state.
- Container Orchestrator: Manage Docker or Kubernetes worker stacks with leader-only write operations.
- Worker Packages: Configure and dispatch apt, npm, and Python package installation across matching node roles.
- Plugin Operations: List installed plugins and force-disable or force-remove broken plugin registry records.
Architecture Flow
src/index.tsexports the server package. The client package is exposed throughsrc/client/index.tsx.- The client registers the
Cluster Managersettings page and rendersClusterManagerLayout, which groups the admin tools into tabs. - The server
beforeLoad()imports all collection definitions fromsrc/server/collections, including config collections and resource-only collection stubs needed by workflow/ACL lookups. - The server
load()wires runtime services and APIs: Redis node registry, PubSub adapter, Redis lock adapter polyfill, PubSub subscribers, resource actions, plugin force operations, ACL snippet, ACL cache middleware, health endpoint, and orchestrator initialization. afterStartstarts node heartbeats, worker package auto-install, and leader election.beforeStopstops the node registry and releases leadership.- Shared runtime state uses Redis and PubSub for heartbeats, execution-node mapping, restart/log/package commands, and package status. Durable settings stay in database collections.
Usage
- Enable the plugin.
- Only accessible to Super Admins.
- Navigate to System Settings -> Cluster Manager.
- Use the dashboard to troubleshoot performance issues, retry failed background tasks, or clear caches.
