You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2009/03/09 14:39:40 UTC

[jira] Updated: (CAMEL-1441) camel-file : java.lang.StringIndexOutOfBoundsException: String index out of range: 1

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

Claus Ibsen updated CAMEL-1441:
-------------------------------

    Fix Version/s: 2.0.0
                   2.0-M1

> camel-file : java.lang.StringIndexOutOfBoundsException: String index out of range: 1
> ------------------------------------------------------------------------------------
>
>                 Key: CAMEL-1441
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1441
>             Project: Apache Camel
>          Issue Type: Bug
>    Affects Versions: 2.0-M1
>         Environment: Camel 2.0SNAPSHOT (09/03/2009)
>            Reporter: Charles Moulliard
>            Assignee: Claus Ibsen
>             Fix For: 2.0-M1, 2.0.0
>
>
> The following spring DSL routes generates an error :  
> 	<camelContext trace="true" xmlns="http://camel.apache.org/schema/osgi">
> 		<camel:package>org.apache.camel.example.reportincident.routing</camel:package>
> 		<!-- File route  -->
> 		<camel:route>
> 			<camel:from	uri="file://d:/temp/data/?move=d:/temp/done/${file:name}" />
> 			<camel:unmarshal ref="bindyDataformat" />
> 			<camel:to uri="bean:csv" />
> 			<camel:to uri="activemq:queue:in" />
> 		</camel:route>
> 		
> 		<camel:route>
> 			<camel:from uri="activemq:queue:in" />
> 			<camel:from	uri="file://d:/temp/data/queue" />
> 		</camel:route>
> 2009-03-09 14:23:09,968 WARN  ScheduledPollConsumer - An exception occurred while polling: Endpoint[file://d:/temp/data/?move=d:/temp/done/${file:name}]: String index out of range: 1 
> java.lang.StringIndexOutOfBoundsException: String index out of range: 1
> 	at java.lang.String.charAt(String.java:687)
> 	at java.util.regex.Matcher.appendReplacement(Matcher.java:703)
> 	at java.util.regex.Matcher.replaceAll(Matcher.java:813)
> 	at java.lang.String.replaceAll(String.java:2190)
> 	at org.apache.camel.component.file.GenericFile.normalizePathToProtocol(GenericFile.java:238)
> 	at org.apache.camel.component.file.GenericFile.setEndpointPath(GenericFile.java:223)
> 	at org.apache.camel.component.file.FileConsumer.asGenericFile(FileConsumer.java:103)
> 	at org.apache.camel.component.file.FileConsumer.pollDirectory(FileConsumer.java:56)
> 	at org.apache.camel.component.file.GenericFileConsumer.poll(GenericFileConsumer.java:66)
> 	at org.apache.camel.impl.ScheduledPollConsumer.run(ScheduledPollConsumer.java:66)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
> 	at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
> 	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
> 	at java.lang.Thread.run(Thread.java:619)

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