You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Luigi De Masi (Jira)" <ji...@apache.org> on 2020/11/05 16:47:00 UTC
[jira] [Created] (CAMEL-15822) [camel-file] fileExist=Move doesn't
use FileMoveExistingStrategy when tempFile is also configured
Luigi De Masi created CAMEL-15822:
-------------------------------------
Summary: [camel-file] fileExist=Move doesn't use FileMoveExistingStrategy when tempFile is also configured
Key: CAMEL-15822
URL: https://issues.apache.org/jira/browse/CAMEL-15822
Project: Camel
Issue Type: Bug
Components: camel-core, camel-ftp, camel-sftp
Affects Versions: 3.6.0
Reporter: Luigi De Masi
Assignee: Luigi De Masi
When both fileExist=Move and tempFile are set, GenericFileProducer.doMoveExistingFile is called, while when tempFile is not set FileMoveExistingStrategy.FileMoveExistingStrategy.
It seems a leftover from 2.X -> 3.x migration.
As a result, endpoints like that won't work because GenericFileProducer.doMoveExistingFile doesn't support dynamic subdirectory auto-creation:
{code:java}
file://data/file?tempFileName=${file:onlyname}.temp&fileExist=Move&moveExisting=${file:parent}/archive-${date:now:yyyyMMddHHmmssSSS}/${file:onlyname}"
{code}
it would be nice to have support for partial dynamic subdir name like this :
{code}
fileExist=Move&moveExisting=archive-${date:now:yyyyMMddHHmmssSSS}/
{code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)