从 ASP.net 中运行的 Web 参考客户端获取 RAW Soap 数据 [英] Getting RAW Soap Data from a Web Reference Client running in ASP.net

查看:17
本文介绍了从 ASP.net 中运行的 Web 参考客户端获取 RAW Soap 数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试对当前项目中的 Web 服务客户端进行故障排除.我不确定服务服务器的平台(很可能是 LAMP).我相信他们那边有问题,因为我已经消除了我客户的潜在问题.客户端是从服务 WSDL 自动生成的标准 ASMX 类型 Web 引用代理.

I'm trying to trouble shoot a web service client in my current project. I'm not sure of the platform of the Service Server (Most likely LAMP). I believe there is a fault on their side of the fence as i have eliminated the potential issues with my client. The client is a standard ASMX type web reference proxy auto generated from the service WSDL.

我需要的是原始 SOAP 消息(请求和响应)

What I need to get to is the RAW SOAP Messages (Request and Responses)

解决这个问题的最佳方法是什么?

What is the best way to go about this?

推荐答案

我在 web.config 中进行了以下更改以获得 SOAP(请求/响应)信封.这会将所有原始 SOAP 信息输出到文件 trace.log.

I made following changes in web.config to get the SOAP (Request/Response) Envelope. This will output all of the raw SOAP information to the file trace.log.

<system.diagnostics>
  <trace autoflush="true"/>
  <sources>
    <source name="System.Net" maxdatasize="1024">
      <listeners>
        <add name="TraceFile"/>
      </listeners>
    </source>
    <source name="System.Net.Sockets" maxdatasize="1024">
      <listeners>
        <add name="TraceFile"/>
      </listeners>
    </source>
  </sources>
  <sharedListeners>
    <add name="TraceFile" type="System.Diagnostics.TextWriterTraceListener"
      initializeData="trace.log"/>
  </sharedListeners>
  <switches>
    <add name="System.Net" value="Verbose"/>
    <add name="System.Net.Sockets" value="Verbose"/>
  </switches>
</system.diagnostics>

这篇关于从 ASP.net 中运行的 Web 参考客户端获取 RAW Soap 数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆