How should a program recover from a timeout, using WCF?

I don't have info about the exception any more. In the past when running a program that runs for several hours, the program would eventually encounter a timeout and I never figured out how to recover. How should one do that?

For example, the c# program does this before every invocation:

var client = new DocumentObjRef.DocumentObjClient();
var cred = client.ClientCredentials.UserName;
cred.UserName = "user";
cred.Password = "password";

How can I release resources and continue after experiencing a timeout?

I tried, for example, waiting a few seconds and trying again, but the timeout appears to persist

emoji
Parents Reply Children
No Data