cancel
Showing results for 
Search instead for 
Did you mean: 

Complex Scenario on file sequencing

Former Member
0 Kudos

Hi All,

I am developing one scenario where requirement is as follows.

My source system will generate a set of Data files and one control file which will be having details of all these data files.

XI has to pick this control file first and depending upon the details specified in it, it has to pull all the data files. When all data files corresponding to that control file are picked up then only XI should send all those files to target system otherwise it should wait.

For Example XI got Control1 file which contains data1, data2 and data3 files. Now XI will pick Control1 file first. Then it should go and check for Data1. once it is picked up it should go and check data2. Similarly for Data3. Once all the files got picked up then it should send those files to target in sequence. That is Data1 should go first then data2 then data3 and then control1 should go.

Can anybody suggest anything on how to deal with this?

Warm Regards,

Gouri

Accepted Solutions (0)

Answers (6)

Answers (6)

Former Member
0 Kudos

Hey,

SAP by default provides some exampples in IR. Check them out.

To display the integration process in the Integration Repository, choose SAP BASIS ® SAP BASIS 7.00 -> http://sap.com/xi/XI/System/Patterns ->Integration Scenario & Integration Process -> Integration Process -> BpmPatternCollectPayload.

You can even find the other objects req lyk data type message type, msg interfaces, mapping , interface mapping etc in short everthing req to be done in IR.

Entire scenario is explained for payload.

Cheers,

RAJ*

*REWARD POINTS IF FOUND HELPFUL*</b>

Former Member
0 Kudos
Former Member
0 Kudos

Do you have any step-by-step document on Collect messages payload dependant?? or any blog??

-Gouri

Former Member
0 Kudos
Former Member
0 Kudos

Hey,

50 to 70 mb files with or with out BPM will affect the performance. Standard file size should be around 20 MB. So you have to split the file if you want to acheive perfromance. There is blog available for the that or else if you are using fcc in file adapter juz Check out the paramter No of record sets per measage . Then apply methodology as suggested by prateek.

Cheers

<b>*RAJ*

*REWARD POINTS IF FOUND USEFULL*</b>

Former Member
0 Kudos

I am already splitting file. Now here my question is in BPM we can not write any code. Here first I need to pick control file and then I have to check the content of control file and then I have to pick data files. Also I need to pass data files first to target and then this corresponding control file.

How I will achieve this in BPM?

-Gouri

Former Member
0 Kudos

Hi ,

interesting scenario you have there

There are two ways I can suggest...

Using BPM collect scenario

Staring the BPM will not be an issue .stopping it is ...i.e. when it should stop collecting messages.it will be started ...by the interface of the control file which you will send ...this control file must have some information about the number of files it has ...(two recieve steps each identifying these two interfaces ...set a counter step in this case .) or some keyfield which identifies each file ..(if not ask for this info to be incorporated in the files)..

if the interfaces of rest of the other then control file is the same...then you have two interface kinds to deal with...if not ..then you'll that many interfaces you have make(in this case hope they are fixed ).

Refer to SAP BASIS component ..you will have certain scenarios under BPM patterns ...which will give you a fairely decent idea ..as to how to handel your scenario ( they are just template which you can copy and use after customising them according to your need)

Besides there is work around i can suggest (as I am not a java guy i prefer abap)

Here you can code in abap side of xi ...a code which will pick your control file .....

from the location (ask your basis guy to set the file path) ..and based on these control file..pick all the other files and place it in a folder or ftp location from where XI will pick ....(use job sceduling for automation )..just a suggestion ..I am using method to split large files ..as ..BPM is resource taxing ...

Former Member
0 Kudos

Thanks Deepak.

If I decide to go ahead with BPM then I have to use Collect pattern dependant on message payload.

Now here my control file will tell me how many data files are going to come. So what will be my ID and IR configuration in this?

I mean to say how many data types, message interfaces, communication channels etc...

-Warm Regards,

Gouri

Former Member
0 Kudos

Hi,

Since your collect pattern will tell you how many files it has to pick..

I hope the interface of the rest of the files is the same ...

So you basically have 2 interfaces ..

1)For the control file

2)for the rest of the files ..

In ID ...

If the source and target interface type is the same for these two interface types then you may not require ..but should you choose ..to do mapping (which i recommend) then create two target inbound interfcaes of the same type.

one message mapping (for non control files ..assuming you do not require any transformation in control file otherwise you have to map it seprately)

Corresponding interface mapping ..

Besides for BPM design could you give me as to what kind of control information we are talking about.

Kindly paste sample.

Regards,

Deepak

Former Member
0 Kudos

Thanks.

I dont have any sample file. But scenario will be as follows.

Control1234, HData1234, TData1234, DData1234.

Now I have to take the sequence no 1234 from control file and need to pick all the data files with same sequence no. Mapping will be 1:1. I have to take these files as it is and provide to target.

Only thing is while picking I should pick this control file first and then data file because sequence no will be specified in control file payload.Also payload will tell how many data files will be there for this sequence no. But when I pick all the corresponding data file I need to pass all data files first and then this control file.

Now in this case how many communication channels I should to create?

How many data types?Separate for control and data or not??

How many message interfaces??? etc.

-Gouri

prateek
Active Contributor
0 Kudos

Accessing the control file wouldnt b a prob for u i think. Then go for "variable substitution" to dynamically fetch the filename from the payload.

See this

http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm

For the requirement of collecting the file in XI, u need to implement BPM. There is a BPM pattern called Serialization for such cases

Regards,

Prateek

Former Member
0 Kudos

Hi

You can achieve the same using File adapter module (sender). Inside the adapter module, you can use a open source file connecter like apache commons to receive and process the files

regards

krishna

Former Member
0 Kudos

Thanks Krishna.

Can you please elaborate on this?

-Gouri

justin_santhanam
Active Contributor
0 Kudos

Gouri,

In BPM you can achieve the same. I hope there is some common field among Control data1 data2 data3 right? Then in BPM first u have to use Fork branch which receives these 4 files. You have to define correlation , which will be common among those 4 files. Once all the 4 files has been received then u can place send steps sequentially in order to send Data1 Data2 Data3 and Control File .

If you have any doubts, reply back.

Best regards,

raj.

Former Member
0 Kudos

The volume of file is very big. At a time there will be 4 to 5 60 to 70MB files will be coming. And Simultaneously no of interfaces will be running. So this will affect performance and also XI wont be able to handle such big volume at a time.

So is there any other way out than BPM?

-Gouri