Dashboard not responsive

Hello all,

I would like to display responsive numbers on a dashboard. Nodered receive mqtt & zmq streams at 5Hz.

I have created a dashboard with 20 text nodes. 4 clients open this dashboard and look at the numbers. If a fifth client opens the same dashboard, this fifth, first and fourth dashboard start to be slow, there is 10 seconds delay on the numbers. Also, the second and third customer may still receive responsive numbers on their dashboard. If the fifth client closes his dashboard, the first and fourth clients get responsive numbers back after about 10 seconds.

Nodered runs on a raspberry, the total CPU load including Nodered is about 20%. Client can run on ethernet or wifi tablet. There no network issue. There only mqtt, zmq buffer-parser and texts nodes on in the flows.json, it is a light flows.

I tried on a more powerful computer that only runs nodered, there is the same behavior.

have you ever noticed this behavior? Is there option to avoid this delay?

Hi,

Likely the total number of items being displayed on the Dashboard is too high. It really only works well with several hundred or fewer datapoints. Text items? Not charts? You might be ok.

Also - 5Hz. update frequency is pretty aggressive - is there a way to coalesce the data into smaller, less-frequent 'chunks' to reduce frequency?

Four clients work fine, but then adding one more client kills performance... hmmm. What about memory consumption?

What version of Node, Node-RED & Dashboard are you running?

Cheers,

Paul

If you slow the data rate to 1 Hz does it make a difference?

The processor load is about 20% (the one running nodered), and the other about 5%. RAM is about 400M for 8G.

I have no graphics and only 25 text elements. The size of the elements is different. Some of them are bigger than others. They cover the whole dashboard.

I reduce the mqtt & zmq stream to 2Hz, this is the minimum frequency I can apply to get dynamic numbers. I use nr: 3.0.2 and dashboard: 3.1.7

What is the reason for this delay? The tablet browser is too slow, or nodred can't track multiple clients at 3Hz?

I suggested allowing it in order to help diagnose the problem.

I don't know how multiple clients are handled in the dashboard. @dceejay, with multiple clients do the websocket connections run in parallel or in series?

Each client has its own web socket. And as this is a nodejs application they are all running on the same thread/event loop so will be handled in series.

I don't know much about websockets, so does that mean that if you connect a number of slow devices (five in this case) that it might overload the comms?

Highly unlikely given how well nodejs performs in general. Easy to test by opening a set of browser windows.

I also don't know much about web socket, serials means that nodered sends the data to the websocket client one by one, otherwise parrallele it's like a broadcast to all the clients? (which is less resources for nodered).

That is what I thought, but I am having difficulty explaining the symptom seen here.

I can only guess there is some messaging loop in there somewhere.

There are only text elements on the dashboard, but when more than four clients are connected it slows down dramatically, apparently. The CPU does not seem to be overloaded, and running on a more powerful computer does not help. That suggests it is something to do with the clients.

Simple test with 9 separate browser windows updating 10 times a second...
(actually it is smoother than the video capture software shows.)
CLEt4zSV8k

The system here has 25 UI nodes, though you wouldn't think that would make much difference.

@dceejay tanks for the answer, There's no loop in the flows. It is quite simple, mqtt node, limit node (to reduce the rate to 2hz) buffer parser to decode numbers, and straight forward to 25 text nodes. There also a pull zmq node at 3hz to text nodes.

@dceejay as @Colin said could you please add 24 up text node and try again to see if you can reproduce my problem
Thanks a lot to look at my issue.

It would be simpler if you shared your exact flow.

I will do