hic78
Messages postés1Date d'inscriptionjeudi 30 mars 2006StatutMembreDernière intervention30 mars 2006
-
30 mars 2006 à 22:30
jesusonline
Messages postés6814Date d'inscriptiondimanche 15 décembre 2002StatutMembreDernière intervention13 octobre 2010
-
31 mars 2006 à 17:18
Bonjour,
J'utilise un client proxy en C# pour interroger un web service SOAP/Java
Voici le code de la classe:
using System.Diagnostics;
using System.Xml.Serialization;
using System;
using System.Web.Services.Protocols;
using System.ComponentModel;
using System.Web.Services;
namespace PSA.Cfg.CfgPages.Classes.ConfiguratorClient
{
public class Flow : SoapHeader
{
public string Process;
}
/// <remarks/>
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Web.Services.WebServiceBindingAttribute(Name="cc", Namespace="cc:CarConfigurator")]
public class ConfigClient : System.Web.Services.Protocols.SoapHttpClientProtocol
{
/// Constructeur pour ne pas aller dans le web.config <remarks/>
public ConfigClient(string carConfigConnection)
{
this.Url = carConfigConnection;
}
public string config(string Request)
{
object[] results = this.Invoke("config", new object[] {Request});
//Ajout Trace
return ((string)(results[0]));
}
}
J'ai parfois le message d'erreur suivant:
Erreur application : System.InvalidOperationException;There is an error in XML document (5, 2).; at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, XmlDeserializationEvents events)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader)
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
at PSA.Cfg.CfgPages.Classes.ConfiguratorClient.ConfigClient.config(String Request)
Il se produit de temps en temps, c'est vraiment aléatoire
L'application est installée sur une ferme de 4 serveurs