Tango synoptic viewer laggy

Hi all,

In my project I need to display a synoptic of about 100 devices with about 200 attributes, also with many Dynamic Objects (e.g. lines and shapes' foreground colors).

So I have been using the tango's java built-in synoptic viewer (triggered inside Jdraw or seperately as fr.esrf.tangoatk.widget.jdraw.SimpleSynopticAppli), so far so good.

The problem is that I am running the viewer together with several Taurus Gui applications, all on a Raspberry Pi 4, and while the Taurus Gui programs are very smooth in updating the attribute values (usually < 1 second), the SimpleSynopticAppli is very laggy in updating changes of attribute (usually from 3 to 10 seconds which makes it not up to the requirement of my application).

For most of the attributes, I set a change event in the device_init() function of the device server, and push changes in their read and write functions.

In the Diagnostics menu of the synoptic viewer, I can see that the viewer seems to do both polling and event listening, and the update period is set at the default 1000 milliseconds (can't be lowered).

How can I improve? Could anyone share his experience?

Edited 2 months ago
Strangely, disabling events altogether in Device Servers make the viewer update in about 1 second or so.
For example, for a label associated with a device state, in pytango commenting out the following code so that the viewer has to poll the device state, and that makes the viewer update the label faster than pushing events for the listener of the viewer.
    def init_device(self):
#self.set_change_event('State', True, True)

def turn_on(self):
#self.push_change_event('State', DevState.ON)

Any idea why?
Edited 2 months ago
Digging further, I can see that the viewer doesn't really listen to the events emitted by the device servers.
In the View->Error History of the viewer, I can see that it lists a lot of ERROR like this:
main/inverter/ivt01/frequency No heartbeat from dserver/inverter/1

And this is the java stack error info:

class fr.esrf.tangoatk.core.AttributeReadException
java.security.AccessController.doPrivileged(Native Method)

It's just like the viewer is having trouble connecting to tango, but it's not the case, since polling still working just fine.
This is quite weird because my TaurusForm client running on the same machine at the same time got the events just right.
Could you try first with the last ATK release (9.3.22).
I fixed a bug recently concerning forwarded attributes. If you have forwarded attribute it may explains the issue.
It seems strange that the ATK client do both polling and event ? Could you post a screenshot of the Diagnostic windows ?
Did you try without Tango polling and by calling
set_change_event(true, false);
in your server init function ?
Dear Jean-Luc,

Thanks so much for your kind input.
I think I have just solved the problem, it has to do with host name.

Say I am using a local system with the host name raspberry. Naturally, since everything is local, I declare the TANGO_HOST environment variable in /etc/tangorc as:

And I declare in /etc/hosts:    raspberry localhost

Everything (tangodb, jive, taurus clients ect.) works fine, except for the java synoptic viewer.
I found that is the real IpV4 address that the Wifi hotspot assigns to my host, so I tried changing the declaration in /etc/hosts:    raspberry localhost

So I think I am supposed to set a static Ip for my host (?)
Ok, that's nice if you manage to solve the issue :)
Jive is not using event and the network problem may come from java zmq when using event…
Register or login to create to post a reply.