11 Replies Latest reply on Sep 26, 2011 12:41 PM by Florian Gysin

    Deploy Error - Incomplete Deployment listing

    Sart Valcerou Newbie

      Hello! I'm new to JbossESB and i made HelloWorld app in Eclipse with JbossTools.

      MyJMSListenerAction

      package org.jboss.soa.esb.samples.quickstart.helloworld;
      
      import org.jboss.soa.esb.actions.AbstractActionLifecycle;
      import org.jboss.soa.esb.helpers.ConfigTree;
      import org.jboss.soa.esb.message.Message;
      
      public class MyJMSListenerAction extends AbstractActionLifecycle {
      
       protected ConfigTree _config;
      
       public MyJMSListenerAction(ConfigTree config) {
       _config = config;
       }
      
       public Message displayMessage(Message message) throws Exception {
      
       System.out.println("Body: " + message.getBody().get());
       return message;
      
       }
      
      }


      SendJMSMessage

      package org.jboss.soa.esb.samples.quickstart.helloworld.test;
      
      import java.util.Properties;
      
      import javax.jms.JMSException;
      import javax.jms.ObjectMessage;
      import javax.jms.Queue;
      import javax.jms.QueueConnection;
      import javax.jms.QueueConnectionFactory;
      import javax.jms.QueueSender;
      import javax.jms.QueueSession;
      import javax.naming.Context;
      import javax.naming.InitialContext;
      import javax.naming.NamingException;
      
      public class SendJMSMessage {
       QueueConnection conn;
       QueueSession session;
       Queue que;
      
      
       public void setupConnection() throws JMSException, NamingException
       {
       Properties properties1 = new Properties();
       properties1.put(Context.INITIAL_CONTEXT_FACTORY,
       "org.jnp.interfaces.NamingContextFactory");
       properties1.put(Context.URL_PKG_PREFIXES,
       "org.jboss.naming:org.jnp.interfaces");
       properties1.put(Context.PROVIDER_URL, "jnp://127.0.0.1:1099");
       InitialContext iniCtx = new InitialContext(properties1);
      
       Object tmp = iniCtx.lookup("ConnectionFactory");
       QueueConnectionFactory qcf = (QueueConnectionFactory) tmp;
       conn = qcf.createQueueConnection();
       que = (Queue) iniCtx.lookup("queue/quickstart_helloworld_Request_gw");
       session = conn.createQueueSession(false, QueueSession.AUTO_ACKNOWLEDGE);
       conn.start();
       System.out.println("Connection Started");
       }
      
       public void stop() throws JMSException
       {
       conn.stop();
       session.close();
       conn.close();
       }
      
       public void sendAMessage(String msg) throws JMSException {
      
       QueueSender send = session.createSender(que);
       ObjectMessage tm = session.createObjectMessage(msg);
      
       send.send(tm);
       send.close();
       }
      
      
       public static void main(String args[]) throws Exception
       {
       SendJMSMessage sm = new SendJMSMessage();
       sm.setupConnection();
       sm.sendAMessage(args[0]);
       sm.stop();
      
       }
      
      }


      jboss-esb

      <?xml version = "1.0" encoding = "UTF-8"?>
      <jbossesb xmlns="http://anonsvn.labs.jboss.com/labs/jbossesb/trunk/product/etc/schemas/xml/jbossesb-1.0.1.xsd" parameterReloadSecs="5">
       <providers>
       <jms-provider name="JBossMQ" connection-factory="ConnectionFactory">
       <jms-bus busid="quickstartGwChannel">
       <jms-message-filter
       dest-type="QUEUE"
       dest-name="queue/quickstart_helloworld_Request_gw"
       />
       </jms-bus>
       <jms-bus busid="quickstartEsbChannel">
       <jms-message-filter
       dest-type="QUEUE"
       dest-name="queue/quickstart_helloworld_Request_esb"
       />
       </jms-bus>
      
       </jms-provider>
       </providers>
      
       <services>
       <service
       category="FirstServiceESB"
       name="SimpleListener"
       description="Hello World">
       <listeners>
       <jms-listener name="JMS-Gateway"
       busidref="quickstartGwChannel"
       is-gateway="true"
       />
       <jms-listener name="helloWorld"
       busidref="quickstartEsbChannel"
       />
       </listeners>
       <actions mep="OneWay">
       <action name="action1"
       class="org.jboss.soa.esb.samples.quickstart.helloworld.MyJMSListenerAction"
       process="displayMessage"
       />
       </actions>
       </service>
       </services>
      
      </jbossesb>


      deployment.xml

      <jbossesb-deployment>
      <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_esb</depends>
       <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_gw</depends>
      </jbossesb-deployment>


      Exception

      11:31:04,765 ERROR [URLDeploymentScanner] Incomplete Deployment listing:
      
      --- MBeans waiting for other MBeans ---
      ObjectName: jboss.esb:deployment=helloworld.esb
       State: NOTYETINSTALLED
       I Depend On:
       jboss.esb:deployment=jbossesb.esb
       jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_esb
       jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_gw
      
      --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
      ObjectName: jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_esb
       State: NOTYETINSTALLED
       Depends On Me:
       jboss.esb:deployment=helloworld.esb


      Can anyone help me. Thanks in advance.


        • 1. Re: Deploy Error - Incomplete Deployment listing
          Sart Valcerou Newbie

          And i forgot to post jbm-queue-service.xml


          <?xml version="1.0" encoding="UTF-8"?>
          <server>
           <mbean code="org.jboss.jms.server.destination.QueueService"
           name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_esb"
           xmbean-dd="xmdesc/Queue-xmbean.xml">
           <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
           <depends>jboss.messaging:service=PostOffice</depends>
           </mbean>
           <mbean code="org.jboss.jms.server.destination.QueueService"
           name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_Request_gw"
           xmbean-dd="xmdesc/Queue-xmbean.xml">
           <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
           <depends>jboss.messaging:service=PostOffice</depends>
           </mbean>
          </server>


          • 2. Re: Deploy Error - Incomplete Deployment listing
            Daniel Bevenius Master

            Hi,

            are you able to run the helloworld quickstart using ant?

            I can't seen anything obvious wrong there. If you are able to run the quickstart from the commandline using ant then if you send me the .esb archive generated by JBoss Tools I'll take a look.

            Regards,

            /Daniel

            • 3. Re: Deploy Error - Incomplete Deployment listing
              Sart Valcerou Newbie

              Hello Daniel! Thank you for your reply.

              Yes, i'm able to run helloworld quickstart using ant.

              How do i send you .esb archive?

              • 4. Re: Deploy Error - Incomplete Deployment listing
                Daniel Bevenius Master

                sorry, you can get my email from my profile which is dbevenius@jboss.com

                • 5. Re: Deploy Error - Incomplete Deployment listing
                  Florian Gysin Newbie

                  I have the same problem as the OP.

                  Tried the helloworld example via the ant script (which worked) and then built it as an eclipse ESB project. The latter I exported as .esb and deployed it to the JBoss manuall which showed me the exact same error as above: both queues were 'unresolved' dependencies.

                   

                  Does someone have any thoughs on this? The config is basically exactly the same for the two projects. And I am able to deploy the eclipse project if the helloworld example via ant was already deployed - it seems that it then just uses the queues defined by the latter.

                  But I am not able to deploy an eclipse .esb project to JBoss manually...

                  • 6. Re: Deploy Error - Incomplete Deployment listing
                    Kit Plummer Newbie

                    Any resolution here?  I'm trying to deploy a simple ESB file produced by the JBossESB Tools. 

                     

                    Seems to not be able to honor the JMS stuff.

                    • 7. Re: Deploy Error - Incomplete Deployment listing
                      Florian Gysin Newbie

                      I found out what the problem is:

                      JBoss Tools do not correctly include the definitions of the queues in the .esb archive that is created. If created via JBoss Tools my .esb archive contains the classes and the META-INF folder containing deployment.xml, jboss-esb.xml and MANIFEST.MF.

                       

                      The queue definition on the other hand is not in there (jbm-queue-service.xml). That means that the queues are not properly defined when JBoss tries to set up the deployed ESB project, hence the error. You can either deploy the queues manually before by copying jbm-queue-service.xml into JBoss' deploy folder, or you can manually put them into the .esb archive. (In the archive 'root', where the META-INF folder is.)

                       

                      I don't know why JBoss Tools is not able to create the 'full' .esb archive. I guess that either this would require some additional config of the ESB project in Eclipse (but where?) or JBoss Tools are expecting a certain syntax/structure in the Eclipse ESB project that is not the same as the structure in the helloworld examples.

                       

                      For my part I solved the problem by writing an ant script that does the packaging of the .esb archive and the deployment for me. (Actually I just copied, adapted and simplified the ant script from the helloworld examples.) Not really a very beautiful solution, as it basically makes JBoss Tools worthless, but at least it works properly. And I this way I always know exactly what is done if an .esb archive is created and deployed; this can be handy to get a better understanding if you are new to JBoss.

                      For the case that anyone is interested I attached the ant script (called build.xml) to this post. Mind that you will have to adapt the properties (as the JBoss server home, etc.) to your local settings.

                      • 8. Re: Deploy Error - Incomplete Deployment listing
                        Kartik Gajjar Newbie

                        hi... this worked for me..

                         

                        Eclipse: helios

                        JBoss Tool: 3.2.0 M1 (jbosstools-3.2.0.M1.aggregate-Update-2010-07-20_01-43-30-H34.zip)

                         

                        After creating project

                        1. Create a folder new folder "mbean"

                        2. Select Project > Properties > Java Build Path > Source > Add Folde ...

                        - Select "mbean"

                        3. Create "jbm-queue-service.xml" under "mbean" folder

                        4. Finally "Run on Server"

                         

                        Hope this helps...

                        • 9. Re: Deploy Error - Incomplete Deployment listing
                          david_b Newbie

                          I had a similar issue deploying esb projects from within eclipse ganymede. I resolved the issue by moving the deployment and jbm-queue-service files to the correct location in the project

                           

                          • deployment.xml in the META-INF folder
                          • jbm-queue-service.xml in the root folder (the folder containing META-INF, called esbcontent for my project)

                           

                          I have the jBoss tools plugin for eclipse and created the project using New->Project->ESB Project.

                          • 10. Re: Deploy Error - Incomplete Deployment listing
                            Rohit Sampat Newbie

                            Thanks a lot Florian Gysin  your build script help me a lot... you have any idea or script which help us to build and deploy jbpm app.

                            • 11. Re: Deploy Error - Incomplete Deployment listing
                              Florian Gysin Newbie

                              Sorry, no, can't help you with that.