This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
i am calling my MDB from MBean String mdbname="jboss.j2ee:service=EJB,plugin=invoker,binding=message-dr iven-bean,jndiName=local/ATTMessageProcessor"; String operation="startDelivery"; List list=MBeanServerFactory.findMBeanServer(null); Iterator itr=list.iterator(); MBeanServer server = (MBeanServer)itr.next(); ObjectName mbeanObjectName = new ObjectName(mdbname); server.invoke(mbeanObjectName, operation, null, null);
its also working from the JMX interface when i look into the jboss.j2ee code. but the only difference in the entry it shows is @14272226 after my JNDIName binding=message-driven-bean,jndiName=local/ATTMessageProcessor@14272226,plugin=invoker,service=EJB i refer to the wiki page http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMDB and found a note
NOTE: that the default MDB local-jndi-name is derived from the ejb-name with a random integer appended, so to have a usable MBean name requires an explicit local-jndi-name setting in the jboss.xml descriptor.
i added the local-jndi-name element in my jboss.xml as mentioned below.
but still getting the error InstanceNotFoundException.. note that i have added the entry of all queues being used in server/all/deploy-hasingelton/jms/jboss-destination-service.xml i feel it might be problem of JMS Specs. as i think 3.2.6 is compliance the JMS1.0 where as JBOSS4.0.5 have the support of JMS1.1 [ May 17, 2007: Message edited by: Bear Bibeault ]
<message-driven> <ejb-name>ATTMessageProcessor</ejb-name> <local-jndi-name>local/ATTMessageProcessor</local-jndi-name> <destination-jndi-name>queue/2_MessageProcessor</destination-jndi-name> </message-driven> if you notice.. i just prefix local-jndi-name with local... and problem resolved... but unfortunately i still not found this entry in jboss4.0 dtd. therefore i manually added.. this entry into the xdoclet .xdt template file.
i hope it will help out all ..
subject: Problem Invoking MDB from MBean in JBOSS4.0.5GA