I am trying to create a webservice with ASP which will be given three parameters: a string, a date / time and Second string. After creating the method, wsdl includes:
& lt; S: element name = "timesheet audit"> & lt; S: complex type & gt; & Lt; S: Sequence & gt; & Lt; S: element minOccurs = "0" maxOccurs = "1" name = "employee number" type = "s: string" /> & Lt; S: element minOccurs = "1" maxOccurs = "1" name = "periodand date" type = "s: datetime" /> & Lt; S: element minOccurs = "0" maxOccurs = "1" name = "tilesheet" type = "s: string" /> & Lt; / S: Sequence & gt; & Lt; / S: complexType & gt; & Lt; / S: element & gt;
The black box calling my web service is complaining that there is a mismatch in the number of parameters I'm assuming because my webmaster is technically taking 1 parameter, a complex type, three Instead.
Is this a problem? If so, what can I do to overcome it?
Edit: In this case there is a consumer black box, I must cover my web service to match the caller. Adding
[SOAP document method (parameter style = SOAPPMATOR style. Bayer)]
to sign my method returns the following error: 'WS-I Does not conform to the original profile v1.1. Check out each violation of the standard statement below. To turn off the conformity check, set the ConformanceClaims property to the related WebServiceBinding attribute for WsClaims.None. R2204: A document-literal binding requires any description, in each of its soapbadi: body element (s), only wsdl: part element (elements) is defined using element attribute. - TargetNamespace = '' with the description of the service from the 'Part' input '' Timesheets AuditSoup Inn '' of the message. - TargetNamespace = '' from service description with 'TimesheetAuditResult' message 'TimesheetAuditSoapOut'.
the client is expecting , But this may be a parameter styling problem.
By default, an asp.net web service uses the "wrapped" parameter style, which means that all the parameters are sent to the same element that is sent inside the SOAP entity.
You can change the method declaration to use the "Plur" parameter style, which is achieved by ParameterStyle property on SoapDocumentMethodAttribute on this web method, without all the parameters directly inside the SOAP body. is.
See for details.
In conformity with the Compliance Error: You can disable the WS-Eye Confirmation probe by putting the following in your web.config:
& lt; Configuration & gt; & Lt; System.web & gt; & Lt; Webservices & gt; & Lt; ConformanceWarnings & gt; & Lt; Remove name = 'basicprofile 1_1' / & gt; & Lt; / ConformanceWarnings & gt; & Lt; / Webservices & gt; & Lt; /system.web> & Lt; / Configuration & gt;
Conformity is usually a good thing, but it is not necessary. Since you are not under the definition of definition in this matter, you do not like it much.
It is also possible that the client expects RPC-style web service instead of a document style web service (this will be controlled with SOPQQMAPTATT instead of SOPRPCMAAPT attribution.) If you have to close the conformant warning If you do not have any luck then you can try to change the RPC-style and see that it works.
And if in any way you can use a definition (source or better, a WSDL source) for the client, so that you can tell what it really is hoping for , It will help if you can get WSDL then you can create a web service system in the right format for yourself.
Comments
Post a Comment