cancel
Showing results for 
Search instead for 
Did you mean: 

File Adapter - Signal File Handling w/o ccBPM

Former Member
0 Kudos

Hi!
We have a Sender File Adapter processing files from a certain directory.

But the File Adapter must not start file processing before a certain file, a so-called signal file has arrived in that directory. This signal file is transferred as the last file to that directory and indicates that all relevant files to be processed by the file adapter are successfully transferred to the directory.

How can we achive that without using ccBPM?

Thanx for any hint.

Regards,
Volker

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member184681
Active Contributor
0 Kudos

Hi,

If you need further assistance to achieve the solution described by Michal, have a look at this Wiki, question #4: http://wiki.sdn.sap.com/wiki/display/XI/Sender+File+Adapter+Frequently+Asked+Questions. I believe it provides a nice example, with some more explanation and a screenshot.

Hope this helps,
Greg

Former Member
0 Kudos

Hi Greg! Hi Michal!
Thanx very much. I'll try it today and then I'll give a feedback.
Regards,
Volker

Former Member
0 Kudos

Hi Greg! Hi Michal!
Unfortunately this simple soultion does not work in my case, because my files have different names.
File name is e.g. x3o*.xml, where the * stands for a timestamp.
As far as I've understood the additional file names have to be identical to the original file names. This would mean in my case:
I get 500-1000 files per hour in a bulk ftp. and then I have to create and transfer 500-1000 trigger files, one for each "real" file. This is not practicable for me.


I tried to use wild cards in the namePart parameter ("x3o*.xml"="x3o*.sig"), but that does not work. File adapter throughs exception: java.lang.Exception: Add attachment: Mandatory file  name part 'x3o*.xml' in main document file not found!

Any other ideas?

Regards,
Volker

former_member184681
Active Contributor
0 Kudos

Hi,

Try using the following: (".xml"=".sig") instead of: ("x3o*.xml"="x3o*.sig") for the namePart parameter. This should work fine. As a rule, the Additional File(s) functionality is ready to work with different file names.

Hope this helps,
Greg

Former Member
0 Kudos

Hi Greg!

I've tried that also (but forgot to mention it in my last reply). I put several files into the directory with names x3o.....xml. Unfortunately the result was:

java.lang.Exception: Add attachment: Mandatory additional payload file 'x3o_1000_GEN.sig' not found!

Where x3o_1000_GEN.xml was the name of one of my "real" files. I have PI 7.11 SP8

Online documentation http://help.sap.com/saphelp_nwpi711/helpdata/en/44/692ab8a4b633eae10000000a1553f6/content.htm also says: "The way that the files to be transported are grouped together is defined by the file names. All file names must be identical except for a defined part (such as the suffix)."

Regards,

Volker

former_member184681
Active Contributor
0 Kudos

Dear Volker,

>>> Mandatory additional payload file 'x3o_1000_GEN.sig' not found!

Was it true when you did your testing? I mean, for that one particular file x3o_1000_GEN.xml, is the signal file name as follows: x3o_1000_GEN.sig? And at this particular moment when the interface was executed, did the signal file exist in the source directory, along with the "original" interface file?

Regards,
Greg

Former Member
0 Kudos

Hi Volker,

I put several files into the directory with names x3o.....xml.

Did you created .sig file for each .xml file. May be for now you can try with 2 or 3 set of files (.xml file and its corresponding .sig file). This functionality should definitely work.

Regards,

Amol

Former Member
0 Kudos

No, I had several x30...xml files and one x3o.sig File.

Regards,

Volker

Former Member
0 Kudos

Hi Amol!

Thanx for your hint and I am sure this would work, BUT:

Like already mentioned this is not practical for me, because I have to handle bulk processing (e.g. 500-1000 files per hour). I think it is not a "nice" solution to generate 500-1000 sig files per hour.

Regards,

Volker

Former Member
0 Kudos

Hi Volker,

Ideally the source system should generate .sig files for you since they would know when the main file is completely written and is ready for PI to process.

Regards,

-Amol

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

there is a better way to do it then with any dummy (second) interface:

1. use Additional File(s) option in the file adapter and specify it:

optional = NO - so the file will not be processed if the singnal file is not there

2. specify in the additional files the signal file name (or extension)

Result:

it will only pull the original file is Additional File (signal file) is in the folder

easy and no BPM

Regards,

Michal Krawczyk


santhosh_kumarv
Active Contributor
0 Kudos

Configure 2 Interfaces.

Option -1 :

Interface-1: Actual Interface.

Configure the File CC to pick the actual files and do not enable option process read-only file. Make sure that the file are getting writted with the read-only option.

Interface-2: Dummy Interface

Configure the Sender File CC to check for the signal file and modify the file permission of the actual file in the same CC using the Run OS Command. This will make the file ready to be processed by the other interface.

~SaNv...