@uns-kit/core 3.0.4 → 3.0.6
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.
- package/README.md +7 -7
- package/package.json +18 -18
package/README.md
CHANGED
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
Core utilities and runtime building blocks for Unified Namespace (UNS) applications. The package bundles the process lifecycle manager, MQTT integrations, gRPC gateway helpers, configuration tooling, and shared type definitions that power the UNS ecosystem.
|
|
4
4
|
|
|
5
|
-
Note: Apps built with uns-kit are intended to be managed by the **UNS
|
|
5
|
+
Note: Apps built with uns-kit are intended to be managed by the **UNS OpenHub controller**.
|
|
6
6
|
|
|
7
7
|
## uns-kit in context
|
|
8
8
|
|
|
9
9
|
| Package | Description |
|
|
10
10
|
| --- | --- |
|
|
11
|
-
| [`@uns-kit/core`](https://github.com/uns-
|
|
12
|
-
| [`@uns-kit/api`](https://github.com/uns-
|
|
13
|
-
| [`@uns-kit/cron`](https://github.com/uns-
|
|
14
|
-
| [`@uns-kit/cli`](https://github.com/uns-
|
|
11
|
+
| [`@uns-kit/core`](https://github.com/uns-openhub/uns-kit/tree/main/packages/uns-core) | Base runtime (UnsProxyProcess, MQTT helpers, config tooling, gRPC gateway). |
|
|
12
|
+
| [`@uns-kit/api`](https://github.com/uns-openhub/uns-kit/tree/main/packages/uns-api) | Express plugin — HTTP endpoints, JWT/JWKS auth, Swagger, UNS metadata. |
|
|
13
|
+
| [`@uns-kit/cron`](https://github.com/uns-openhub/uns-kit/tree/main/packages/uns-cron) | Cron-driven scheduler that emits UNS events on a fixed cadence. |
|
|
14
|
+
| [`@uns-kit/cli`](https://github.com/uns-openhub/uns-kit/tree/main/packages/uns-cli) | CLI for scaffolding new UNS applications. |
|
|
15
15
|
|
|
16
16
|
## Installation
|
|
17
17
|
|
|
@@ -25,7 +25,7 @@ npm install @uns-kit/core
|
|
|
25
25
|
|
|
26
26
|
- **UnsProxyProcess** — the central runtime class. It manages the MQTT connection, plugin lifecycle, and the instance status topic. Plugins (`@uns-kit/api`, `@uns-kit/cron`) augment it with domain-specific proxy factories.
|
|
27
27
|
- **UnsProxy** — base class extended by all plugin proxies. Tracks produced topics, API endpoints, and catch-all mappings; re-publishes them to the controller on a 60-second cadence.
|
|
28
|
-
- **ConfigFile** — loads and validates `config.json` at startup. On a real server this file is provided by the UNS
|
|
28
|
+
- **ConfigFile** — loads and validates `config.json` at startup. On a real server this file is provided by the UNS OpenHub controller; in development you maintain it yourself.
|
|
29
29
|
- **MQTT helpers** — resilient publishers, topic builders, throttled queues, and handover support.
|
|
30
30
|
- **gRPC gateway** — infrastructure to bridge Python workers into the UNS message fabric.
|
|
31
31
|
|
|
@@ -81,7 +81,7 @@ const cron = await proc.createCrontabProxy("*/5 * * * *", { event: "tick" });
|
|
|
81
81
|
|
|
82
82
|
## Datahub client (last value + history)
|
|
83
83
|
|
|
84
|
-
`UnsClient` provides a minimal REST client for the UNS
|
|
84
|
+
`UnsClient` provides a minimal REST client for the UNS OpenHub API, including batch last-value, single-topic catch-all history, and batch range endpoints. Prefer a long-lived service token if available; you can pass it directly and skip username/password auth.
|
|
85
85
|
|
|
86
86
|
```ts
|
|
87
87
|
import { UnsClient } from "@uns-kit/core";
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uns-kit/core",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.6",
|
|
4
4
|
"description": "Core utilities and runtime building blocks for UNS-based realtime transformers.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "Aljoša Vister <aljosa.vister@gmail.com>",
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
|
-
"url": "https://github.com/uns-
|
|
10
|
+
"url": "https://github.com/uns-openhub/uns-kit.git",
|
|
11
11
|
"directory": "packages/uns-core"
|
|
12
12
|
},
|
|
13
13
|
"keywords": [
|
|
@@ -32,28 +32,28 @@
|
|
|
32
32
|
"main": "dist/index.js",
|
|
33
33
|
"types": "dist/index.d.ts",
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@grpc/grpc-js": "^1.14.
|
|
36
|
-
"@grpc/proto-loader": "^0.8.
|
|
37
|
-
"@infisical/sdk": "^
|
|
38
|
-
"azure-devops-node-api": "^15.1.
|
|
35
|
+
"@grpc/grpc-js": "^1.14.4",
|
|
36
|
+
"@grpc/proto-loader": "^0.8.1",
|
|
37
|
+
"@infisical/sdk": "^5.0.2",
|
|
38
|
+
"azure-devops-node-api": "^15.1.2",
|
|
39
39
|
"chalk": "^5.6.2",
|
|
40
|
-
"fs-extra": "^11.
|
|
41
|
-
"get-port": "^7.
|
|
42
|
-
"jsonwebtoken": "^9.0.
|
|
43
|
-
"mqtt": "^5.
|
|
40
|
+
"fs-extra": "^11.4.0",
|
|
41
|
+
"get-port": "^7.2.0",
|
|
42
|
+
"jsonwebtoken": "^9.0.3",
|
|
43
|
+
"mqtt": "^5.15.2",
|
|
44
44
|
"pkg-dir": "^9.0.0",
|
|
45
|
-
"prettier": "^3.6
|
|
46
|
-
"simple-git": "^3.
|
|
47
|
-
"tsx": "^4.
|
|
48
|
-
"winston": "^3.
|
|
45
|
+
"prettier": "^3.9.6",
|
|
46
|
+
"simple-git": "^3.36.0",
|
|
47
|
+
"tsx": "^4.23.8",
|
|
48
|
+
"winston": "^3.19.0",
|
|
49
49
|
"winston-gelf": "^1.7.0",
|
|
50
|
-
"ws": "^8.
|
|
51
|
-
"zod": "^3",
|
|
52
|
-
"zod-to-json-schema": "^3.
|
|
50
|
+
"ws": "^8.21.2",
|
|
51
|
+
"zod": "^3.25.76",
|
|
52
|
+
"zod-to-json-schema": "^3.25.2",
|
|
53
53
|
"zod-to-ts": "^1.2.0"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
|
-
"@types/jsonwebtoken": "^9.0.
|
|
56
|
+
"@types/jsonwebtoken": "^9.0.10",
|
|
57
57
|
"@types/ws": "^8.18.1"
|
|
58
58
|
},
|
|
59
59
|
"scripts": {
|