camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Taylor (JIRA)" <j...@apache.org>
Subject [jira] Reopened: (CAMEL-1974) Package scanning cannot be used for folders containing special characters
Date Wed, 16 Sep 2009 12:59:12 GMT

     [ https://issues.apache.org/activemq/browse/CAMEL-1974?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

John Taylor reopened CAMEL-1974:
--------------------------------


Discussion at http://www.nabble.com/Fix-for-CAMEL-1974-seems-to-cause-problem-on-Windows-td25458041s22882.html

This fix causes a problem on windows with spaces in the path.

Trace:
{noformat}
 classloader: java.net.URLClassLoader@189acb5
[pache.camel.spring.Main.main()] efaultPackageScanClassResolver TRACE URL from classloader:
jar:file:/C:/Documents and Settings/TaylorJohn.
GS/.m2/repository/org/apache/camel/camel-core/2.1-SNAPSHOT/camel-core-2.1-SNAPSHOT.jar!/org/apache/camel/component/file/
[pache.camel.spring.Main.main()] efaultPackageScanClassResolver TRACE Decoded urlPath: file:/C:/Documents
and Settings/TaylorJohn.SGS/.m2/r
pository/org/apache/camel/camel-core/2.1-SNAPSHOT/camel-core-2.1-SNAPSHOT.jar!/org/apache/camel/component/file/
[pache.camel.spring.Main.main()] efaultPackageScanClassResolver WARN  Could not read entries
in url: jar:file:/C:/Documents and Settings/Ta
lorJohn.SGS/.m2/repository/org/apache/camel/camel-core/2.1-SNAPSHOT/camel-core-2.1-SNAPSHOT.jar!/org/apache/camel/component/file/
java.net.URISyntaxException: Illegal character in path at index 18: file:/C:/Documents and
Settings/TaylorJohn.SGS/.m2/repository/org/apach
/camel/camel-core/2.1-SNAPSHOT/camel-core-2.1-SNAPSHOT.jar!/org/apache/camel/component/file/
        at java.net.URI$Parser.fail(URI.java:2809)
        at java.net.URI$Parser.checkChars(URI.java:2982)
        at java.net.URI$Parser.parseHierarchical(URI.java:3066)
        at java.net.URI$Parser.parse(URI.java:3014)
        at java.net.URI.<init>(URI.java:578)
        at org.apache.camel.impl.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:222)
        at org.apache.camel.impl.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:180)
        at org.apache.camel.impl.DefaultPackageScanClassResolver.findAnnotated(DefaultPackageScanClassResolver.java:100)
        at org.apache.camel.impl.converter.AnnotationTypeConverterLoader.load(AnnotationTypeConverterLoader.java:62)
        at org.apache.camel.impl.converter.DefaultTypeConverter.checkLoaded(DefaultTypeConverter.java:359)
        at org.apache.camel.impl.converter.DefaultTypeConverter.doConvertTo(DefaultTypeConverter.java:153)
{noformat}




> Package scanning cannot be used for folders containing special characters
> -------------------------------------------------------------------------
>
>                 Key: CAMEL-1974
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1974
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 2.0.0
>         Environment: macbook pro, osx leopard
>            Reporter: Fabio Marinelli
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.1.0
>
>         Attachments: DefaultPackageScanClassResolverTest.diff, package+scan+test.jar
>
>
> I found out this problem developing a test case with cargo on my macbook. Temporary directory
on leopard is something like (/private/var/folders/is/ispMf0ylEtCIOP8skg0va++++TI/-Tmp-) and
cargo deploys the embedded container there.
> Problem happens when camel tries to find converters by using DefaultPackageScanClassResolver
class; it converts the temporary path, using URLDecoder, in the invalid path "/private/var/folders/is/ispMf0ylEtCIOP8skg0va
   TI/-Tmp-"
> You can reproduce this bug by patching the DefaultPackageScanClassResolverTest and adding
the following resource file, that I'm going to attach to this issue.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message