Responsing to the original business host after a deferred response

32 views
Skip to first unread message

Dom

unread,
Oct 16, 2014, 6:18:32 AM10/16/14
to Ensemble-in...@googlegroups.com
Hi Everybody,

I have a particular issue I am scratching my head with.

Lets say I have a Router (A), that calls a Business Process (B) which in turn calls a Business Operation (C) that sends a message onto the end system. 

The Business Operation (C) uses a deferred response method to get the response back from the end system. This comes in through a Business Service (D) and updates the token, in turn responding to BO (C)

BO (C) then returns the response back as an output parameter to the BP (B) via its SendRequestSync method


How do I then get the response back from the OnRequest method in BP (B) to the Router (A)?

Because we are using Deferred Response in BO (C), we are not calling the BP (B) OnResponse Method.


1. Can I respond from the BO(C) back to the OnResponse method in BP(B)  when I am using Deferred Response in the BO (C)?
or...
2. Is there any way I can trigger the OnResponse method in BP (B)  from within the BP (B) OnRequest method so it will send back the response to the Router(A)



David Loveluck

unread,
Oct 16, 2014, 7:12:54 AM10/16/14
to Ensemble-in...@googlegroups.com

Hi

 

The BS (D) does not respond to the BO (C)  it responds to the BP.

 

So your BS constructs the full response object and then calls SendDeferredResponse(). The response goes back to the BP and the BP should behave in exactly the same way as if the response came from the original BO. The BP doesn’t really know where the response came from.

 

dave

--
You received this message because you are subscribed to the Google Groups "InterSystems: Ensemble in Healthcare Community" group.
To post to this group, send email to Ensemble-in...@googlegroups.com
To unsubscribe from this group, send email to Ensemble-in-Healt...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/Ensemble-in-Healthcare?hl=en
---
You received this message because you are subscribed to the Google Groups "InterSystems: Ensemble in Healthcare" group.
To unsubscribe from this group and stop receiving emails from it, send an email to Ensemble-in-Healt...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Dom

unread,
Oct 16, 2014, 8:49:31 AM10/16/14
to Ensemble-in...@googlegroups.com
Thanks Dave,

The BP (C) is currently getting the deferred response back via the Output parameter from the Sync call --  its how we then get the response back to the Router (B) from the BP (C) that is the issue. 

Dale du Preez

unread,
Oct 16, 2014, 9:05:12 AM10/16/14
to Ensemble-in...@googlegroups.com
Assuming that this is all implemented in code, I believe it should be sufficient to just set response = <yourOutputVariable>.

Dale


On 10/16/2014 2:49 PM, Dom wrote:
Thanks Dave,

The BP (C) is currently getting the deferred response back via the Output parameter from the Sync call --  its how we then get the response back to the Router (B) from the BP (C) that is the issue. 
Reply all
Reply to author
Forward
0 new messages