java - Apache camel file encrypt/ ftp upload woes on Windows -



java - Apache camel file encrypt/ ftp upload woes on Windows -

i have java web application creates file in folder. these files picked camel route pgp encrypts , ftp's it. initially, had 1 route , worked on windows servers. stopped working. so, split 2 routes way if ftp fails won't have unencrypted files lying on server. plus, can manually ftp those, if needed (not ideal). now, works on 1 server not another. both windows servers, application server tomcat.

is there reliable way create work across servers?

the routes shown below

<route id="file_encrypt"> <from uri="file://{{rootoutputdirectory}}/thirdparty/outbound?readlock=rename&amp;delete=true"/> <setheader headername="cryptokeyfile"> <simple>${properties:thirdparty.pgpkey}</simple> </setheader> <to uri="bean:pgpencryptprocessor"/> <to uri="file://{{rootoutputdirectory}}/thirdparty/outbound/encrypted"/> </route> <route id="file_ftp"> <from uri="file://{{rootoutputdirectory}}/thirdparty/outbound/encrypted/?readlock=rename&amp;move=.done&amp;movefailed=.error"/> <to uri="ftp://{{thirdparty.ftp.user}}@{{thirdparty.ftp.url}}{{thirdparty.ftp.outgoingdir}}/?password={{thirdparty.ftp.password}}&amp;binary=true"/> </route>

the value of thirdparty.ftp.outgoingdir is

thirdparty.ftp.outgoingdir=/test/incoming

i see next error in log

org.apache.camel.component.file.genericfileoperationfailedexception: file operation failed: 550 failed alter directory.

it seems issue listed here - http://camel.465427.n5.nabble.com/cannot-change-directory-to-quot-code-550-on-ftp-component-td5734612.html. however, not clear why works on 1 server not same settings.

turns out commons-net version different across different servers - 1 had 3.1 (works) , other had 3.2 (doesn't work). not sure how happened (looking it). however, switching commons-net 3.1 across servers got working.

java windows encryption ftp apache-camel

Comments

Popular posts from this blog

model view controller - MVC Rails Planning -

ruby on rails - Devise Logout Error in RoR -

html - Submenu setup with jquery and effect 'fold' -