Thx Dirk,
The solution i came up with:
- Extend the FtpMessageReceiver
- replace the implementations of procesFile and createFtpClient (something to do with unexposed methods)
Implemented the following code ;
message.setProperty(FileConnector.PROPERTY_ORIGINAL_FILENAME, file.getName());
message.setProperty(FileConnector.PROPERTY_FILE_SIZE, file.getSize());
// New Custom Property
Map<String,String> map = new HashMap<String, String>(1);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd@HH:mm:ss.SSS");
map.put("FtpserverTimestamp", sdf.format(file.getTimestamp().getTime()).replace('@', 'T'));
// end new Custom Property
And added in config :
<ftp:connector name="ftpConnector" validateConnections="true"
streaming="false" passive="true">
<service-overrides messageReceiver="org.mule.rws.lbs.FtpMessageReceiverWithProps"/>
<file:expression-filename-parser />
</ftp:connector>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email