0 Replies Latest reply: Sep 26, 2012 9:22 AM by 964567 RSS

    Monitoring JMS Queue WLST - java.lang.RuntimeException: javax.management.In

    964567
      Hello everybody,

      I'm trying to monitoring JMS queues, as follows:

      servers = domainRuntimeService.getServerRuntimes()

      for server in servers:
      jmsRuntime = server.getJMSRuntime();
      jmsServers = jmsRuntime.getJMSServers();

      for jmsServer in jmsServers:
      destinations = jmsServer.getDestinations();

      for destination in destinations:
      modulo =(destination.getName()).split('!')[0]


      if (modulo == "sync" or modulo == "async"):
      name = destination.getName();
      pend =int(destination.getMessagesPendingCount())

      if pend > 0:
      print '%25s | %50s | %10s' % (data,name,pend)




      The script works but when the queue creates a Temporary Queue, my script generates the following exception and abort my flow.

      java.lang.RuntimeException: javax.management.InstanceNotFoundException: com.bea:ServerRuntime=SERVER_04,Name=SERVER_04_JMSServer!SERVER_04_JMSServer.TemporaryQueue421284,Type=JMSDestinationRuntime,JMSServerRuntime=SERVER_04_JMSServer


      Is there anyway that I ignore the Temporary Queue?