cancel
Showing results for 
Search instead for 
Did you mean: 

Condition for Receiver Determination

Former Member
0 Kudos

Can we write a condition,where in if the files are coming from the specific folder it has to be recieved by a particular service and if its coming from a diff folder it has to be recieved by another service

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Yes, it is possible.

In the receiver agreement, when you define condition for receivers, click on

Condition --> Condition Editor, Left Operand --> Expression editor, Context Object ---> Directory

You will get one the technical context object for file adapter, click on 'Directory'

And now you put the condition based on which you want to route the file, it will be delivered to the respective target based on the source directory

-Supriya.

Former Member
0 Kudos

Hi Supriya

Thanks i have done the same.but its not working..Here my service is BPM..

The above method works fopr BPM also rite?

Former Member
0 Kudos

Yes, it works for BPM as well.

Probably the directory scheme which you have given in Receiver determination is wrong.

-Supriya.

Former Member
0 Kudos

HI Supriya

The condition i used is

DIRECTORY = D:/out/xmin

the error is "NO_RECEIVER_CASE_ASYNC"

is there anything wrong in the condiiton

Edited by: King_kiran on Nov 15, 2010 4:19 AM

Edited by: King_kiran on Nov 15, 2010 5:03 AM

Former Member
0 Kudos

may be the value does not match. can you enable the directory in ur comm channel under Advanced tab and check if the value is correct

Former Member
0 Kudos

my cc already had it in the advanced selection tab.Dont know where its going wrong

Former Member
0 Kudos

is the file in the local PI directory. if so can you try without the "D:" rather something like /usr/....

Former Member
0 Kudos

Hmm No use..

let me give the condition in detail what i have made so that you can be clear..

directory=d:/out/xmin int_bpm

its the condition in the receiver determintaion..is this rite way to give a condition ? as most of the times we give condition basing on some payload value so am not sure wit these folder things

former_member200962
Active Contributor
0 Kudos

If you are using the Context Object then it should be Directory .....did you trying checking the ASMA for Directory in sender channel?

Check what is the value of Directory in the Message header....if it is not d:/out/xmin int_bpm then the condition is bound to fail.

Former Member
0 Kudos

hi Salvi,

//If you are using the Context Object then it should be Directory //

Yes it is Directory

///did you trying checking the ASMA for Directory in sender channel?///

No its not checked will check it and try

///Check what is the value of Directory in the Message header....if it is not d:/out/xmin int_bpm then the condition is bound to fail.////

i didnt get this.can you elaborate please. message header in the sense u mean in the xml file?

former_member200962
Active Contributor
0 Kudos

not the XML message....since you are making use of the header parameter Directory you should be checking the message header (message consists of Payload (the XML which you place in the folder) and a header section (which contains the fields like Directory, File Name))

If not able to see in channel monitoring.....then remove the condition in RD --> include a small UDF in mapping which will get the Directory value in some target node....check what is the value you are getting.

Regards,

Abhishek.

Former Member
0 Kudos

Hmm of no use..

its not recognising the condition for the folder

Ex:

The Requirement is we have 4 input folders which sends the file .we are using bpm to process them.

The reqrmnt is now that we want the same bpm to run independently for each folder.so we have imported the same bpm in the configuration scenario with four different names.and in the receiver determination we gave the condition like u201Cdirectory=D:/out/xminu201D int_bpm1 and u201Cdirectory=D:/out/xmaxu201D int_bpm2

Answers (0)