小编Bri*_*ian的帖子

WSDL导出扩展中的周期性异常

我有一个已经运行了一个多月的SOAP服务.在过去的两周里,我们遇到了服务随机开始生成异常的情况.每次,它们似乎与导出扩展相关,并且错误总是沿着以下行:

调用WSDL导出扩展时抛出异常:System.ServiceModel.Description.DataContractSerializerOperationBehavior

使用"System.ArgumentException:命名节点来自不同的文档上下文." 似乎每次都是根本原因.

让我感到烦恼的是,这项服务在一个半月内没有改变,所以我很困惑我们突然间突然得到了争论错误.这是否表明存在潜在问题(内存泄漏或类似问题)?

我对运行的机器的访问权限非常有限,但可以根据需要尝试获取任何支持信息.这是wsdl回归的完整例外:

    An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:
    System.InvalidOperationException: An exception was thrown in a call to a WSDL export extension: System.ServiceModel.Description.DataContractSerializerOperationBehavior
     Endpoint: [endpoint name here... hidden for security] ----> System.ArgumentException: The named node is from a different document context.
       at System.Xml.XmlAttributeCollection.Append(XmlAttribute node)
       at System.ServiceModel.Description.SoapHelper.CreateSoapFaultBinding(String name, WsdlEndpointConversionContext endpointContext, FaultBinding wsdlFaultBinding, Boolean isEncoded)
       at System.ServiceModel.Description.MessageContractExporter.MessageBindingExporter.ExportMessageBinding(OperationDescription operation, Type messageContractExporterType)
       at System.ServiceModel.Description.WsdlExporter.CallExtension(WsdlEndpointConversionContext endpointContext, IWsdlExportExtension extension)
       --- End of inner ExceptionDetail stack trace ---
       at System.ServiceModel.Description.ServiceMetadataBehavior.MetadataExtensionInitializer.GenerateMetadata()
       at …
Run Code Online (Sandbox Code Playgroud)

c# wsdl web-services exception invalidoperationexception

10
推荐指数
2
解决办法
2025
查看次数