Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-17274

camel-spring-boot - Using war packaging cannot load XML routes via routes collector

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 3.8.0, 3.9.0, 3.10.0, 3.11.0, 3.12.0, 3.13.0
    • 3.14.0
    • camel-spring-boot
    • None
    • Unknown

    Description

      A regression is caused by CAMEL-15560 by removal of collectXmlRoutesFromDirectory methods, which overrode default method to use spring's application context, but no equivalent was made in replacement.

      To fix this is seems simply a new implementation of new equivalent method, re-introducing loading resource by the spring applicationContext.

      Unfortunately it seems this is only seen/issue up once a fully packaged springboot jar/war is created and run, and route xml's fail to load, as such very hard to unit test, and like wise no pre-existing tests clearly for old behaviour either, thus it broke.

      related to: https://stackoverflow.com/questions/68065987/apache-camel-routes-in-xml-not-loaded-in-spring-boot/

       

      Attached is a sample extracted application demonstrating the issue, see its readme. The zipped app is currently working using 3.7.6 but you will note on changing camel dependency to 3.8.0 the routes do not load, nor start.

       

      A PR will be linked to this ticket that fixes this issue.

      Attachments

        1. springboot-camel.zip
          24 kB
          Michael Andre Pearce

        Issue Links

          Activity

            People

              davsclaus Claus Ibsen
              michael.andre.pearce Michael Andre Pearce
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: