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

Unable to load Schematron XSLT templates on windows

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.18.3, 2.19.0
    • Fix Version/s: 2.17.7, 2.18.4, 2.19.0
    • Component/s: camel-schematron
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      Similar to CAMEL-8504. ClassPathURIResolver does:

      InputStream stream = ClassPathURIResolver.class.getClassLoader()      
          .getResourceAsStream(rulesDir.concat(File.separator).concat(href));
      

      Depending on the ClassLoader implementation, platform dependent paths for resource lookups are not guaranteed to work (which arguably could be considered a bug in the ClassLoader impl).

      Looking at the git history, it seems this code has swapped between using File.separator and "/" a few times now. However, I see no clear reason why we need to use File.separator in the resource lookup. "/" should work perfectly fine in all cases.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jamesnetherton James Netherton
                Reporter:
                jamesnetherton James Netherton
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: