KB Article #175896

create a semaphore file in an external ftp partner delivery exchange

Problem

-- need to send messages with a certain filename to an external server of a partner via FTP. Additionally the partner is requesting us to create an additional semaphore file with the same filename but with an ending .sem once the file was transferred successfully. The content of this semaphore file doesn't matter, so it can be empty or a copy of the original one as long as the filename is the same

Resolution


* Solution 1

create a post-processing script which runs only when the original file was transferred successfully and is just creating a small file in a separate folder with the correct filename and ending. This folder is polled by B2Bi and once the new semaphore file is available sends it to the partner's ftp as well

* Solution 2

create a custom FTP STOR command Java class and insert it after the standard STOR in a new ftpcommandset.xml file, this custom command would upload an empty file with the same filename, but with the .sem extension instead

Pros of Solution 2 compared to Solution 1 :
-        No need for a post processing script
-        No need for a separate sem-file pick up
-        .sem file would be created in the same FTP session as the upload of the original file
-        No entries in MsgTracker for the semaphore files (maybe a con?)
 
Cons:
-        Java development needed
-        Specialised ftpcommandset file needed for this Partner Delivery