@checkstack/signal-backend 0.2.2 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/CHANGELOG.md +114 -0
  2. package/package.json +7 -6
package/CHANGELOG.md CHANGED
@@ -1,5 +1,119 @@
1
1
  # @checkstack/signal-backend
2
2
 
3
+ ## 0.2.4
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [42abfff]
8
+ - @checkstack/common@0.9.0
9
+ - @checkstack/backend-api@0.15.1
10
+ - @checkstack/signal-common@0.2.2
11
+
12
+ ## 0.2.3
13
+
14
+ ### Patch Changes
15
+
16
+ - 50e5f5f: Runtime plugin system: install + uninstall plugins from npm, GitHub releases
17
+ (including private GitHub Enterprise instances), or tarball uploads at
18
+ runtime, with multi-package bundles, dependency-derived compatibility checks,
19
+ multi-instance coordination via a Postgres artifact store, and
20
+ single-coordinator destructive cleanup.
21
+
22
+ Highlights:
23
+
24
+ - New `PluginSource` discriminated union and `PluginInstaller` /
25
+ `PluginInstallerRegistry` interfaces in `@checkstack/backend-api`. The
26
+ GitHub variant accepts an optional `apiBaseUrl` so deployments backed by
27
+ GitHub Enterprise can install from `https://ghe.example.com/api/v3`
28
+ instead of `api.github.com`.
29
+ - New `installPackageMetadataSchema` (Zod) in `@checkstack/common` validates
30
+ every plugin's `package.json` at install time. Required fields: `name`,
31
+ `version`, `description`, `author`, `license`, `checkstack.type`,
32
+ `checkstack.pluginId`. Optional: `checkstack.bundle`,
33
+ `checkstack.usageInstructions`, `checkstack.allowInstallScripts`.
34
+ - New `pluginManagerContract` in `@checkstack/pluginmanager-common` with
35
+ `list`, `previewInstall`, `install`, `previewUninstall`, `uninstall`, and
36
+ `events` procedures.
37
+ - New `@checkstack/pluginmanager-frontend` admin UI: installed-plugins list
38
+ with per-row uninstall (typed-confirmation modal, schema/configs/cascade
39
+ toggles), install page with NPM / Tarball Upload / GitHub Release tabs
40
+ (Catalog tab disabled — coming soon), and an events page surfacing the
41
+ install/uninstall audit log.
42
+ - New `bunx @checkstack/scripts plugin-pack` CLI for plugin authors —
43
+ per-package mode produces an npm-shaped tarball; `--bundle` mode produces
44
+ an outer tarball containing every sibling declared in
45
+ `package.json#checkstack.bundle`. Published to npm so external authors
46
+ can `bunx` it directly without a workspace checkout.
47
+ - Compatibility derived from `package.json#dependencies` ranges
48
+ (`semver.satisfies` against the platform's loaded `@checkstack/*`
49
+ versions) — no separate `compatibility` field.
50
+ - Multi-instance: originator persists artifacts + `plugins` rows + broadcasts
51
+ install/uninstall; receiving instances do in-process register/unregister
52
+ only. Destructive ops (drop schema, delete plugin_configs, delete
53
+ artifacts, delete `plugins` rows) run exactly once on the originator.
54
+ - Fresh-instance bootstrap: `loadPlugins()` hydrates any
55
+ `is_uninstallable=true` plugin missing from `node_modules` from the
56
+ artifact store before normal Phase 1 register.
57
+ - New schema: `plugin_artifacts` (tarball storage), `plugin_install_events`
58
+ (audit/error log). `plugins` extended with `version`, `metadata`,
59
+ `source`, `bundle_id`, `is_primary`. Local plugin sync now writes
60
+ `version` from each plugin's `package.json` so the admin UI shows real
61
+ versions instead of `—`.
62
+ - Tarball-upload endpoint (`POST /api/pluginmanager/upload-tarball`) for
63
+ the install UI; access-gated by `pluginmanager.plugin.manage`.
64
+ - Plugin Manager menu link added to the user menu (main grid, alongside
65
+ Profile / Notification Settings / etc.).
66
+
67
+ Cross-cutting changes:
68
+
69
+ - Backend request/response logging now flows through `rootLogger` (winston)
70
+ instead of `hono/logger`. 5xx responses include the response body inline
71
+ so swallowed early-return errors are visible in the log.
72
+ - The `/api/:pluginId/*` dispatcher now logs which core service is missing
73
+ or which `pluginId` had no metadata when it 500s.
74
+ - New `registerCorePluginMetadata` on `PluginManager` for core routers
75
+ (like the plugin manager itself) that need their metadata visible to the
76
+ RPC dispatcher without going through the full plugin lifecycle.
77
+ - ESLint: `unicorn/no-null` is now disabled globally. Drizzle distinguishes
78
+ between `null` (writes a real SQL NULL) and `undefined` (skip the column
79
+ on insert), so treating them as interchangeable produced latent bugs at
80
+ the persistence boundary. The bulk of the patch-bumped packages above
81
+ reflect lint-fix touches that landed when this rule was relaxed.
82
+ - Workspace-wide license normalization to `Elastic-2.0` (matches
83
+ `LICENSE.md`). Every `package.json` in the workspace now declares the
84
+ same SPDX identifier; the patch bumps capture this.
85
+
86
+ Plugin packages (every `plugins/*`): added a `pack` npm script
87
+ (`bunx @checkstack/scripts plugin-pack`), mirrored each plugin's
88
+ `pluginId` from `plugin-metadata.ts` into `package.json#checkstack.pluginId`
89
+ so install-time validation passes, stubbed any missing required metadata
90
+ fields (`description`, `author`, `license`), and added
91
+ `checkstack.bundle` to multi-package plugin primaries (telegram, rcon, ssh,
92
+ jira, queue-bullmq, queue-memory, cache-memory).
93
+
94
+ Breaking changes:
95
+
96
+ - The legacy single-method `PluginInstaller` interface (`install(packageName)`)
97
+ is removed. Callers must use `coreServices.pluginInstallerRegistry`.
98
+ - The old `pluginAdminContract` and `createPluginAdminRouter` are removed.
99
+ Replaced by `pluginManagerContract` in `@checkstack/pluginmanager-common`
100
+ and `createPluginManagerRouter` in `core/backend`.
101
+ - `@checkstack/test-utils-backend` no longer exports
102
+ `createMockPluginInstaller` / `MockPluginInstaller` (the legacy interface
103
+ it shimmed is gone).
104
+
105
+ Note: bumps are limited to `minor` (for packages with new public API
106
+ surface) and `patch` (for downstream consumers, license normalization,
107
+ and lint fixes). No `major` bumps despite the `PluginInstaller` removal —
108
+ the legacy interface had no third-party consumers in the wild before this
109
+ runtime plugin system landed, and the contract surface is the same shape
110
+ modulo the rename.
111
+
112
+ - Updated dependencies [50e5f5f]
113
+ - @checkstack/backend-api@0.15.0
114
+ - @checkstack/common@0.8.0
115
+ - @checkstack/signal-common@0.2.1
116
+
3
117
  ## 0.2.2
4
118
 
5
119
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@checkstack/signal-backend",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
+ "license": "Elastic-2.0",
4
5
  "type": "module",
5
6
  "exports": {
6
7
  ".": {
@@ -8,16 +9,16 @@
8
9
  }
9
10
  },
10
11
  "dependencies": {
11
- "@checkstack/common": "0.7.0",
12
- "@checkstack/signal-common": "0.2.0",
13
- "@checkstack/backend-api": "0.14.0"
12
+ "@checkstack/common": "0.8.0",
13
+ "@checkstack/signal-common": "0.2.1",
14
+ "@checkstack/backend-api": "0.15.0"
14
15
  },
15
16
  "devDependencies": {
16
17
  "@types/bun": "latest",
17
18
  "typescript": "^5.7.2",
18
19
  "zod": "^4.0.0",
19
- "@checkstack/tsconfig": "0.0.5",
20
- "@checkstack/scripts": "0.1.2"
20
+ "@checkstack/tsconfig": "0.0.7",
21
+ "@checkstack/scripts": "0.3.0"
21
22
  },
22
23
  "scripts": {
23
24
  "typecheck": "tsgo -b",