commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bela Hullar (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (VFS-510) moveTo fails with SFTPFileObject if CacheStrategy.ON_CALL is set
Date Mon, 20 Jan 2014 12:41:20 GMT

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

Bela Hullar updated VFS-510:
----------------------------

    Description: 
calling moveTo on SFTPFileObject cause the following error:
java.lang.ClassCastException: org.apache.commons.vfs2.cache.OnCallRefreshFileObject cannot
be cast to org.apache.commons.vfs2.provider.sftp.SftpFileObject
	at org.apache.commons.vfs2.provider.sftp.SftpFileObject.doRename(SftpFileObject.java:289)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.provider.AbstractFileObject.moveTo(AbstractFileObject.java:1102)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.impl.DecoratedFileObject.moveTo(DecoratedFileObject.java:155)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.cache.OnCallRefreshFileObject.moveTo(OnCallRefreshFileObject.java:158)
~[commons-vfs2-2.0.jar:2.0]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.handleGeneratedFiles(RetryableTask.java:104)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.access$000(RetryableTask.java:24)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask$1.execute(RetryableTask.java:73) ~[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.util.errorrecovery.ExponentialBackOff.execute(ExponentialBackOff.java:48)
~[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.changeState(RetryableTask.java:69)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.TaskImpl.validate(TaskImpl.java:76) [bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.queues.SubmissionQueueEntry.run(SubmissionQueueEntry.java:44)
[bee.jar:1.0-SNAPSHOT]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [na:1.7.0_05]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [na:1.7.0_05]
	at java.lang.Thread.run(Thread.java:722) [na:1.7.0_05]

As with CacheStrategy.ON_CALL the file objects are wrapped into a decorator
the following line in SFTPFileObject causes the problem (SftpFileObject.java:289):
channel.rename(relPath, ((SftpFileObject) newfile).relPath);


  was:
calling moveTo on SFTPFileObject cause the following error:
java.lang.ClassCastException: org.apache.commons.vfs2.cache.OnCallRefreshFileObject cannot
be cast to org.apache.commons.vfs2.provider.sftp.SftpFileObject
	at org.apache.commons.vfs2.provider.sftp.SftpFileObject.doRename(SftpFileObject.java:289)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.provider.AbstractFileObject.moveTo(AbstractFileObject.java:1102)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.impl.DecoratedFileObject.moveTo(DecoratedFileObject.java:155)
~[commons-vfs2-2.0.jar:2.0]
	at org.apache.commons.vfs2.cache.OnCallRefreshFileObject.moveTo(OnCallRefreshFileObject.java:158)
~[commons-vfs2-2.0.jar:2.0]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.handleGeneratedFiles(RetryableTask.java:104)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.access$000(RetryableTask.java:24)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask$1.execute(RetryableTask.java:73) ~[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.util.errorrecovery.ExponentialBackOff.execute(ExponentialBackOff.java:48)
~[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.changeState(RetryableTask.java:69)
[bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.tasks.TaskImpl.validate(TaskImpl.java:76) [bee.jar:1.0-SNAPSHOT]
	at ch.systemsx.bee.workflowmanager.queues.SubmissionQueueEntry.run(SubmissionQueueEntry.java:44)
[bee.jar:1.0-SNAPSHOT]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [na:1.7.0_05]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [na:1.7.0_05]
	at java.lang.Thread.run(Thread.java:722) [na:1.7.0_05]

As with CacheStrategy.ON_CALL the file objects wrapped into a decorator
the following line in SFTPFileObject causes the problem (SftpFileObject.java:289):
channel.rename(relPath, ((SftpFileObject) newfile).relPath);



> moveTo fails with SFTPFileObject if CacheStrategy.ON_CALL is set
> ----------------------------------------------------------------
>
>                 Key: VFS-510
>                 URL: https://issues.apache.org/jira/browse/VFS-510
>             Project: Commons VFS
>          Issue Type: Bug
>    Affects Versions: 2.0
>            Reporter: Bela Hullar
>
> calling moveTo on SFTPFileObject cause the following error:
> java.lang.ClassCastException: org.apache.commons.vfs2.cache.OnCallRefreshFileObject cannot
be cast to org.apache.commons.vfs2.provider.sftp.SftpFileObject
> 	at org.apache.commons.vfs2.provider.sftp.SftpFileObject.doRename(SftpFileObject.java:289)
~[commons-vfs2-2.0.jar:2.0]
> 	at org.apache.commons.vfs2.provider.AbstractFileObject.moveTo(AbstractFileObject.java:1102)
~[commons-vfs2-2.0.jar:2.0]
> 	at org.apache.commons.vfs2.impl.DecoratedFileObject.moveTo(DecoratedFileObject.java:155)
~[commons-vfs2-2.0.jar:2.0]
> 	at org.apache.commons.vfs2.cache.OnCallRefreshFileObject.moveTo(OnCallRefreshFileObject.java:158)
~[commons-vfs2-2.0.jar:2.0]
> 	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.handleGeneratedFiles(RetryableTask.java:104)
[bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.access$000(RetryableTask.java:24)
[bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask$1.execute(RetryableTask.java:73)
~[bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.util.errorrecovery.ExponentialBackOff.execute(ExponentialBackOff.java:48)
~[bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.workflowmanager.tasks.RetryableTask.changeState(RetryableTask.java:69)
[bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.workflowmanager.tasks.TaskImpl.validate(TaskImpl.java:76) [bee.jar:1.0-SNAPSHOT]
> 	at ch.systemsx.bee.workflowmanager.queues.SubmissionQueueEntry.run(SubmissionQueueEntry.java:44)
[bee.jar:1.0-SNAPSHOT]
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [na:1.7.0_05]
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [na:1.7.0_05]
> 	at java.lang.Thread.run(Thread.java:722) [na:1.7.0_05]
> As with CacheStrategy.ON_CALL the file objects are wrapped into a decorator
> the following line in SFTPFileObject causes the problem (SftpFileObject.java:289):
> channel.rename(relPath, ((SftpFileObject) newfile).relPath);



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message