views:

55

answers:

2

Does the OneWay operations in WCF service execute as long as the operation is complete?

By my experiment, I think there is no timeout. I was able to run an operation for half an hour. (I closed after that)

Can someone experienced in WCF answer this? If there is a timeout, where can I specify it

+2  A: 

OneWay operations don't wait for a Reply Message. It just writes data to the network connection and returns. So, the only "wait time" would be the time required to write the message to the network.

Be aware though that WCF can still block the client (Clients Blocking with One-Way Operations):

this means that any problem writing the data to the transport prevents the client from returning. Depending upon the problem, the result could be an exception or a delay in sending messages to the service.

Edit: Regarding timeout, they are set on the binding. If your operation can't perform his "Send Message", it can still timeout.

Jeff Caron
Assuming that the operation from client is successful and the server received the message, is there any timeout for the execution?
Sandeep
I don't think so.
Jeff Caron
A: 

There is no timeout. You have to handle it by yourselves in running operation. Timeouts are related to working with channels but in case of one way operation the message is received and passed to operation and no more interaction with channel will ever occure.

Ladislav Mrnka