Sensor value and Battery Value for device as separate topics

Posted on
Sun Dec 06, 2020 7:47 pm
FlyingDiver offline
User avatar
Posts: 7189
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Sensor value and Battery Value for device as separate to

The End term is there to NOT match if there are still components of the topic that haven't been used yet. It's to keep a topic with extra terms after from matching on a partial topic.

Which you use it entirely up to you. I just put in a lot of tools to give you the most flexibility. OTOH, your best efficiency (least extra processing time) is when the message-type defines a specific sensor type that only matches one Shim definition. If you use less triggers, with a generic message-type, then ALL the Shim devices that use that message-type have to be called to see if the message matches (Unique ID).

In your case, since those are different Shim types, you should use different triggers with different message-types.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Thu Dec 10, 2020 8:50 am
Ramias offline
Posts: 272
Joined: Nov 24, 2015

Re: Sensor value and Battery Value for device as separate to

Here's another follow up question:

I have a whole bunch of these in my logs:

Code: Select all
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 26 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 26 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 27 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 28 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 29 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 30 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 31 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 32 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 33 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 34 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 35 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 36 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 36 messages pending


Is this because I have a message that isn't matching on a shim? Any way I can see what the message(s) is/are?

Thanks

Posted on
Thu Dec 10, 2020 8:56 am
FlyingDiver offline
User avatar
Posts: 7189
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Sensor value and Battery Value for device as separate to

That mean you have a trigger queuing messages with the type "##RingAlarm##" that doesn't have a Shim using the message. So they're piling up waiting for some shim device to request them.

You need to disable that trigger until you have a Shim ready to use it.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Thu Dec 10, 2020 4:08 pm
Ramias offline
Posts: 272
Joined: Nov 24, 2015

Re: Sensor value and Battery Value for device as separate to

I was missing a Shim.

I now have 16 topics (devices) under /ring/accountGUID/alarm/#.

Logs show this ever 5 minutes:
Code: Select all
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 11 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 12 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 13 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 14 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 15 messages pending
   MQTT Connector Warning          Queue for message type '##RingAlarm##' has 16 messages pending


Sometimes it is 15 messages. Could this just be a lag issue if all 16 topics update at once and the plugin queues them before the Shim can process them?

Good thing is the count has not been higher than 16 for the past several hours.

Posted on
Thu Dec 10, 2020 4:11 pm
FlyingDiver offline
User avatar
Posts: 7189
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Sensor value and Battery Value for device as separate to

Yeah, that just means a slew came in at once and slowly get processed. I specifically designed the system to queue that way so that messages didn't get lost if a bunch of MQTT traffic came in faster than the inter-plugin system could process them.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Thu Dec 10, 2020 4:13 pm
FlyingDiver offline
User avatar
Posts: 7189
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Sensor value and Battery Value for device as separate to

It only shows the entry in the log when there's more than 10 messages in the queue.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Dec 11, 2020 10:04 pm
Ramias offline
Posts: 272
Joined: Nov 24, 2015

Re: Sensor value and Battery Value for device as separate to

cool. I thought about changing line 942 to make it a debug event instead of a warning. But figured I may want the warning if they get super high. So I changed line 941 to 25 -- just a few higher than my current number of Shim devices.

Posted on
Fri Dec 11, 2020 10:22 pm
FlyingDiver offline
User avatar
Posts: 7189
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Sensor value and Battery Value for device as separate to

Ramias wrote:
cool. I thought about changing line 942 to make it a debug event instead of a warning. But figured I may want the warning if they get super high. So I changed line 941 to 25 -- just a few higher than my current number of Shim devices.


Open an issue on GitHub and I'll make it configurable. ;)

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Who is online

Users browsing this forum: No registered users and 3 guests

cron