Uploaded image for project: 'ServiceMix 4'
  1. ServiceMix 4
  2. SMX4-879

jbi-maven-plugin generates jbi.xml with incorrect "component-name", resulting in failed deployment

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Not A Problem
    • 4.3.0
    • None
    • Examples
    • None
      • Linux Ubuntu on Core2Duo CPU
      • ServiceMix v4.3.0
      • jbi-maven-plugin : v4.4
      • Maven v2.2.1

    Description

      After adding a dependency in the "cxf-wsdl-first" sample, it fails to deploy.

      Steps to reproduce :
      rm -r ~/.m2/repository/org/apache/servicemix/examples/cxf-wsdl-first
      cd apache-servicemix-4.3.0/examples/cxf-wsdl-first/
      mvn jbi:generate-jbi-service-assembly-descriptor # output in mvn_jbi_good.txt
      cat wsdl-first-cxf-sa/target/classes/META-INF/jbi.xml | grep component-name #(see jbi_good.xml)
      vi wsdl-first-cxfse-su/pom.xml
      #add dependency "servicemix-http" after "servicemix-cxf-se" (in second position)
      mvn jbi:generate-jbi-service-assembly-descriptor # output in mvn_jbi_bad.txt, after several runs
      cat wsdl-first-cxf-sa/target/classes/META-INF/jbi.xml | grep component-name #(see jbi_bad.xml)

      The bug may not occur consistently on every run, several runs may be needed.
      After a few retries, the "component-name" tag in jbi.xml becomes "servicemix-http" instead of "servicemix-cxf-se"

      Workaround : add the dependency "servicemix-http" in last position.

      At deployment, the following error is displayed (see error.log for full error):

      Configuration problem: Bean class [org.apache.servicemix.cxfse.CxfSeEndpoint] not found
      Offending resource: file [/data/software/apache-servicemix-4.3.0/data/jbi/wsdl-first-cxf-sa/sus/wsdl-first-cxfse-su/xbean.xml]
      Bean 'CXFSE-Endpoint'; nested exception is java.lang.ClassNotFoundException: org.apache.servicemix.cxfse.CxfSeEndpoint in classloader org.apache.xbean.spring.context.FileSystemXmlApplicationContext@13077ec

      P.S. : With no experience in ServiceMix yet, it took me 3 days to figure out why the slightly modified sample was not working properly.

      Attachments

        1. jbi_bad.xml
          1 kB
          metatech
        2. jbi_good.xml
          1 kB
          metatech
        3. mvn_jbi_bad.txt
          0.9 kB
          metatech
        4. mvn_jbi_good.txt
          1.0 kB
          metatech
        5. error.log
          11 kB
          metatech

        Activity

          People

            ffang Freeman Yue Fang
            metatech metatech
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: