cancel
Showing results for 
Search instead for 
Did you mean: 

FTP Sender Adapter always process in ascending alphabetical order?

suwandi_cahyadi
Contributor
0 Kudos

Hi Experts,

I just want to confirm for the sequence of the FTP sender adapter processing. Is the processing sequence is always in ascending alphabetical order?

I've been trying to find out, in the help document for the 7.4 version:

Configuring the Sender FTP Adapter - Advanced Adapter Engine - SAP Library

It's stated that "Files are always processed in ascending alphabetical order."

However, after searching more in the forums, some have an opinion that the processing sequence depends cannot be determined, such as in the following discussion:

Processing files in Sequence using FTP Adapter | SCN

I just want to make sure if the processing sequence can be guaranteed in ascending alphabetical order or it depends on the system/FTP server?

Thank you,

Suwandi C.

Accepted Solutions (1)

Accepted Solutions (1)

vadimklimov
Active Contributor
0 Kudos

Hi Suwandi,

As mentioned by Vishnu, you may select between processing order by name or by date when using QoS = EOIO.

When using QoS = EO, the order in which files will be processed from the polling directory, cannot be guaranteed. Let me explain the reason for this. When File adapter retrieves files list for files located in the polling directory, it relies on functionality of JDK - to be more precise, it uses class java.io.File and retrieves a list of files from the polling directory using File.listFiles(). Even though practically you will most likely get a list of files in alphabetical ascending order when using this method, referring to official documentation for JDK's class File, "There is no guarantee that the name strings in the resulting array will appear in any specific order; they are not, in particular, guaranteed to appear in alphabetical order." (see e.g. Java Platform SE 6). As to my knowledge, File adapter doesn't make explicit sorting of retrieved files for QoS = EO - which means, it relies on a list returned by JDK's File.listFiles(). Putting all this together, drives me to a conclusion, you may expect files to be processed in alphabetical ascending order for QoS = EO, but this cannot be 100% assured.

Regards,

Vadim

Answers (2)

Answers (2)

suwandi_cahyadi
Contributor
0 Kudos

Hi All,

Thank you for the kind explanation. In that case, can I conclude that if I use the EOIO for sender FTP, the files will be guaranteed to be processed in ascending alphabetical order?

Thank you,

Suwandi C.

vadimklimov
Active Contributor
0 Kudos

Yes.

pvishnuvardan_reddy
Active Contributor
0 Kudos

Hi Suwandi,

From the note 821267 - FAQ: XI 3.0 / PI 7.0 / PI 7.1 / PI 7.3 File Adapter, check for Q:12

     The File Adapter allows you to configure the Processing Sequence of files for the Transport Protocol "File System (NFS)", which also determines the order for EOIO processing. Files can either be processed in ascending alphabetical order (Processing Sequence "By Name") or by their last modification time stamp (Processing Sequence "By Date"), where the oldest file is processed first. For the Transport Protocol "File Transfer Protocol (FTP)" files are always processed in ascending alphabetical order.