Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Exceptions and WCF services with void return type

If we call a WCF service with a void as a return type.

Will it wait around for the service to finish processing in case there is an exception?

Or will it return imediately and the client will not be notified of any exception on the server?

like image 480
Shiraz Bhaiji Avatar asked Jan 20 '11 17:01

Shiraz Bhaiji


2 Answers

By default it will wait around. If you use the IsOneWay attribute however, it will not.

like image 118
Paul Hiles Avatar answered Nov 12 '22 20:11

Paul Hiles


The execution of a WCF method will not become asynchronous just because there is a void return type. It will still execute to completion before returning.

like image 29
JaredPar Avatar answered Nov 12 '22 22:11

JaredPar