cancel
Showing results for 
Search instead for 
Did you mean: 

How to set wait time for picking files in SFTP server or wait time in message mapping

former_member601407
Participant
0 Kudos

Hi,

I have an inbound scenario, where around 50 files are getting processed in PI and sent to ECC at a time. I want to have a wait time either for picking the file in SFTP server (like, 1st file and 2nd file picking time difference should be about 30secsand so on)

or

we can have wait time in message mapping.

Let me know how we can configure that

Accepted Solutions (1)

Accepted Solutions (1)

peter_wallner2
Active Contributor

Hello,

If your PI runs on Linux or Unix just use "Run Operating System Command after message processing" and type in "sleep 30"

Best regards, peter

JaySchwendemann
Active Contributor
0 Kudos

That sounds clever! Does this really work? I mean the operating system command ought to be executed on the sender sFTP server, right? Sorry being too lazy to look up specifications of the "Run Operating System Command after message processing" parameter 🙂

peter_wallner2
Active Contributor
0 Kudos

Hello Jens,

I have not tried it with a sender channel that accesses a server out of the network.
So far I have only used it on (S)FTP sender channels that access within the company network. It does work.

I had issues once when I transported an iFlow, it said I have no authorization to maintain OS commands. So I deleted the command on the channel, transported the iFlow and added the command again.

Best regards, Peter

former_member190293
Active Contributor
0 Kudos

Hi Jens!

OS command is executed on PI application server's OS.

Regards, Evgeniy.

peter_wallner2
Active Contributor
0 Kudos

Hello Evgeniy

so it will even work with an SFTP server outside my network, correct?
Best regards, Peter

former_member190293
Active Contributor
0 Kudos

Hello Peter!

Yes, I guess so.

I hardly can imagine the way adapter could execute the OS commands on remote server's side using SFTP connection :-).

Regards, Evgeniy.

peter_wallner2
Active Contributor
0 Kudos

Hello Evgeniy, you are correct.

Answers (2)

Answers (2)

JaySchwendemann
Active Contributor

Sounds what you really want to do is queuing things? When you are willing to spend say 30 seconds then I would assume that it will be legit to process the files in sequence.

Please have a look at Quality Of Service "Exactly Once In Order".

You can even enforce to have queue names depending on some kind of key within the payload for example. This allows you to only queue up semantically matching messages, e.g. all messages to one order number go into a queue, but order 1234 will not block order 9876. See vadim.klimov 's excelent Blog about that: https://blogs.sap.com/2016/08/15/setting-dynamic-queue-name-in-eoio-scenarios/

Cheers

Jens

PavanKumar
Active Contributor
0 Kudos

Hi Subin,

You can configure the parameter Interval (ms) for modification check in sender SFTP Channel with the value how much wait time you want other file to process.

Regards

Pavan

former_member190293
Active Contributor
0 Kudos

Hi!

This option allows to check if the file is still being changed when channel is going to pick that file.

Regards, Evgeniy.