NEWS
MQTT Topics ignorieren
-
Hallo,
ich habe hier drei MQTT Clients die extrem viele Topics senden.
Davon würde ich gerne welche über diese Funktion abbestellen:
Ich hoffe das ist so gedacht!?
Die MQTT Instanz ist der Server.Ignorieren möchte ich alles unter:
mqtt.0.instar.all.alarm.*
mqtt.0.instar.cam_10.alarm.*
und
mqtt.0.instar.cam_11.alarm.*Lösche ich nun alle Objekte und gebe ich im Feld ".alarm.*" ein werden diese trotzdem wieder erstellt.
Was mache ich falsch?
-
-
@marc-berg sagte in MQTT Topics ignorieren:
.alarm.
Ja, das bringt den Adapter in einen Bootloop.
host.Smartazamba 2024-02-14 20:13:51.443 info Restart adapter system.adapter.mqtt.0 because enabled host.Smartazamba 2024-02-14 20:13:51.443 error instance system.adapter.mqtt.0 terminated with code 6 (UNCAUGHT_EXCEPTION) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at /opt/iobroker/node_modules/@iobroker/js-controller-adapter/src/lib/adapter/adapter.ts:11905:26 host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTT._callReadyHandler (/opt/iobroker/node_modules/@iobroker/js-controller-adapter/src/lib/adapter/adapter.ts:11928:18) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTT.emit (node:domain:489:12) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTT.emit (node:events:517:28) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTT.onReady (/opt/iobroker/node_modules/iobroker.mqtt/main.js:38:24) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTT.main (/opt/iobroker/node_modules/iobroker.mqtt/main.js:99:54) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at MQTTServer (/opt/iobroker/node_modules/iobroker.mqtt/lib/server.js:17:16) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at new MQTTServer (/opt/iobroker/node_modules/iobroker.mqtt/lib/server.js:49:35) host.Smartazamba 2024-02-14 20:13:51.442 error Caught by controller[0]: at new RegExp (<anonymous>) host.Smartazamba 2024-02-14 20:13:51.441 error Caught by controller[0]: SyntaxError: Invalid regular expression: /*\.alarm\..*/: Nothing to repeat host.Smartazamba 2024-02-14 20:13:51.441 error Caught by controller[0]: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason: mqtt.0 2024-02-14 20:13:51.240 info terminating mqtt.0 2024-02-14 20:13:50.737 warn Terminated (UNCAUGHT_EXCEPTION): Without reason mqtt.0 2024-02-14 20:13:50.734 info terminating mqtt.0 2024-02-14 20:13:50.674 error Invalid regular expression: /*\.alarm\..*/: Nothing to repeat mqtt.0 2024-02-14 20:13:50.673 error SyntaxError: Invalid regular expression: /*\.alarm\..*/: Nothing to repeat at new RegExp (<anonymous>) at new MQTTServer (/opt/iobroker/node_modules/iobroker.mqtt/lib/server.js:49:35) at MQTTServer (/opt/iobroker/node_modules/iobroker.mqtt/lib/server.js:17:16) at MQTT.main (/opt/iobroker/node_modules/iobroker.mqtt/main.js:99:54) at MQTT.onReady (/opt/iobroker/node_modules/iobroker.mqtt/main.js:38:24) at MQTT.emit (node:events:517:28) at MQTT.emit (node:domain:489:12) at MQTT._callReadyHandler (/opt/iobroker/node_modules/@iobroker/js-controller-adapter/src/lib/adapter/adapter.ts:11928:18) at /opt/iobroker/node_modules/@iobroker/js-controller-adapter/src/lib/adapter/adapter.ts:11905:26 mqtt.0 2024-02-14 20:13:50.358 error unhandled promise rejection: Invalid regular expression: /*\.alarm\..*/: Nothing to repeat mqtt.0 2024-02-14 20:13:50.356 error Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). mqtt.0 2024-02-14 20:13:50.353 info Ignoring topic with pattern: *.alarm.* (RegExp: *\.alarm\..* und ^mqtt\.0\..*\.alarm\..*) mqtt.0 2024-02-14 20:13:50.173 warn No ioBroker changes will be published to the clients. Set the "publish" option in the adapter settings to subscribe for relevant changes. mqtt.0 2024-02-14 20:13:50.131 info starting. Version 5.2.0 in /opt/iobroker/node_modules/iobroker.mqtt, node: v18.19.0, js-controller: 5.0.17
-
Du könntest doch auch einzeln
mqtt.0.instar.all.alarm.*
mqtt.0.instar.cam_10.alarm.*
mqtt.0.instar.cam_11.alarm.*(jeweils duch <Enter> getrennt) angeben.
-
@marc-berg sagte in MQTT Topics ignorieren:
mqtt.0.instar.all.alarm.*
Da werden die Ojekte ebenfalls wieder angelegt.
-
@rushmed sagte in MQTT Topics ignorieren:
Da werden die Ojekte ebenfalls wieder angelegt.
und die Topics sind in einzelnen "Bubbles"?
Wenn ja, scheint es wohl ein Bug zu sein.
-
@marc-berg Danke, das hatte ich befürchtet.
Habe ein Issue aufgemacht.