I am instantiating an XmlSerializer using the XmlSerializer(Type)
constructor. This works most of the time, but sometimes I get a timeout
during the process. I'm using the same type in all cases and it has happened
on multiple computers ranging from 500 MHz to 2.6 GHz. Does anyone know why
the csc.exe process would time out in this case? It looks like the timeout
is set to 10 minutes which seems like a long time to wait for something.
Here's the detailed stack trace if it helps:
Timed out waiting for a program to execute. The command being executed was
"c:\winnt\microsoft.net\framework\v1.1.4322\csc.ex e" /noconfig
@"C:\TEMP\qwjndcv1.cmdline".
at
System.CodeDom.Compiler.Executor.ExecWaitWithCaptu reUnimpersonated(IntPtr
userToken, String cmd, String currentDir, TempFileCollection tempFiles,
String& outputName, String& errorName, String trueCmdLine)
at System.CodeDom.Compiler.Executor.ExecWaitWithCaptu re(IntPtr userToken,
String cmd, String currentDir, TempFileCollection tempFiles, String&
outputName, String& errorName, String trueCmdLine)
at System.CodeDom.Compiler.CodeCompiler.Compile(Compi lerParameters
options, String compilerDirectory, String compilerExe, String arguments,
String& outputFile, Int32& nativeReturnValue, String trueArgs)
at System.CodeDom.Compiler.CodeCompiler.FromFileBatch (CompilerParameters
options, String[] fileNames)
at
System.CodeDom.Compiler.CodeCompiler.FromSourceBat ch(CompilerParameters
options, String[] sources)
at System.CodeDom.Compiler.CodeCompiler.FromSource(Co mpilerParameters
options, String source)
at
System.CodeDom.Compiler.CodeCompiler.System.CodeDo m.Compiler.ICodeCompiler.C
ompileAssemblyFromSource(CompilerParameters options, String source)
at System.Xml.Serialization.Compiler.Compile()
at System.Xml.Serialization.TempAssembly..ctor(XmlMap ping[] xmlMappings)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String
defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
Thanks,
Rangi