Я новичок в веб-сервисах .NET и полностью запутался в этой проблеме. TCP Viewer показывает, что мое тестовое приложение, взаимодействующее с моим веб-сервисом, формирует свой XML следующим образом:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<GetSupply xmlns="http://webservices.florecom.org/commercial/customer/">
<Request>
<SupplyRequest>
<Header xmlns="urn:fec:florecom:xml:data:draft:SupplyStandardMessage:5">
<UserName>xxx</UserName>
<Password>xxx</Password>
<MessageDateTime>2012-01-17T14:59:44.0438037+02:00</MessageDateTime>
<MessageSerial>0</MessageSerial>
</Header>
<Body xmlns="urn:fec:florecom:xml:data:draft:SupplyStandardMessage:5">
<SupplyRequestDetails>
<SupplyRequestLine xmlns="urn:fec:florecom:xml:data:draft:ReusableAggregateBusinessInformationEntity:3"/>
</SupplyRequestDetails>
</Body>
</SupplyRequest>
</Request>
</GetSupply>
</s:Body>
</s:Envelope>
Но мой веб-сервис получает XML от другой компании, которая выглядит следующим образом:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<fsm:SupplyRequest xmlns:qdt="urn:un:unece:uncefact:data:draft:QualifiedDataType:5" xmlns:udt="urn:un:unece:uncefact:data:standard:UnqualifiedDataType:4" xmlns:ram="urn:un:unece:uncefact:data:draft:ReusableAggregateBusinessInformationEntity:3" xmlns:fsm="urn:fec:florecom:xml:data:draft:SupplyStandardMessage:5">
<fsm:Header>
<fsm:UserName>xxx</fsm:UserName>
<fsm:Password>xxx</fsm:Password>
<fsm:MessageID>634617184436505019</fsm:MessageID>
<fsm:MessageDateTime>2012-01-09T15:07:23.6505019+01:00</fsm:MessageDateTime>
<fsm:MessageSerial>0</fsm:MessageSerial>
</fsm:Header>
<fsm:Body>
<fsm:SupplyRequestDetails>
<SupplyRequestLine xmlns="urn:fec:florecom:xml:data:draft:ReusableAggregateBusinessInformationEntity:3"/>
</fsm:SupplyRequestDetails>
</fsm:Body>
</fsm:SupplyRequest>
</soap:Body>
</soap:Envelope>
Может кто-нибудь помочь объяснить, почему? Это разные версии SOAP? Спасибо
UPDATE
Интересно, что проблема, возникающая в этом сценарии (со вторым XML-сообщением), заключается в том, что при попадании в метод службы (используется точка останова для проверки этого и подделка сообщения с помощью Fiddler) .NET не удается привязать параметр метода (называемый «запрос»), чтобы его значение оставалось NULL