Hi, Basically I don't know the name of the file that will be unzipped, so for that I am using regex in source path.
Is something wrong there. Cause if I give specific file name with .zip extension it is successfully able to unzip it. Thanks On Tue, 16 Oct 2018, 15:41 Aman Singh, <[email protected]> wrote: > Hi , > > The file connector version is 2.0.10 > and the EI is 6.2.0 > > Thanks > > On Tue, Oct 16, 2018 at 3:37 PM Cyril Rognon <[email protected]> wrote: > >> Hi >> >> We would need to know the version of EI you are using. And the version of >> the fileconnector if it was added. >> >> Thanks >> Cyril >> >> Le mar. 16 oct. 2018 à 09:56, Aman Singh <[email protected]> a >> écrit : >> >>> Hi All, >>> >>> I have created an inbound-endpoint which copies a "zip" file with any >>> name from server to local. Below is the code for my inbounf-endpoint:- >>> <?xml version="1.0" encoding="UTF-8"?> >>> <inboundEndpoint name="FileCopyIE" onError="sequence2" protocol="file" >>> sequence="sequence1" suspend="false" xmlns=" >>> http://ws.apache.org/ns/synapse"> >>> <parameters> >>> <parameter name="interval">1000</parameter> >>> <parameter name="sequential">true</parameter> >>> <parameter name="coordination">true</parameter> >>> <parameter >>> name="transport.vfs.ContentType">application/octet-stream</parameter> >>> <parameter >>> name="transport.vfs.LockReleaseSameNode">false</parameter> >>> <parameter name="transport.vfs.AutoLockRelease">true</parameter> >>> <parameter >>> name="transport.vfs.ActionAfterFailure">MOVE</parameter> >>> <parameter >>> name="transport.vfs.ActionAfterProcess">MOVE</parameter> >>> <parameter >>> name="transport.vfs.FileURI">sftp://username:password@hostname >>> /home/folder1?sftpPathFromRoot=true</parameter> >>> <parameter >>> name="transport.vfs.MoveAfterFailure">D:/Fail</parameter> >>> <parameter name="transport.vfs.DistributedLock">false</parameter> >>> <parameter name="transport.vfs.FileNamePattern">.*.*</parameter> >>> <parameter name="transport.vfs.MoveAfterProcess">D: >>> /AfterProcess</parameter> >>> <parameter name="transport.vfs.Locking">disable</parameter> >>> <parameter >>> name="transport.vfs.FileSortAttribute">none</parameter> >>> <parameter >>> name="transport.vfs.FileSortAscending">true</parameter> >>> <parameter name="transport.vfs.CreateFolder">true</parameter> >>> <parameter name="transport.vfs.Streaming">false</parameter> >>> <parameter name="transport.vfs.Build">false</parameter> >>> </parameters> >>> </inboundEndpoint> >>> >>> Now I want to unzip the file from picking it from copied location, my >>> code for that is below:- >>> >>> <?xml version="1.0" encoding="UTF-8"?> >>> <sequence name="sequence1" trace="disable" xmlns=" >>> http://ws.apache.org/ns/synapse"> >>> <log level="custom"> >>> <property name="message" value="==========Succefully Started >>> Sequence============"/> >>> </log> >>> <script >>> language="js"><![CDATA[java.lang.Thread.sleep(15000);]]></script> >>> <fileconnector.unzip> >>> <source>file:///D:/AfterProcess/.*.zip</source> >>> <destination>file:///D:/001/</destination> >>> </fileconnector.unzip> >>> <log level="custom"> >>> <property name="message" value="==========Succefully UnZip >>> file"/> >>> </log> >>> <log level="custom"> >>> <property name="message" value="Succefully UnZip file"/> >>> </log> >>> >>> </sequence> >>> >>> But it is unable to unzip my file. Rest Log mediator message are >>> printing but unzip is not working >>> Can anybody help with the issue here? Why the unzipping is failing. What >>> do I need to change? >>> >>> Thank you. >>> >>> _______________________________________________ >>> Dev mailing list >>> [email protected] >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
