|
Home > Archive > BizTalk Server Orchestration > October 2005 > Consecutive Listen/Delay Shapes.
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Consecutive Listen/Delay Shapes.
|
|
|
| Hello All,
I have an orchestration which comes to life with a init message and has two
consecutive listen shapes(L1, L2), each with a delay of 20 seconds. Each
listen shape is in a loop. The recieve shape in each of the listen shapes is
tied to a direct port to the message box listening to a particular
message(MSG 1).
In the first listen(L1) shape I have decision shape (D1), the successful
branch would send a message to a file location depending on some rules, if it
sends a file then it would set the variable to "false" on which the next
listen shape L2 would work. So that the next listen shape will not
execute.This works fine.
Lets say I recieve a message which falls in to the else path of the decision
shape (D1) then I want the next listen(L2) to wait for a next message from
the same port(tied to message box) which the recieve locaiton of listen shape
1 was tied.
But the thing I am seeing is that the first message which L1 recieved is
being passed on to the next listen shape L2. I want L2 to listen for another
new message from the port tied to message box.
Can this be done using listen shapes? Or is there any other way to solve
this porblem?
Any help would be much appreciated.
Thanks in Advance,
KriS.
| |
| Jon Flanders 2005-10-26, 5:52 pm |
| Hello KriS,
So I am not sure but I think this pattern is not possible. I am assuming
both Receives in the Loop are following the same correlation set. What happens
when the correlation set is initialized is that the subscriptions for both
of those receives are created, which is why the first message is routed to
both Receive shapes. I think the only thing that might work is that if you
had a send before the second receive and you initalized a new correlation
set for the second Receive using the Send. I am not postivie that will compile
- because you essentiallly are doing a multiple sequential receive pattern,
which is a special messaging pattern that the designer is aware of, but that
would be the only way to make the second receive subscription wait.
BTW - why have two receives in the loop - can't you acccomplish the same
functionality in the loop itself with just one receive? Maybe I don't understand
the functionality you are trying to build.
Jon Flanders [MVP]
http://www.masteringbiztalk.com
> Hello All,
>
> I have an orchestration which comes to life with a init message and
> has two consecutive listen shapes(L1, L2), each with a delay of 20
> seconds. Each listen shape is in a loop. The recieve shape in each of
> the listen shapes is tied to a direct port to the message box
> listening to a particular message(MSG 1).
>
> In the first listen(L1) shape I have decision shape (D1), the
> successful branch would send a message to a file location depending on
> some rules, if it sends a file then it would set the variable to
> "false" on which the next listen shape L2 would work. So that the next
> listen shape will not execute.This works fine.
>
> Lets say I recieve a message which falls in to the else path of the
> decision shape (D1) then I want the next listen(L2) to wait for a next
> message from the same port(tied to message box) which the recieve
> locaiton of listen shape 1 was tied.
>
> But the thing I am seeing is that the first message which L1 recieved
> is being passed on to the next listen shape L2. I want L2 to listen
> for another new message from the port tied to message box.
>
> Can this be done using listen shapes? Or is there any other way to
> solve this porblem?
>
> Any help would be much appreciated.
>
> Thanks in Advance,
> KriS.
| |
|
| Jon,
Thanks for the reply.
That was my first thought to have a send before the recieve. I already tried
by having a send before the recieve of the listen 2,but that did not work
either. The second recieve still receives the same message which the first
recieve recieved.
The reason I have two listen shapes and have two recieve shapes is for
forwarding this message to the next process. The next process in line would
do its job and wait for the confirmation which would come from the message
box from the same port.
I guess I need to go back and change my design at this point.
Thanks again,
KriS.
"Jon Flanders" wrote:
> Hello KriS,
>
> So I am not sure but I think this pattern is not possible. I am assuming
> both Receives in the Loop are following the same correlation set. What happens
> when the correlation set is initialized is that the subscriptions for both
> of those receives are created, which is why the first message is routed to
> both Receive shapes. I think the only thing that might work is that if you
> had a send before the second receive and you initalized a new correlation
> set for the second Receive using the Send. I am not postivie that will compile
> - because you essentiallly are doing a multiple sequential receive pattern,
> which is a special messaging pattern that the designer is aware of, but that
> would be the only way to make the second receive subscription wait.
>
> BTW - why have two receives in the loop - can't you acccomplish the same
> functionality in the loop itself with just one receive? Maybe I don't understand
> the functionality you are trying to build.
>
>
> Jon Flanders [MVP]
> http://www.masteringbiztalk.com
>
>
>
>
| |
| Jon Flanders 2005-10-26, 5:52 pm |
| Hello KriS, The thing that is going to control this is the correlation set
and when it gets initialized. When you had the second send - did it initialize
the correlation set that the second receive followed?
Jon Flanders [MVP]
http://www.masteringbiztalk.com
[vbcol=seagreen]
> Jon,
>
> Thanks for the reply.
>
> That was my first thought to have a send before the recieve. I already
> tried by having a send before the recieve of the listen 2,but that did
> not work either. The second recieve still receives the same message
> which the first recieve recieved.
>
> The reason I have two listen shapes and have two recieve shapes is for
> forwarding this message to the next process. The next process in line
> would do its job and wait for the confirmation which would come from
> the message box from the same port.
>
> I guess I need to go back and change my design at this point.
>
> Thanks again,
> KriS.
> "Jon Flanders" wrote:
>
| |
|
| Jon,
No it does not initialize the correlation set for the second recieve. So
this is the solution I should be implementing. I will post my progress.Thanks
a lot for the response.
KriS.
"Jon Flanders" wrote:
> Hello KriS, The thing that is going to control this is the correlation set
> and when it gets initialized. When you had the second send - did it initialize
> the correlation set that the second receive followed?
>
>
> Jon Flanders [MVP]
> http://www.masteringbiztalk.com
>
>
>
>
| |
|
| Jon,
Just to update my progress. If I had a send with a new correlation set
another instance of the same orchestration is coming to life. So the thing I
did is I got rid of the second listen shape and it works now!.
Thanks again,
KriS.
"KriS" wrote:
[vbcol=seagreen]
> Jon,
> No it does not initialize the correlation set for the second recieve. So
> this is the solution I should be implementing. I will post my progress.Thanks
> a lot for the response.
> KriS.
>
> "Jon Flanders" wrote:
>
|
|
|
|
|