Но иногда я просто получаю сообщение InvalidOperationException, и оно имеет следующее сообщение. Есть ли способ интерпретировать, что это такое, не копаясь в строке в поисках знакомых вещей, которые кажутся очень грязными и не зависят от интернационализации, сообщение об ошибке может вернуться на другом языке.
Код: Выделить всё
Client found response content type of 'text/html; charset=utf-8', but expected 'text/xml'.
The request failed with the error message:
--
Request timed out.
body {font-family:"Verdana";font-weight:normal;font-size: .7em;color:black;}
p {font-family:"Verdana";font-weight:normal;color:black;margin-top: -5px}
b {font-family:"Verdana";font-weight:bold;color:black;margin-top: -5px}
H1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red }
H2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon }
pre {font-family:"Lucida Console";font-size: .9em}
.marker {font-weight: bold; color: black;text-decoration: none;}
.version {color: gray;}
.error {margin-bottom: 10px;}
.expandable { text-decoration:underline; font-weight:bold; color:navy; cursor:hand; }
Server Error in '/PerformanceManager' Application.
[i]Request timed out.[/i]
Description: [/b]An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.[b]
Exception Details: [/b]System.Web.HttpException: Request timed out.[b]
Source Error:[/b] [b]
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.Stack Trace:[/b]
Код: Выделить всё
[HttpException (0x80004005): Request timed out.]
Version Information:[/b] Microsoft .NET Framework Version:2.0.50727.312; ASP.NET Version:2.0.50727.833
--.
Изменить:
У меня есть попытка обойти этот метод на веб-сервере. Я отладил его, и метод веб-сервера возвращается (примерно через минуту) без каких-либо исключений. Я также добавил обработчик необработанных исключений в веб-службу, и точка останова там не была достигнута. Как только веб-сервис возвращается, я получаю эту ошибку в клиенте вместо ожидаемого результата.
Подробнее здесь: https://stackoverflow.com/questions/115 ... -be-interp
Мобильная версия