cancel
Showing results for 
Search instead for 
Did you mean: 

How to handle Multiple Receiver at Runtime

Former Member
0 Kudos

Hi All,

My requirement is File to JDBC Sync to multiple Receivers (Ex: Three receiver JDBC, File System1 and File System2) depending upon the JDBC Response I have to decide which receiver system. This should happen at runtime depending upon the condition.

In this scenario I am also using BPM.

For Example:

Suppose in the Database, I have three records (EmpID, EmpName and EmpSal).where EmpID is 1000, 1001 and 1002.

If EmpId is 1000 than I should send to Database

If EmpId is 1001 than I should send to File System1

If EmpId is 1002 than I will send to File System 2

How can I achieve this scenario?

Do I need to handle this in BPM or Receiver Determination or Message Mapping or Interface Determination?

Can some help me in giving in details steps, please?

Thanks

Shaik

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

or Juz use the <b>switch step</b> type in BPM.It gives much better control.

Former Member
0 Kudos

Hi all,

thanks for ur prompt respose. How can i do this in BPM. can some one explain me wht step required after synchronous JDBC Respose.

steps involved in IP File JDBC Sync to File (instead of File i want to have multiple receiver here)are

Receive Step, Sync Send Step and Send Step.

Thanks

Shaik

henrique_pinto
Active Contributor
0 Kudos

So you have one single message (response from JDBC sync) with multiple records, and each record should be sent to specific receiver, is that it?

If that's it, don't modify your BPM, set proper receiver determination conditions (f.ex., if EmpID = 1, send to REceiver 1, if EmpID = 2,Receiver 2 etc.).

Up to now, this is what is gonna happen: if your response message have 3 records, each with a different EmpID, the message will be sent to all the receivers (since the condition is checked like this: IF XML contains EmpID = 1, send to Receiver 1; IF it contains EmpID = 2, send to Receiver 2, ...). Hence, all conditions will be met and all receiver will receive the file.

Now, you need to create several mapping programs in order to guarantee that the receiver will receive only the proper records. And for each interface determination you have (in this case, you should have 3) you must set a different mapping (one for each receiver, as in to filter only the specific messages).

That's one way of doing it.

One alternative way is of executing a multimapping in BPM after JDBC response. This multimapping needs to separate all the records in different messages, in a way that each message only has records of a single EmpID. In this case, you don't need to maintain different mapping programs for each receiver, just the condition in receiver determination should be enough.

Regards,

Henrique.

Former Member
0 Kudos

Hi Henrique,

I appreciate your answer. But I have couple of queries which would like to get clarify.

1. <i>If that's it, don't modify your BPM, set proper receiver determination conditions (f.ex., if EmpID = 1, send to REceiver 1, if EmpID = 2,Receiver 2 etc.).

</i>

In our case u has three EmpID's. What happens if I have 20 or more EmpID's. Do I need to have 20 conditions in the Receiver Determination?

2. <i>One alternative way is of executing a multimapping in BPM after JDBC response.</i>

Can you explain me how can i execute a multi mapping in BPM?

If possible give be explanation in step by step way.

Thanks

Shaik

Former Member
0 Kudos

Hey

>>In our case u has three EmpID's. What happens if I have 20 or more EmpID's. Do I need to have 20 conditions in the Receiver Determination?

yes

>>Can you explain me how can i execute a multi mapping in BPM?

you execute MUltimapping in BPM if you have a N:M scenario or 1:M scenario for IDOC or HTTP,you define a message mapping in IR and use this in transformation step in BPM .

Thanx

Ahmad

Former Member
0 Kudos

hi Ahmad,

<i>In our case u has three EmpID's. What happens if I have 20 or more EmpID's. Do I need to have 20 conditions in the Receiver Determination?

yes </i>

is this is not going to be a performance issue, if increase the CC .

Thanks

Shaik

Former Member
0 Kudos

yes,this can be,infact its one of the few time consuming jobs in pipeline steps.

context based routin takes some time but it wont be that big of an issue.

Thanx

AHmad

henrique_pinto
Active Contributor
0 Kudos

Actually the slow step about content-based conditional routings is the parsing of the payload at receiver determination runtime. Since the payload will be parsed anyway, I don't think it will be much of a differente if you have 1 or 20 conditions (that is, if all conditions are based in the same field; which you could even read through a context object, to try to increase performance).

However, conditional routing in receiver determination is best suited for few conditions.

If you do have the requirement of several possible receivers, use enhanced receiver determination instead.

Regards,

Henrique.

Answers (4)

Answers (4)

Former Member
0 Kudos

thanks for all for ur support.

right now i will go with the condition editor . if any problem i will raise a thread.

I am awarding points to all.

thanks

Shaik

henrique_pinto
Active Contributor
0 Kudos

azias, if your questions were answered, please close the thread.

Regards,

Henrique.

Former Member
0 Kudos

HEY,

    • IF YOU WANT TO KEEP IT SIMPLE THEN EITHER USE CONTEXT OBJECTS OR XPATH AND SPECIFY THE CONDITION IN RECEIVER DETERMINATION**

Cheers,

<b>*RAJ*

*REWARD POINTS IF FOUND USEFULL*</b>

prateek
Active Contributor
0 Kudos

<i>Do I need to handle this in BPM or Receiver Determination or Message Mapping or Interface Determination?</i>

1. U can handle it in BPM

2. U may use dynamic receiver determination as shown

/people/robin.schroeder/blog/2006/11/15/using-dynamic-receiver-determination-with-sync-interface

/people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16

Regards,

Prateek

former_member184619
Active Contributor
0 Kudos

Hi Shaik,

u can do it without BPm

Check these blogs

/people/shabarish.vijayakumar/blog/2005/08/03/xpath-to-show-the-path-multiple-receivers

/people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination

Sachin