We have a WCF + Rest service running on the host. I need to make a client call to the host that would initiate a long running task on the server (even up to 15 min), then check back once that process has finished to get the result. One solution is to have client checking the host every minute or so after the initial call - but that seems not very productive. Is there a way to expose some type of event through WCF so that client would be notified when the task completed on the server? What is the best approach for this type of scenario? thanks
Kind of hard to answer without more application details. But have a few alternatives (here are a few of them):
Here are some more information regarding duplex contracts: https://msdn.microsoft.com/en-us/library/ms731064%28v=vs.110%29.aspx
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.