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

camel-spring-boot - XPath language configuring saxon=true seems to not work

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 4.0.0
    • 4.0.2, 4.1.0
    • camel-saxon
    • None
    • Unknown

    Description

      I have a Spring Boot project, and I'm trying to set Saxon as the default implementation for the XPath language.

      Per the [documentation](https://camel.apache.org/components/4.0.x/languages/xpath-language.html#_sb_option_camel_language_xpath_saxon), you can set the property {}camel.language.xpath.saxon{} to true to enable it.

      However, the Spring Boot runtime configures the language by doing a reflective copy of the properties from the configuration to the language instance object. It happens that the property names are different: [XPathLanguage.java](https://github.com/apache/camel/blob/main/components/camel-xpath/src/main/java/org/apache/camel/language/xpath/XPathLanguage.java#L100-L106}) uses "useSaxon" whereas [XPathLanguageConfiguration.java](https://github.com/apache/camel-spring-boot/blob/main/components-starter/camel-xpath-starter/src/main/java/org/apache/camel/language/xpath/springboot/XPathLanguageConfiguration.java) uses "saxon".

      There's an unit test covering this setting, but it is using ["useSaxon"](https://github.com/apache/camel/blob/main/components/camel-saxon/src/test/resources/org/apache/camel/language/xpath/XPathLanguageDefaultSettingsTest.xml#L29-L31).

      Attachments

        Issue Links

          Activity

            People

              davsclaus Claus Ibsen
              ammachado Adriano Machado
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: