3 Replies Latest reply on Jul 21, 2010 4:08 AM by rainer knupfer

    Problem with e-mail connector/client jboss-esb

    rainer knupfer Newbie

      Hi,

      I need to listen to incoming mail-messages. For this i looked at following example:

      http://community.jboss.org/wiki/UsingMailInflowWithJBossESB

       

      My plattform is JBoss5.1 and JBossEsb4.8 (jdk1.6)

       

      Whenever i deploy the sample i get (see below)

      Any idea?

       

      Thx

       

       

       

       

      DEPLOYMENTS MISSING DEPENDENCIES:
        Deployment "jboss.esb.vfszip:/C:/Java-Packages/JBoss/JBossAS/jboss-5.1.0.GA/jboss-5.1.0.GA/server/default/deploy/Quick
      start_helloworld_mail.esb/" is missing the following dependencies:
          Dependency "<UNKNOWN jboss.esb.vfszip:/C:/Java-Packages/JBoss/JBossAS/jboss-5.1.0.GA/jboss-5.1.0.GA/server/default/d
      eploy/Quickstart_helloworld_mail.esb/>" (should be in state "PreInstall", but is actually in state "** UNRESOLVED Demand
      s 'jboss.jca:name='Quickstart_helloworld_mail.esb#mail-ra.rar',service=RARDeployment' **")

       

      DEPLOYMENTS IN ERROR:
        Deployment "<UNKNOWN jboss.esb.vfszip:/C:/Java-Packages/JBoss/JBossAS/jboss-5.1.0.GA/jboss-5.1.0.GA/server/default/dep
      loy/Quickstart_helloworld_mail.esb/>" is in error due to the following reason(s): ** UNRESOLVED Demands 'jboss.jca:name=
      'Quickstart_helloworld_mail.esb#mail-ra.rar',service=RARDeployment' **

       

              at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:993)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:939)
              at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:873)
              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.checkComplete(MainDeployerAdapter.java:

        • 1. Re: Problem with e-mail connector/client jboss-esb
          rainer knupfer Newbie

          there is also a similar example at http://community.jboss.org/wiki/UsingJCAWithJBossESB

          Although, same problem

           

          the deployment.xml has following line that creates the problem

          <depends>jboss.jca:name='Quickstart_helloworld_mail.esb#mail-ra.rar',service=RARDeployment</depends>

          • 2. Re: Problem with e-mail connector/client jboss-esb
            Daniel Bevenius Master

            Hi,

             

            can you try changing deployment.xml to this:

             

            <jbossesb-deployment>
              <depends>jboss.jca:name='mail-ra.rar',service=RARDeployment</depends>
              <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_helloworld_mail_Request_esb</depends>
            </jbossesb-deployment>
            

             

            And also update the jca-gateway element in jboss-esb.xml:

             

             <jca-gateway name="Mail-JCA-Gateway"
                adapter="mail-ra.rar"
                endpointClass="org.jboss.soa.esb.samples.quickstart.helloworld_mail.MailEndpoint"
                is-gateway="true" transacted="false">
                <activation-config>
                    <property name="mailServer" value="localhost"/>
                    <property name="storeProtocol" value="imap"/>
                    <property name="mailFolder" value="folder"/>
                    <property name="userName" value="user"/>
                    <property name="password" value="password"/>
                    <property name="pollingInterval" value="30000"/>
                </activation-config>
             </jca-gateway>
            
            Only the 'adapter' attribute has changed in the above snippet.
            Regards,
            /Daniel
            • 3. Re: Problem with e-mail connector/client jboss-esb
              rainer knupfer Newbie

              Thx, this error is not coming anymore!

               

              Although I can't still read the mails, my 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"

                                 jndi-URL="jnp://127.0.0.1:1099" jndi-context-factory="org.jnp.interfaces.NamingContextFactory"

                                 jndi-pkg-prefix="org.jboss.naming:org.jnp.interfaces">

                        <jms-bus busid="mailEsbChannel">

                            <jms-message-filter

                                dest-type="QUEUE"

                                dest-name="queue/mail_service_Request_esb"

                            />

                        </jms-bus>

                    </jms-provider>

                 </providers>

               

                 <services>

                   <service category="MailServiceESB" name="MailListener"

                       description="Hello World Mail Service">

                       <listeners>

                           <jca-gateway name="Mail-JCA-Gateway"

                               adapter="mail-ra.rar"

                               endpointClass="ch.swissgrid.bgm2.mail.MailEndpoint"

                               is-gateway="true" transacted="false">

                               <activation-config>

                                   <property name="mailServer" value="smtp.gmail.com"/>

                                   <property name="storeProtocol" value="pop3"/>

                                   <property name="mailFolder" value="*"/>

                                   <property name="userName" value="myUser"/>

                                   <property name="password" value="myPassword"/>

                                   <property name="pollingInterval" value="5000"/>

                                  <property name="port" value="465"/>

                                  <property name="starttls" value="true"/>

                               </activation-config>

                           </jca-gateway>

                           <jms-listener name="JMS-ESBListener"

                                        busidref="mailEsbChannel"

                                        maxThreads="1"

                                  />

                       </listeners>

                       <actions>

                              <action name="action1"

                                  class="ch.swissgrid.bgm2.mail.MyMailListenerAction"

                                  process="displayMessage"

                                  />

                               <action name="action2">

                                 <property name="printfull" value="true"/>

                               </action>

                       </actions>

                   </service>

                 </services>

               

              </jbossesb>