Open ramsoftmarc opened 2 hours ago
The method signature was changed. https://github.com/nextgenhealthcare/connect/blob/e0b3a89a30b576a5ef091ec7023df80e6da068ee/server/src/com/mirth/connect/plugins/dashboardstatus/DashboardConnectorEventListener.java#L43-L45
var states = connectorListener.getConnectorStateMap("");
should get you what you want but untested on my end.
That seems to work, thank you.
Previously on Mirth 3.4.2, I was able to get the state of a connector listener using this code:
var defController = Packages.com.mirth.connect.server.controllers.DefaultExtensionController.create(); var monitor = defController.getServicePlugins().get(com.mirth.connect.plugins.dashboardstatus.DashboardConnectorStatusServletInterface.PLUGIN_POINT); connectorListener = monitor.getConnectorListener(); var states = connectorListener.getConnectorStateMap(); thisState = states.get(myChannelId + '_0')[1];
Using Mirth 4.4.2 I'm getting this error:
Can't find method com.mirth.connect.plugins.dashboardstatus.DashboardConnectorEventListener.getConnectorStateMap().
Was this removed or is there another function call to get the state?
I'm Using openJDK v15