我正在使用IntelliTrace在Azure服务器中调试应用程序。有时我可以看到产生异常的代码,但有时候我不能。而且我看不到的相应代码的例外总是相同的。
当我双击异常开始调试时,有没有理由在新标签页中继续获得相同的消息(没有可用的来源)?
我已经知道解决它需要做什么异常,但我也需要知道在哪里找到代码!帮助
@SLaks
我得到的例外情况的一个例子是:
"The condition specified using HTTP conditional header(s) is not met."
调用堆栈:
[External Code]
System.dll!System.Net.LazyAsyncResult.Complete(System.IntPtr userToken = {unknown})
[External Code]
System.dll!System.Net.ContextAwareResult.Complete(System.IntPtr userToken = {unknown})
System.dll!System.Net.HttpWebRequest.ProcessResponse()
System.dll!System.Net.HttpWebRequest.SetResponse(System.Net.CoreResponseData coreResponseData = {unknown})
System.dll!System.Net.ConnectionReturnResult.SetResponses(System.Net.ConnectionReturnResult returnResult = {unknown})
System.dll!System.Net.Connection.ReadComplete(int bytesRead = {unknown}, System.Net.WebExceptionStatus errorStatus = {unknown})
System.dll!System.Net.Connection.ReadCallback(System.IAsyncResult asyncResult = {unknown})
System.dll!System.Net.LazyAsyncResult.Complete(System.IntPtr userToken = {unknown})
System.dll!System.Net.Security._SslStream.ProcessFrameBody(int readBytes = {unknown}, byte[] buffer = {unknown}, int offset = {unknown}, int count = {unknown}, System.Net.AsyncProtocolRequest asyncRequest = {unknown})
System.dll!System.Net.Security._SslStream.ReadFrameCallback(System.Net.AsyncProtocolRequest asyncRequest = {unknown})
System.dll!System.Net.FixedSizeReader.CheckCompletionBeforeNextRead(int bytes = {unknown})
System.dll!System.Net.FixedSizeReader.ReadCallback(System.IAsyncResult transportResult = {unknown})
System.dll!System.Net.LazyAsyncResult.Complete(System.IntPtr userToken = {unknown})
[External Code]
System.dll!System.Net.ContextAwareResult.Complete(System.IntPtr userToken = {unknown})
System.dll!System.Net.Sockets.BaseOverlappedAsyncResult.CompletionPortCallback(uint errorCode = {unknown}, uint numBytes = {unknown}, System.Threading.NativeOverlapped* nativeOverlapped = {unknown})
[External Code]
例外实际上是由我造成的。这是一个例子:
AzureBrightWebRole.dll!AzureBright.Common.EasyPay.EasyPay.CheckFinishedPayments()
AzureBrightWorkerRole.dll!AzureBrightWorkerRole.WorkerRole.Run()
Microsoft.WindowsAzure.ServiceRuntime.dll!Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.StartRoleInternal()
Microsoft.WindowsAzure.ServiceRuntime.dll!Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.StartRole()
Microsoft.WindowsAzure.ServiceRuntime.dll!Microsoft.WindowsAzure.ServiceRuntime.Implementation.Loader.RoleRuntimeBridge.AnonymousMethod()
[External Code]
我访问的网络服务似乎停止了工作。最后,我发现,它与它无关!我在本地重现了错误,它发生在我的代码中。为什么我看不到错误发生的代码以及在哪些条件下?虽然我不能确定,但我不记得代码已被更改,并且今天已完成。
答案 0 :(得分:2)
当有一些代码要显示时,IntelliTrace只会显示源代码。
您发布的堆栈跟踪中的所有代码都在.Net框架内,因此没有源代码可以显示。
您可以从.Net Framework Reference Source获取源代码。
这个例外,以及许多类似的例外,都是ASP.Net内部的,应该被忽略。