web stats
How to getting 'Polling' status of a channel - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 08-28-2015, 05:37 AM
C3G C3G is offline
Mirth Newb
 
Join Date: Jun 2015
Posts: 13
C3G is on a distinguished road
Default How to getting 'Polling' event of a channel

Good morning Gents,

I need your lights. Does anyone know how to get the event "Polling" of a connector ? Currently I can see this information in Dashboard Menu - Connection Log Tabulation - Connector Info Field.

This information seems not be in the Database of Mirth, so I presume that information is somewhere else, but I don't know where looking. I also looked at JavaScript Class of Mirth to get this, but I didn't find anything.

Just in case, my purpose is to monitor each time that a channel run.

Any ideas ??? Thank you in advance for your help.

Regards

Last edited by C3G; 08-28-2015 at 05:43 AM. Reason: Wrong Title - Sorry
Reply With Quote
  #2  
Old 09-28-2015, 05:31 AM
C3G C3G is offline
Mirth Newb
 
Join Date: Jun 2015
Posts: 13
C3G is on a distinguished road
Default Help

Up !
Reply With Quote
  #3  
Old 09-29-2015, 05:53 AM
mcalKno mcalKno is offline
 
Join Date: Apr 2015
Location: Pennsylvania
Posts: 247
mcalKno is on a distinguished road
Default

Could you just have a transformer write the date/time to a log file or logger or global map? The transformer would fire when the poll happens. What is the full use case?

Last edited by mcalKno; 09-29-2015 at 05:56 AM.
Reply With Quote
  #4  
Old 09-30-2015, 12:46 AM
C3G C3G is offline
Mirth Newb
 
Join Date: Jun 2015
Posts: 13
C3G is on a distinguished road
Default

Hi mcalKno,

First, thank you for your reply.

What I want is to know each time that a channel has running (or get simply the last run by channel).

Sometimes, some channel has no source file, so no message to proceed and that's why I cannot use the transformer.

If I want to have a check on the last run of our channels is because sometimes, one or multiple channel stop working while that all are OK and status on ready. Currently, my work arround is to stop and restart the channel in the dashboard. But to be proactive, I need to know if it run or no

If you have any idea or solution will be very helpful.

Thank you in advance......... Rgds
Reply With Quote
  #5  
Old 10-05-2015, 05:48 AM
C3G C3G is offline
Mirth Newb
 
Join Date: Jun 2015
Posts: 13
C3G is on a distinguished road
Default

Hi Everybody,

Now with the following code, I can get the last status of the channel, but I need also to get the timestamp that correspond. How can I get it ?

Your help will be very appreciated....

Rgds

Code:
var defController = Packages.com.mirth.connect.server.controllers.DefaultExtensionController.create();
var monitor = defController.getServicePlugins().get(Packages.com.mirth.connect.plugins.dashboardstatus.DashboardConnectorStatusMonitor.PLUGINPOINT);
var states = monitor.invoke('getStates', null, null);
status = states.get('channelID' + '_0')[1];
Reply With Quote
  #6  
Old 10-12-2015, 10:40 PM
C3G C3G is offline
Mirth Newb
 
Join Date: Jun 2015
Posts: 13
C3G is on a distinguished road
Default Help Please...

Up !
Reply With Quote
Reply

Tags
connection, connector, event, log, polling

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 07:38 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Mirth Corporation