@kronos-integration/service-mqtt 2.0.1 → 2.0.3
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kronos-integration/service-mqtt",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.3",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"provenance": true
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
"lint:typescript": "tsc --allowJs --checkJs --noEmit --resolveJsonModule --target es2024 --lib es2024 -m esnext --module nodenext --moduleResolution nodenext ./src**/*.mjs"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@kronos-integration/service": "^12.0.
|
|
39
|
+
"@kronos-integration/service": "^12.0.5",
|
|
40
40
|
"mqtt": "^5.13.3",
|
|
41
|
-
"pacc": "^3.
|
|
41
|
+
"pacc": "^3.7.0"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@types/node": "^24.0.15",
|
package/src/service-mqtt.mjs
CHANGED
package/src/topic-endpoint.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SendEndpoint } from "@kronos-integration/endpoint";
|
|
2
2
|
|
|
3
|
-
export class TopicEndpoint extends
|
|
3
|
+
export class TopicEndpoint extends SendEndpoint {
|
|
4
4
|
constructor(name, owner, options) {
|
|
5
5
|
super(name, owner, options);
|
|
6
6
|
|
package/tests/mqtt-ava.mjs
CHANGED
|
@@ -27,7 +27,10 @@ test("start / stop", async t => {
|
|
|
27
27
|
const sp = new StandaloneServiceProvider();
|
|
28
28
|
|
|
29
29
|
const r1 = new ReceiveEndpoint("r1", sp);
|
|
30
|
-
|
|
30
|
+
|
|
31
|
+
const received = [];
|
|
32
|
+
|
|
33
|
+
r1.receive = async (message) => received.push(message);
|
|
31
34
|
|
|
32
35
|
const mqtt = await sp.declareService({
|
|
33
36
|
type: ServiceMQTT,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export class TopicEndpoint extends
|
|
1
|
+
export class TopicEndpoint extends SendEndpoint {
|
|
2
2
|
constructor(name: any, owner: any, options: any);
|
|
3
3
|
_topic: any;
|
|
4
4
|
get topic(): any;
|
|
5
5
|
}
|
|
6
|
-
import {
|
|
6
|
+
import { SendEndpoint } from "@kronos-integration/endpoint";
|