Loading ...
Sorry, an error occurred while loading the content.

RE: [soaplite] Lite server, .NET client fails

Expand Messages
  • Chris Davies
    CD My SOAP::Lite client can communicate with the other person s .NET server. CD However, their .NET client can t communicate successfully with my CD
    Message 1 of 5 , May 21, 2002
    • 0 Attachment
      CD> My SOAP::Lite client can communicate with the other person's .NET
      server.
      CD> However, their .NET client can't communicate successfully with my
      CD> SOAP::Lite server. I'm using SOAP 0.55. The .NET client is the
      CD> Release version.

      DC> I'm currently doing a similar thing but using a SOAP::Lite client
      DC> with .Net server. Is it correct to have your server's returned
      DC> method 'TestIntResponse' in a different namespace to the returned
      DC> value 'stringLength'?

      CD> To be honest I haven't a clue whether it's correct or not. I use
      CD> SOAP without really understanding all of the underlying XML stuff.
      CD> Presumably Paul Kulchenko will have tested SOAP::Lite against .NET,
      CD> since he's created the interoperability guidelines, so I'm assuming
      CD> that I must just doing something wrongly.

      DC> Yes, but there's lots of flexibility with SOAP, so interopabilty
      DC> isn't as easy as it should be. My SOAP::Lite client doesn't put a
      DC> namespace on any of the elements thus letting them be in the
      DC> default namespace which is defined on the method element

      CD> How do you get perl to build your data packet? I do this on the
      CD> client side (as per Paul's interop guidelines):
      CD>
      CD> $p = SOAP::Data
      CD> -> type ('int')
      CD> -> name ('stringLength')
      CD> -> uri ('http://service.manheimeurope.com/SignalBox_001')
      CD> -> value ("how now, brown cow");
      CD> $result = $soap->TestString($p);

      DC> I think that the important thing is to ensure that all your XML
      DC> elements are in the same namespace. Your method element is in the
      DC> 'SignalBox_001; namespace, so should all your data elements
      DC> $p = SOAP::Data
      DC> -> type ('int')
      DC> -> name ('stringLength')
      DC> -> uri ('SignalBox_001')
      DC> -> value ("how now, brown cow");

      DC> Another approach is to put a default namespace definition on your
      DC> method element and then you don't need to specify a namespace for
      DC> the data elements. This is what I'm doing in my SOAP::Lite client:
      DC> my $r = $self->{soap}->call(
      DC> SOAP::Data->name('GetProductProfileBasic')->attr({xmlns => $ns}),
      DC> SOAP::Data->name(tpnb => $tpnb),
      DC> SOAP::Data->name(storeID => $storeID),
      DC> );

      DC> It seems to be non-trivial to do this for a SOAP::Lite server, so
      DC> see if the first way works.

      But that *is* what I (think I)'m doing - see my original post - and it's
      not working!

      ...unless a uri of 'http://service.manheimeurope.com/SignalBox_001'
      is different to one of simply 'SignalBox_001'?

      By the way, I've also tried using the attr({xmlns => $ns}) type stuff
      instead of using uri(), and that doesn't seem to help, either.

      Thanks,
      Chris
    Your message has been successfully submitted and would be delivered to recipients shortly.