Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

soaplite · SOAP::Lite for Perl (soaplite.com)

The Yahoo! Groups Product Blog

Check it out!

Group Information

  • Members: 1205
  • Category: Protocols
  • Founded: Jan 28, 2001
  • Language: English
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Messages

Advanced
Messages Help
Messages 5988 - 6018 of 6629   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#5988 From: rahed <raherh@...>
Date: Wed Aug 1, 2007 10:00 am
Subject: Re: attribute name of "id"
raherh
Send Email Send Email
 
On 8/1/07, Robert Eden <rmeden@...> wrote:

>  The attribute with a name of "id" never shows up in the XML.  If I
>  change it do "idz" it does.
>
>  Is this a known issue?  Is there any way to get around it?

id/href pair attributes are used in soap to define uniquely its entities.
So rename them (or qualifiy them into a namespace).

--
Radek

#5989 From: "Thomas Eden" <thomas.eden@...>
Date: Wed Aug 1, 2007 2:22 pm
Subject: Re: attribute name of "id"
teden
Send Email Send Email
 
You can use XML::Simple or any other XML generation tool you want. Just make sure you specify the SOAP::Data->type("xml")->value($myXML).

Thom Eden

On 8/1/07, Robert Eden <rmeden@...> wrote:

Look at the following code...

$subscr= SOAP::Data
->name("subscription")
->type("subscription")
->attr({ subscriptionProfile => "OpenEGP", id => "3" })
->value( \SOAP::Data->value(
SOAP::Data->name("activationstatus" => 'A'),

The attribute with a name of "id" never shows up in the XML. If I
change it do "idz" it does.

Is this a known issue? Is there any way to get around it?

What if I use XML::Simple to generate my request... can I pass it to
the SOAP method? I tried, but it HTMLizes it. (changes < to &lt)

Robert



#5990 From: rahed <raherh@...>
Date: Thu Aug 2, 2007 9:03 am
Subject: Re: attribute name of "id"
raherh
Send Email Send Email
 
> Sorry.... I'm new to SOAP, hacking my way through this... I can't rename it,
> so how do I qualify it into a namespace?

Something like this:

$soap = SOAP::Data->name(subscr=>\SOAP::Data->value(
             SOAP::Data->name(tag1=>10)->attr({'n1:id'=>1}),
             SOAP::Data->name(tag2=>20)->attr({'n2:id'=>2})
                                            )
                                            )->attr({'xmlns:n1'=>"myns1",
                                                        'xmlns:n2'=>"myns2",});

Here the namespaces myns1 and myns2 are declared within the parent
element subscr with prefixes n1 and n2. Id attributes are then
qualified into these namespaces.

HTH

--
Radek

#5991 From: Ian Harisay <imharisa@...>
Date: Thu Aug 16, 2007 10:52 pm
Subject: need help building a client from a wsdl
imharisa@...
Send Email Send Email
 
Hi,

hopefully someone can help me make this work.  I just don't see what I
am doing wrong here.  I have written my client in Java.  The Java code
is working.  I would really like to get this to work under perl instead.

Working Java code block:

private static final String END_POINT =
             "http://206.210.94.165/keystone/services/External?wsdl";


     public static void main(String args[]) {
         String USER_IDENTIFIER = "test_user_000000002";
         String ORG_CODE = "MY_COMPANY";
         String DIGEST = "";
         String PART_NUMBER = "10071";
         String PROGRAM = "fit_for_life";
         String SEED = "9f05343d89fec4";

         try {

             // Create the digest for security when communicating from
3rd Party
             // To the SenseWear Application.
             String stamp = AuthenticationHandler.createTimestamp();
             DIGEST = AuthenticationHandler.createDigest(stamp,
USER_IDENTIFIER, SEED);

             External service = new External_Impl(END_POINT);
             ExternalPortType port =
service.getExternalSOAP11Port_Http();
             ExternalCreateUser user = new ExternalCreateUser();

             user.setUser(USER_IDENTIFIER);
             user.setOrgCode(ORG_CODE);
             user.setDigest(DIGEST);
             user.setProgram(PROGRAM);
             user.setTimestamp(stamp);
             user.setSubscription(PART_NUMBER);

             ExternalCreateUserResponse c_Response =
port.externalCreate(user);

             if (c_Response.getReturn().booleanValue()) {
                 System.out.println("--External User Created-- ");
                 System.out.println("Error Code: " +
c_Response.getCode());
             } else {
                 System.out.println("--External Create Failure--");
                 System.out.println("Error Code: " +
c_Response.getCode());
             }

         } catch (Exception ex) {
             System.out.println("Unable to create the ExternalStub");
             ex.printStackTrace();
         }


Perl code that doesn't work (yet :)

use strict;
use Digest::MD5 qw(md5_hex);
use Data::Dumper;
use Time::CTime;
use SOAP::Lite;

my $seed         = '9f05343d89fec4';
my $org_code     = 'MY_COMPANY';
my $user         = 'bill_the_user'.$$;
my $subscription = '10071';
my $program      = 'fit_for_life';
my $timestamp    = get_timestamp();
my $digest       = get_digest();

print "Connecting to Bodymedia web services...\n";
my $response  = SOAP::Lite
   ->service('http://206.210.94.165/keystone/services/External?wsdl')
   ->externalCreate(
      'orgCode'      => $org_code,
      'user'         => $user,
      'program'      => 'fit_weight',
      'subscription' => '10071',
      'digest'       => $digest,
      'timestamp'    => $timestamp);

print Dumper($response);

sub get_digest {
   return md5_hex($timestamp.$user.$seed);
}

sub get_timestamp {
   return strftime('%Y-%m-%d %X' ,localtime(time));
}

Thanks for any help I can get

#5992 From: "robertatelastica" <robert.nicholson@...>
Date: Sun Aug 26, 2007 2:59 pm
Subject: Why does this code no longer work? AWS
robertatelas...
Send Email Send Email
 
my $aws_wsdl =
"http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl";

   #Create a new SOAP::Lite instance, feeding it Amazon's WSDL
   my $aws_handle = SOAP::Lite->service("$aws_wsdl");

   my $request_complex_type = \SOAP::Data->value(
     SOAP::Data->name('ItemId')
     ->value($asin),
     SOAP::Data->name('IdType')
     ->value('ASIN'),
     SOAP::Data->name('Condition')
     ->value('All'),
     SOAP::Data->name('ResponseGroup')
     ->value('Large'));

   #my $itemlookup_request = SOAP::Data->value(
   #  SOAP::Data->name('SubscriptionId')
   #            ->value($subscription_id),
   #  SOAP::Data->name('Request')
   #            ->value($request_complex_type));

   my $itemlookup_request = SOAP::Data->value(
     SOAP::Data->name('MarketplaceDomain')
               ->value(''),
     SOAP::Data->name('SubscriptionId')
               ->value($subscription_id),
     SOAP::Data->name('Request')
               ->value($request_complex_type));

   my $results = $aws_handle->ItemLookup($itemlookup_request);

Anybody know why this results in

String value expected instead of SOAP::Data reference
  at /home/XXXXX/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm line 174

SOAP::XMLSchema1999::Serializer::as_string('SOAP::Serializer=HASH(0xa1a7158)',
'SOAP::Data=HASH(0x9aae9a0)', 'MarketplaceDomain', 'xs:string',
'HASH(0xa1abd44)') called at (eval
184)[/home/XXXXX/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm:2964] line 342

AWSECommerceService::_call('AWSECommerceService=HASH(0xa003b80)',
'ItemLookup', 'SOAP::Data=HASH(0x9aae9a0)') called at (eval
184)[/home/XXXXX/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm:2964] line 383
         AWSECommerceService::__ANON__[(eval
184)[/home/XXXXX/lib/perl5/site_perl/5.8.8/SOAP/Lite.pm:2964]:384]('AWSECommerce\
Service=HASH(0xa003b80)',
'SOAP::Data=HASH(0x9aae9a0)') called at filter.pl line 1319
XXXXX

#5993 From: rahed <raherh@...>
Date: Tue Aug 28, 2007 1:06 pm
Subject: Re: Why does this code no longer work? AWS
raherh
Send Email Send Email
 
On 8/26/07, robertatelastica <robert.nicholson@...> wrote:

> my $aws_wsdl =
>  "http://ecs.amazonaws.com/AWSECommerceService/AWSECommerceService.wsdl";
>
>  #Create a new SOAP::Lite instance, feeding it Amazon's WSDL
>    my $aws_handle = SOAP::Lite->service("$aws_wsdl");

You want to call your service like this:

$aws_handle->ItemLookup(SOAP::Data->name('myname'=>\SOAP::Data->value(SOAP::Data\
->name('myothername'=>'somevalue'))));

Trim it to your requirements. Value of a name attribute must be a
string or a reference.

--
Radek

#5994 From: "Mandeep" <mandeep_chd@...>
Date: Tue Aug 28, 2007 4:01 pm
Subject: Does SOAP:Lite has dependency on perl version ??
mandeep_chd
Send Email Send Email
 
Hi Friends,

I am new to the group. I want to use SOAP:Lite.

On my linux host the current perl version is

v5.6.1 built for i686-linux

I have two questions:

1) if I install the SOAP::Lite package on my linux host..will it
work or it has some dependency on the perl version?

2) During installation, will the SOAP::Lite package overwrite any
existing perl packages or libraries ?

Your help is really appreciated.

Regards,
Mandeep

#5995 From: "pokharel_ashish" <pokharel_ashish@...>
Date: Tue Aug 28, 2007 6:48 pm
Subject: putting attributes to xml element using SOAP::Lite
pokharel_ashish
Send Email Send Email
 
Hi everyone,

This might be a repeat of questions in earlier post but cant find one.
I would appreciate if anyone can help me figure out one small thing
here. I wanted to create a SOAP call as follows:

<soap:Body>
   <myFlow version="1.0">
	 <flow name="myName" action="start">
	      <auth>
	          <user>user</user>
                  <password>pass</password>
	      </auth>
	 </flow>
   </myFlow>
</soap:Body>

It seems most of it is pretty simple.

    my $mySoap = SOAP::Lite ->uri("myUri")
                            ->proxy("myProxy");

    my $method = SOAP::Data->name('myFlow');
    my @params = ( SOAP::Data->name("flow"=>
                  \SOAP::Data->name("auth" =>
                  \SOAP::Data->value(SOAP::Data->name("user"=>"user"),

                            SOAP::Data->name("password"=>"pass"))));
    my $soap = $mySoap->call($method => @params);

But by no means I can put the attributes to the elements for myFlow
and flow. Does anyone know a simple solution to this?

Thanks

#5996 From: "Mandeep" <mandeep_chd@...>
Date: Tue Aug 28, 2007 4:42 pm
Subject: Does SOAP:Lite has dependency on perl version ??
mandeep_chd
Send Email Send Email
 
Hi Friends,

I am new to the group. I want to use SOAP:Lite.

On my linux host the current perl version is

v5.6.1 built for i686-linux

I have two questions:

1) if I install the SOAP::Lite package on my linux host..will it
work or it has some dependency on the perl version?

2) During installation, will the SOAP::Lite package overwrite any
existing perl packages or libraries ?

Your help is really appreciated.

Regards,
Mandeep

#5997 From: "Darren Young" <darren.young@...>
Date: Wed Aug 29, 2007 10:59 pm
Subject: Perl SOAP::Lite Server and a C# client
darren_young
Send Email Send Email
 
I'm trying to place a SOAP::Lite service up that needs to service C#
clients and it's just not working. What I have so far...

The SOAP::Lite server:

[root@gsbsfn1 cgi-bin]# cat test.cgi
#!/usr/bin/perl -w

use SOAP::Transport::HTTP;

SOAP::Transport::HTTP::CGI
   -> dispatch_to('Demo')
   -> handle;

package Demo;

sub new {
     bless {}, shift;
};

sub hi {
     my ($self) = @_;
     return "hello, world";
}

1;

The C# code (using Visual Studio 2005):

// s.cs
using System;

class TestApp
{
	 [STAThread]
	 static void Main()
	 {
		 SSim ssim = new SSim();
		 Console.WriteLine("SSim.hi: "+ssim.hi());
	 }
}

//ssim.cs
using System.Diagnostics;
using System.Xml.Serialization;
using System;
using System.Web.Services.Protocols;
using System.ComponentModel;
using System.Web.Services;


[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Web.Services.WebServiceBindingAttribute(Name="SSimSoap",Namespace="Demo"
)]

public class SSim : System.Web.Services.Protocols.SoapHttpClientProtocol {

	 public SSim() {
		 this.Url = "http://128.135.211.10/cgi-bin/test.cgi";
	 }

[System.Web.Services.Protocols.SoapDocumentMethodAttribute(
	 "Demo#hi",
	 RequestNamespace="Demo",
	 ResponseNamespace="Demo",
	 Use=System.Web.Services.Description.SoapBindingUse.Literal,
	 ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]


	 public string hi() {
		 object[] results = this.Invoke("hi", new object[0]);
		 return ((string)(results[0]));
	 }
}

a working perl client:

#!/usr/bin/perl -w

use SOAP::Lite +debug;
# use SOAP::Lite;

print SOAP::Lite
     -> uri('Demo')
     -> proxy('http://128.135.211.10/cgi-bin/test.cgi')
     -> hi()
     -> result . "\n";

debug output from that client:

SOAP::Transport::new: ()
SOAP::Serializer::new: ()
SOAP::Deserializer::new: ()
SOAP::Parser::new: ()
SOAP::Lite::new: ()
SOAP::Transport::HTTP::Client::new: ()
SOAP::Lite::call: ()
SOAP::Serializer::envelope: ()
SOAP::Serializer::envelope: hi
SOAP::Data::new: ()
SOAP::Data::new: ()
SOAP::Data::new: ()
SOAP::Data::new: ()
SOAP::Transport::HTTP::Client::send_receive: HTTP::Request=HASH(0x8072aac)
SOAP::Transport::HTTP::Client::send_receive: POST
http://128.135.211.10/cgi-bin/test.cgi HTTP/1.1
Accept: text/xml
Accept: multipart/*
Accept: application/soap
Content-Length: 401
Content-Type: text/xml; charset=utf-8
SOAPAction: "Demo#hi"

<?xml version="1.0" encoding="UTF-8"?><soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><hi
xmlns="Demo" xsi:nil="true" /></soap:Body></soap:Envelope>
SOAP::Transport::HTTP::Client::send_receive:
HTTP::Response=HASH(0x8545294)
SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 200 OK
Connection: close
Date: Wed, 29 Aug 2007 22:51:52 GMT
Server: Apache/2.0.52 (Red Hat)
Content-Length: 462
Content-Type: text/xml; charset=utf-8
Client-Date: Wed, 29 Aug 2007 22:51:52 GMT
Client-Peer: 128.135.211.10:80
Client-Response-Num: 1
SOAPServer: SOAP::Lite/Perl/0.69

<?xml version="1.0" encoding="UTF-8"?><soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Body><hiResponse
xmlns="Demo"><s-gensym3 xsi:type="xsd:string">hello,
world</s-gensym3></hiResponse></soap:Body></soap:Envelope>
SOAP::Deserializer::deserialize: ()
SOAP::Parser::decode: ()
SOAP::SOM::new: ()
hello, world
SOAP::Lite::DESTROY: ()
SOAP::Deserializer::DESTROY: ()
SOAP::Parser::DESTROY: ()
SOAP::Transport::DESTROY: ()
SOAP::Transport::HTTP::Client::DESTROY: ()
SOAP::SOM::DESTROY: ()
SOAP::Serializer::DESTROY: ()
SOAP::Data::DESTROY: ()
SOAP::Data::DESTROY: ()
SOAP::Data::DESTROY: ()
SOAP::Data::DESTROY: ()

What the C# command line client does (basically nothing):

SSim.hi:

The apache access log shows the inbound request to the test.cgi script:

128.135.211.176 - - [29/Aug/2007:17:55:15 -0500] "POST
/cgi-bin/test.cgi HTTP/1.1" 200 462 "-" "Mozilla/4.0 (compatible; MSIE
6.0; MS Web Services Client Protocol 2.0.50727.832)"


I know VERY little about C#, I'm writing the Perl SOAP service to sit
on top of a bunch of existing Perl code so I can expose that
functionality to the C# coders/consumers here. I need to verify that
this in fact can be done and give them a sample of some working C#
code that they can use to start with.

Any help would be most appreciated.

#5998 From: "rawill4u" <rawill4u@...>
Date: Wed Aug 22, 2007 3:08 pm
Subject: Need additional info on setting up complex data types
rawill4u
Send Email Send Email
 
I need to create an xml body that looks like this:
<Input_1>
  <Input_data>
      <data1 xsi:type="xsd:string">xxxx</data1>
      <data2 xsi:type="xsd:string">xxxxx</data1>
  </Input_data>
<Processing_options>
      <option1 xsd:type="xsd:boolean">1</option1>
      <option2 xsd:type="xsd:boolean">1</option2>
</Processing_options>
</Input_1>

The closest I have gotten is this:
<Input_1>
  <Input_data>
      <data1 xsi:type="xsd:string">xxxx</data1>
      <data2 xsi:type="xsd:string">xxxxx</data1>
  </Input_data>
</Input_1>
<Input_1>
<Processing_options>
      <option1 xsd:type="xsd:boolean">1</option1>
      <option2 xsd:type="xsd:boolean">1</option2>
</Processing_options>
</Input_1>

The code I am using is this:
SOAP::Data->name("Input_1" =>
\SOAP::Data->value(
SOAP::Data->name("Input_data" =>
\SOAP::Data->value(
SOAP::Data->type('string')->name("data1" => $value1),
SOAP::Data->type('string')->name("data2" => $value2)))),
\SOAP::Data->value(
SOAP::Data->name("options" =>
\SOAP::Data->value(
SOAP::Data->type('boolean')->name("option1" => $option1),
SOAP::Data->type('boolean')->name("option2" => $option2)))));


What am I doing wrong? From all of the things I have read this looks
like it should work.

Second question the service I am trying to use represents the
boolean values as true or false....not 1 or 0.  How do I get the
boolean values to be sent that way.

#5999 From: "warren_m_smith" <warren@...>
Date: Mon Aug 13, 2007 8:27 pm
Subject: Accepting Goofy MSMQ Message
warren_m_smith
Send Email Send Email
 
I'm trying to accept SOAP requests from a MSMQ server, but MSMQ is
sending some malformed messages, which I just have to accept and deal
with [example below].

I've solved some of the problems [detailed below, as well] myself, but
cannot figure out how to process a message with an empty body (other
than injecting xml which seems like a bit of a kludge). Any ideas?

-Warren


* DIME Message boundary not on its own line

MIME::Tools reads message line-by-line. Created new packager,
overriding SOAP::Package::MIME::unpackage to inject a newline before
message boundaries if they don't exist.

* Non-standard header elements have mustUnderstand="1" attributes

Worked around by disabling MUSTUNDERSTAND checks.

* SOAPAction: "MSMQMessage"

Values for SOAPAction must be in format uri#anchor. Worked around by
creating an empty on_action() handler.

* Empty Envelope Body



Host: zippy
Content-Length: 1186
Content-Type: multipart/related; boundary="MSMQ - SOAP boundary,
16118"; type=text/xml
Proxy-Accept: NonInteractiveClient
SOAPAction: "MSMQMessage"

--MSMQ - SOAP boundary, 16118
Content-Type: text/xml; charset=UTF-8
Content-Length: 859

<se:Envelope xmlns:se="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="http://schemas.xmlsoap.org/srmp/"><se:Header><path
xmlns="http://schemas.xmlsoap.org/rp/"
se:mustUnderstand="1"><action>MSMQ:this is my
label</action><to>HTTP://zippy:8890/msmq/private$/test_queue</to><rev><via>HTTP:\
//zippy:8890/msmq/private$/test_queue</via></rev><id>uuid:8194@5a6842ad-2573-4db\
9-b21a-658bb3973cbf</id></path><properties
se:mustUnderstand="1"><expiresAt>20380119T031407</expiresAt><sentAt>20070813T174\
236</sentAt></properties><Msmq
xmlns="msmq.namespace.xml"><Class>0</Class><Priority>1</Priority><Correlation>AA\
AAAAAAAAAAAAAAAAAAAAAAAAA=</Correlation><App>42</App><BodyType>0</BodyType><Hash\
Algorithm>32772</HashAlgorithm><SourceQmGuid>5a6842ad-2573-4db9-b21a-658bb3973cb\
f</SourceQmGuid><TTrq>20071111T174236</TTrq></Msmq></se:Header><se:Body></se:Bod\
y></se:Envelope>--MSMQ
- SOAP boundary, 16118
Content-Type: application/octet-stream
Content-Length: 53
Content-Id: body@5a6842ad-2573-4db9-b21a-658bb3973cbf

<?xml version="1.0"?>
<string>just testing!</string>--MSMQ - SOAP boundary, 16118--

#6000 From: "Allan" <StevenD@...>
Date: Fri Aug 24, 2007 6:28 am
Subject: Can't install SOAP::Lite on linux with CPAN
gaah68114
Send Email Send Email
 
Hi,

Can't complete an installation.  May I post the installation messages
to see if anyone has a recommendation or help.  I'm kind of a newbie
at CPAN.


cpan[3]> install SOAP::Lite
Running install for module 'SOAP::Lite'
Running make for B/BY/BYRNE/SOAP-Lite-0.69.tar.gz
   Has already been unwrapped into directory /root/.cpan/build/SOAP-
Lite-0.69-fgrBz6
   Has already been made
Running make test
PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-
e" "test_harness(0, 'blib/lib', 'blib/arch')" t/01-core.t t/02-
payload.t t/03-server.t t/04-attach.t t/05-customxml.t t/06-modules.t
t/07-xmlrpc_payload.t t/08-schema.t
t/01-core..............ok
t/02-payload...........ok
t/03-server............ok
         2/32 skipped: various reasons
t/04-attach............ok
t/05-customxml.........ok
t/06-modules...........FAILED tests 15, 19
         Failed 2/19 tests, 89.47% okay
t/07-xmlrpc_payload....ok
t/08-schema............ok
Failed Test    Stat Wstat Total Fail  List of Failed
----------------------------------------------------------------------
---------
t/06-modules.t               19    2  15 19
2 subtests skipped.
Failed 1/8 test scripts. 2/321 subtests failed.
Files=8, Tests=321,  3 wallclock secs ( 2.61 cusr +  0.27 csys =
2.88 CPU)
Failed 1/8 test programs. 2/321 subtests failed.
make: *** [test_dynamic] Error 11
   BYRNE/SOAP-Lite-0.69.tar.gz
   /usr/bin/make test -- NOT OK
Warning (usually harmless): 'YAML' not installed, will not store
persistent state
Running make install
   make test had returned bad status, won't install without force
Failed during this command:
  BYRNE/SOAP-Lite-0.69.tar.gz                  : make_test NO


I'd appreciate any guidance.  Thanks so much.
--Steve D.

#6001 From: Eric Bridger <eric@...>
Date: Thu Aug 30, 2007 2:23 pm
Subject: Re: putting attributes to xml element using SOAP::Lite
ebridger2004
Send Email Send Email
 
You can use the SOAP::Data->attr method to set attributes. Note: attr
takes a hash reference as it's argument.
E.g.

\SOAP::Data->attr(  { 'name' => 'myName' } )->name( 'flow');
Actually you need two attributes:

\SOAP::Data->attr(  { 'name' => 'myName' , 'action' => 'start' } )-
  >name( 'flow');

On Aug 28, 2007, at 2:48 PM, pokharel_ashish wrote:

> Hi everyone,
>
> This might be a repeat of questions in earlier post but cant find one.
> I would appreciate if anyone can help me figure out one small thing
> here. I wanted to create a SOAP call as follows:
>
> <soap:Body>
> <myFlow version="1.0">
> <flow name="myName" action="start">
> <auth>
> <user>user</user>
> <password>pass</password>
> </auth>
> </flow>
> </myFlow>
> </soap:Body>
>
> It seems most of it is pretty simple.
>
> my $mySoap = SOAP::Lite ->uri("myUri")
> ->proxy("myProxy");
>
> my $method = SOAP::Data->name('myFlow');
> my @params = ( SOAP::Data->name("flow"=>
> \SOAP::Data->name("auth" =>
> \SOAP::Data->value(SOAP::Data->name("user"=>"user"),
>
> SOAP::Data->name("password"=>"pass"))));
> my $soap = $mySoap->call($method => @params);
>
> But by no means I can put the attributes to the elements for myFlow
> and flow. Does anyone know a simple solution to this?
>
> Thanks
>
>
>

#6002 From: Craig Dunigan <cdunigan@...>
Date: Thu Aug 30, 2007 2:33 pm
Subject: Re: Can't install SOAP::Lite on linux with CPAN
craigdunigan62
Send Email Send Email
 
I'm only marginally competent at SOAP::Lite, but I darn sure can help
with CPAN.

I just tried this myself, and it looks like this results from missing
modules.

At the CPAN prompt, enter 'look SOAP::Lite' to go into the build
directory for SOAP::Lite.  'cd t' to enter the directory containing
the tests, and run 'perl 06-modules.t'.  That should give you a clear
idea of what's failing, and why, and if it's missing modules, which
ones are missing.  'exit' to go back to the CPAN prompt and install
the missing modules.  I'm *guessing* that you can skip any modules for
functionality you won't be using, like Net::Jabber, which came up for
me.  The critical one appears to be XML::Parser::Lite.

Now before you try again to install SOAP::Lite, enter 'clean
SOAP::Lite'.  That should generally be done for any failed CPAN
installation before you try it again.


On Fri, 24 Aug 2007, Allan wrote:

> Hi,
>
> Can't complete an installation.  May I post the installation messages
> to see if anyone has a recommendation or help.  I'm kind of a newbie
> at CPAN.
>
>
> cpan[3]> install SOAP::Lite
> Running install for module 'SOAP::Lite'
> Running make for B/BY/BYRNE/SOAP-Lite-0.69.tar.gz
>  Has already been unwrapped into directory /root/.cpan/build/SOAP-
> Lite-0.69-fgrBz6
>  Has already been made
> Running make test
> PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-
> e" "test_harness(0, 'blib/lib', 'blib/arch')" t/01-core.t t/02-
> payload.t t/03-server.t t/04-attach.t t/05-customxml.t t/06-modules.t
> t/07-xmlrpc_payload.t t/08-schema.t
> t/01-core..............ok
> t/02-payload...........ok
> t/03-server............ok
>        2/32 skipped: various reasons
> t/04-attach............ok
> t/05-customxml.........ok
> t/06-modules...........FAILED tests 15, 19
>        Failed 2/19 tests, 89.47% okay
> t/07-xmlrpc_payload....ok
> t/08-schema............ok
> Failed Test    Stat Wstat Total Fail  List of Failed
> ----------------------------------------------------------------------
> ---------
> t/06-modules.t               19    2  15 19
> 2 subtests skipped.
> Failed 1/8 test scripts. 2/321 subtests failed.
> Files=8, Tests=321,  3 wallclock secs ( 2.61 cusr +  0.27 csys =
> 2.88 CPU)
> Failed 1/8 test programs. 2/321 subtests failed.
> make: *** [test_dynamic] Error 11
>  BYRNE/SOAP-Lite-0.69.tar.gz
>  /usr/bin/make test -- NOT OK
> Warning (usually harmless): 'YAML' not installed, will not store
> persistent state
> Running make install
>  make test had returned bad status, won't install without force
> Failed during this command:
> BYRNE/SOAP-Lite-0.69.tar.gz                  : make_test NO
>
>
> I'd appreciate any guidance.  Thanks so much.
> --Steve D.
>
>
>

--
Craig Dunigan
IS Technical Services Specialist
Middleware - EIS - DoIT
University of Wisconsin, Madison

opinions expressed are my own, not the University's

#6003 From: rahed <raherh@...>
Date: Thu Aug 30, 2007 4:47 pm
Subject: Re: Can't install SOAP::Lite on linux with CPAN
raherh
Send Email Send Email
 
In the beginning of the installation you are asked which optional
modules are to be installed.

Failed tests 15 and 19 are Apache modules which are not necessary for
basic soap operation.

--
Radek

#6004 From: Morgan Fletcher <morgan@...>
Date: Fri Aug 31, 2007 12:04 am
Subject: Encoding text from server
fnagrom
Send Email Send Email
 
I am querying a service like so:

     $response = SOAP::Lite
         ->service("http://thing1.thing2.com:10000/FOO.wsdl")
         -> getId("$r");

Some of the records I get contain characters like this: \205 \256.
(represented as best I can) When I get a record like that I get:

not well-formed (invalid token) at line 44, column 106, byte 2658 at
/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi/XML/Parser.pm
line 187

Should I be encoding this text somehow, from the client end, so that I
don't get this XML Parser error? If so, how?

Morgan

#6005 From: "Hans Poo" <hans@...>
Date: Fri Aug 31, 2007 12:24 am
Subject: Re: Can't install SOAP::Lite on linux with CPAN
hanspoo
Send Email Send Email
 
Hi,

If you're on a Debian based, my case ubuntu, you may tray to find the
package with:

# apt-cache search -n perl|grep soap
libsoap-lite-perl - Client and server side SOAP implementation

in this case i found it in the normal repositories, then you can install:
# apt-get install libsoap-lite-perl

after that, you like to know where the files were installed:
# dpkg -L libsoap-lite-perl

If you're on a redhat base distro, you can find with yum or up2date to
do the same, i left fedora
some years from now.. don't have the exact commands.

Important: For complex packages with lot of dependencies, the distro
package is the fast way to do it.

If you don't have the package in the distro, or you just like (or
have) to install from source,
then, beware that CPAN installers complain a lot due to failed tests,
normally things work besides
the comlplaints, but you should check.

First, you should try forcing CPAN:

# get into the interactive installer with
# perl -MCPAN -e shell

# force the installation, please don't forget to say "no" to the
standard tests
force install SOAP::Lite

[ this should be done as root ]

If it fails, i recommend to go where the CPAN module stores the cache
of modules:
# cd ~/.cpan/build

Then cd to the directory of your module. After the above commands you
should find a module called
SOAP-Lite-0.XX, i've just done this an it's SOAP-Lite-0.69.

cd SOAP-Lite-0.69

Then, please take some minutes to read the README file,
# less README

.. then issue
# perl Makefile.PL
# make

Normally problems arise doing the last two commands, but, you will
have more information of how to
solve them.

finally [ as root ]
# make install

Good Luck
Hans


--- In soaplite@yahoogroups.com, "Allan" <StevenD@...> wrote:
>
> Hi,
>
> Can't complete an installation.  May I post the installation messages
> to see if anyone has a recommendation or help.  I'm kind of a newbie
> at CPAN.
>
>
> cpan[3]> install SOAP::Lite
> Running install for module 'SOAP::Lite'
> Running make for B/BY/BYRNE/SOAP-Lite-0.69.tar.gz
>   Has already been unwrapped into directory /root/.cpan/build/SOAP-
> Lite-0.69-fgrBz6
>   Has already been made
> Running make test
> PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-
> e" "test_harness(0, 'blib/lib', 'blib/arch')" t/01-core.t t/02-
> payload.t t/03-server.t t/04-attach.t t/05-customxml.t t/06-modules.t
> t/07-xmlrpc_payload.t t/08-schema.t
> t/01-core..............ok
> t/02-payload...........ok
> t/03-server............ok
>         2/32 skipped: various reasons
> t/04-attach............ok
> t/05-customxml.........ok
> t/06-modules...........FAILED tests 15, 19
>         Failed 2/19 tests, 89.47% okay
> t/07-xmlrpc_payload....ok
> t/08-schema............ok
> Failed Test    Stat Wstat Total Fail  List of Failed
> ----------------------------------------------------------------------
> ---------
> t/06-modules.t               19    2  15 19
> 2 subtests skipped.
> Failed 1/8 test scripts. 2/321 subtests failed.
> Files=8, Tests=321,  3 wallclock secs ( 2.61 cusr +  0.27 csys =
> 2.88 CPU)
> Failed 1/8 test programs. 2/321 subtests failed.
> make: *** [test_dynamic] Error 11
>   BYRNE/SOAP-Lite-0.69.tar.gz
>   /usr/bin/make test -- NOT OK
> Warning (usually harmless): 'YAML' not installed, will not store
> persistent state
> Running make install
>   make test had returned bad status, won't install without force
> Failed during this command:
>  BYRNE/SOAP-Lite-0.69.tar.gz                  : make_test NO
>
>
> I'd appreciate any guidance.  Thanks so much.
> --Steve D.
>

#6006 From: Hugues de Mazancourt <hugues@...>
Date: Fri Aug 31, 2007 8:46 am
Subject: Re: Encoding text from server
hdemazancourt
Send Email Send Email
 

Le 31 août 07 à 02:04, Morgan Fletcher a écrit :

I am querying a service like so:

$response = SOAP::Lite
->service("http://thing1.thing2.com:10000/FOO.wsdl")
-> getId("$r");

Some of the records I get contain characters like this: \205 \256. 
(represented as best I can) When I get a record like that I get:

There's a *real* problem with the way Perl handles UFT-8 strings (or what it this is Unicode strings). You can't really predict what will happen to non-ASCII data when different packages, layers, system variables (such as LANG) are involved.
My solution to these problems was to Base64-encode/decode all data before sending them over the network.
See MIME::Base64 package

Best,

Hugues


#6007 From: Morgan Fletcher <morgan@...>
Date: Fri Aug 31, 2007 3:21 pm
Subject: Re: Encoding text from server
fnagrom
Send Email Send Email
 
Hugues de Mazancourt wrote:
>
> Le 31 août 07 à 02:04, Morgan Fletcher a écrit :
>
>> I am querying a service like so:
>>
>> $response = SOAP::Lite
>> ->service("http://thing1.thing2.com:10000/FOO.wsdl
>> <http://thing1.thing2.com:10000/FOO.wsdl>")
>> -> getId("$r");
>>
>> Some of the records I get contain characters like this: \205 \256.
>> (represented as best I can) When I get a record like that I get:
>
> There's a *real* problem with the way Perl handles UFT-8 strings (or
> what it this is Unicode strings). You can't really predict what will
> happen to non-ASCII data when different packages, layers, system
> variables (such as LANG) are involved.
> My solution to these problems was to Base64-encode/decode all data
> before sending them over the network.
> See MIME::Base64 package

Did you encode them on the server side? I can't modify what comes from
the web service, it's vendor-provided.

Morgan

#6008 From: Hugues de Mazancourt <hugues@...>
Date: Fri Aug 31, 2007 4:57 pm
Subject: Re: Encoding text from server
hdemazancourt
Send Email Send Email
 

Le 31 août 07 à 17:21, Morgan Fletcher a écrit :

Did you encode them on the server side? I can't modify what comes from 
the web service, it's vendor-provided.

Fortunately (for me), I'm on the server side.
I don't know if there's any way to trap the message before it is passed to the XML parser. I guess it would be a solution.


Hugues

#6010 From: Morgan Fletcher <morgan@...>
Date: Tue Sep 4, 2007 7:13 pm
Subject: Re: Encoding text from server
fnagrom
Send Email Send Email
 
Morgan Fletcher wrote:
> I am querying a service like so:
>
> $response = SOAP::Lite
> ->service("http://thing1.thing2.com:10000/FOO.wsdl
> <http://thing1.thing2.com:10000/FOO.wsdl>")
> -> getId("$r");
>
> Some of the records I get contain characters like this: \205 \256.
> (represented as best I can) When I get a record like that I get:
>
> not well-formed (invalid token) at line 44, column 106, byte 2658 at
> /usr/lib/perl5/
>
> vendor_perl/5.8.5/i386-linux-thread-multi/XML/Parser.pm
> line 187
>
> Should I be encoding this text somehow, from the client end, so that I
> don't get this XML Parser error? If so, how?
>

Replying to myself; the vendor fixed this on the server side.

Thanks for the feedback.

Morgan

#6011 From: "alexfranco73" <messenger@...>
Date: Wed Sep 12, 2007 10:44 am
Subject: How pass stringArray in WSDL as parameter
alexfranco73
Send Email Send Email
 
Hello!
I m getting crazy. I m trying to comunicate with a service what
requires stringArray as one of the parameters. Sending Integer or
String works fine, but when i try to send an array or an asociative
array the service receive empty.

Here is my code:

my $client = SOAP::Lite -> service
("http://services.enviosmasivos.net/ws/UserService.php?wsdl");
$token = $client->authenticate($userpush, $passpush);
my $client2 = SOAP::Lite -> service
("http://services.enviosmasivos.net/ws/SendService.php?wsdl");

$usuario=$userpush;
@tlfs=('34666666666','34666666667');
$message="Mensaje de prueba del servicio de alertas www.pushsms.es";
$sender="INFO";
$title="ALERTA";
$type=1;

$envio = $client2->send('token' => $token, 'user'
=> '$usuario', 'tlfs'=>@tlfs, 'message'=>$message, 'sender'=>$sender,
'title'=> $title, 'type'=>$type);


@tlfs is being received like empty array. I m really lost and dont
know what else to try. I accept any ideas :)

Thanks all of you for your time and help.

#6012 From: "Mike" <mw487@...>
Date: Thu Sep 13, 2007 9:14 am
Subject: working client example for ops.espacenet.com : WSDL, MIME attachment
mw487
Send Email Send Email
 
#!/usr/bin/perl -w

use SOAP::Lite; # +trace => ['debug'] ; print 'SOAP Lite version ',
$SOAP::Lite::VERSION ,"\n";  #tested on 0.69
use MIME::Entity;

my $soap = SOAP::Lite->new();
$soap->proxy('http://ops.espacenet.com/OpenPatentServices/webService');
$soap->ns('urn:EPO-OpenPatentServices');
$soap->service('http://ops.espacenet.com/OpenPatentServices/webService/getPatent\
Data?wsdl'
);
my $req_xml;

#$req_xml  = '<OpenPatentServices
ACTION="Biblio">'.'<WORLDPATENTDATA><BIBLIO SEED="EP1000000"
SEED_FORMAT="E"
SEED_TYPE="PN"/>'.'</WORLDPATENTDATA></OpenPatentServices>';
#$req_xml  = '<OpenPatentServices
ACTION="FamilyAndLegalAndBiblio"><WORLDPATENTDATA><FAMILY SEED=" US
5000063%%" SEED_FORMAT="D" SEED_TYPE="PN" DESC_LNG="ENG"
DATE_MIGR="00000000"
LEGAL="YES"/></WORLDPATENTDATA></OpenPatentServices>';
$req_xml = '<OpenPatentServices
ACTION="Claims"><WORLDPATENTDATA><BIBLIO SEED="EP1000000"
SEED_FORMAT="E" SEED_TYPE="PN"/></WORLDPATENTDATA></OpenPatentServices>';
my $som = $soap->getPatentData($req_xml);

if ( $som->fault ) {    # will be defined if Fault element is in the
message
	 print $som->faultstring;    # returns value of 'detail' element as
}
else {print "no error. \n";print $som->result, "\n";
}

$req_xml = '<OpenPatentServices
ACTION="DocumentInquiry"><WORLDPATENTDATA><INQUIRY SEED="EP1000000"
SEED_FORMAT="E" SEED_TYPE="PN"/></WORLDPATENTDATA></OpenPatentServices>';
$som = $soap->getPatentData($req_xml);
print 'result: "', $som->result, "\"\n\n";

$req_xml = '<OpenPatentServices
ACTION="DocumentRetrieval"><WORLDPATENTDATA><DOCUMENT ID="EP
1000000PAFP " SYSTEM="BNS" FORMAT="SINGLE_PAGE_TIFF"
PAGE_NUMBER="1"/></WORLDPATENTDATA></OpenPatentServices>';

#$req_xml  = '<OpenPatentServices
ACTION="DocumentRetrieval"><WORLDPATENTDATA><DOCUMENT ID="EP
1000000PAFP " SYSTEM="BNS" FORMAT="SINGLE_PAGE_PDF"
PAGE_NUMBER="1"/></WORLDPATENTDATA></OpenPatentServices>';

# change the namespace!  eliminate the error.
$soap-> ns('urn:EPO-OpenPatentServices-documentData');
$som = $soap->getDocumentData($req_xml);

if ( $som->fault ) {    # will be defined if Fault element is in the
message
	 print $som->faultstring;    # returns value of 'detail' element
}
else {
	 my $mime_entity = ${ $som->parts }[0];
	 my $body        = $mime_entity->bodyhandle;
	 open( OUT, '>1.tif' ) or die "whoops $!";

	 #open ( OUT , '>1.pdf' ) or die "whoops $!" ;
	 binmode(OUT);
	 print OUT $body->as_string;
	 close OUT;
	 print "no error with Document Retrieval; check file system for
output.\n";
}

# watch for embedded spaces and html encoding
# - show source, or use the base 64 attachment.
# and http://www.motobit.com/util/base64-decoder-encoder.asp

IyEvdXNyL2Jpbi9wZXJsIC13DQoNCnVzZSBTT0FQOjpMaXRlOyAjICt0cmFjZSA9PiBbJ2RlYnVn
J10gOyBwcmludCAnU09BUCBMaXRlIHZlcnNpb24gJywgJFNPQVA6OkxpdGU6OlZFUlNJT04gLCJc
biI7ICAjdGVzdGVkIG9uIDAuNjkNCnVzZSBNSU1FOjpFbnRpdHk7DQoNCm15ICRzb2FwID0gU09B
UDo6TGl0ZS0+bmV3KCk7DQokc29hcC0+cHJveHkoJ2h0dHA6Ly9vcHMuZXNwYWNlbmV0LmNvbS9P
cGVuUGF0ZW50U2VydmljZXMvd2ViU2VydmljZScpOw0KJHNvYXAtPm5zKCd1cm46RVBPLU9wZW5Q
YXRlbnRTZXJ2aWNlcycpOw0KJHNvYXAtPnNlcnZpY2UoJ2h0dHA6Ly9vcHMuZXNwYWNlbmV0LmNv
bS9PcGVuUGF0ZW50U2VydmljZXMvd2ViU2VydmljZS9nZXRQYXRlbnREYXRhP3dzZGwnDQopOw0K
bXkgJHJlcV94bWw7DQoNCiMkcmVxX3htbCAgPSAnPE9wZW5QYXRlbnRTZXJ2aWNlcyBBQ1RJT049
IkJpYmxpbyI+Jy4nPFdPUkxEUEFURU5UREFUQT48QklCTElPIFNFRUQ9IkVQMTAwMDAwMCIgU0VF
RF9GT1JNQVQ9IkUiIFNFRURfVFlQRT0iUE4iLz4nLic8L1dPUkxEUEFURU5UREFUQT48L09wZW5Q
YXRlbnRTZXJ2aWNlcz4nOw0KIyRyZXFfeG1sICA9ICc8T3BlblBhdGVudFNlcnZpY2VzIEFDVElP
Tj0iRmFtaWx5QW5kTGVnYWxBbmRCaWJsaW8iPjxXT1JMRFBBVEVOVERBVEE+PEZBTUlMWSBTRUVE
PSIgVVMgNTAwMDA2MyUlIiBTRUVEX0ZPUk1BVD0iRCIgU0VFRF9UWVBFPSJQTiIgREVTQ19MTkc9
IkVORyIgREFURV9NSUdSPSIwMDAwMDAwMCIgTEVHQUw9IllFUyIvPjwvV09STERQQVRFTlREQVRB
PjwvT3BlblBhdGVudFNlcnZpY2VzPic7DQokcmVxX3htbCA9ICc8T3BlblBhdGVudFNlcnZpY2Vz
IEFDVElPTj0iQ2xhaW1zIj48V09STERQQVRFTlREQVRBPjxCSUJMSU8gU0VFRD0iRVAxMDAwMDAw
IiBTRUVEX0ZPUk1BVD0iRSIgU0VFRF9UWVBFPSJQTiIvPjwvV09STERQQVRFTlREQVRBPjwvT3Bl
blBhdGVudFNlcnZpY2VzPic7DQpteSAkc29tID0gJHNvYXAtPmdldFBhdGVudERhdGEoJHJlcV94
bWwpOw0KDQppZiAoICRzb20tPmZhdWx0ICkgeyAgICAjIHdpbGwgYmUgZGVmaW5lZCBpZiBGYXVs
dCBlbGVtZW50IGlzIGluIHRoZSBtZXNzYWdlDQoJcHJpbnQgJHNvbS0+ZmF1bHRzdHJpbmc7ICAg
ICMgcmV0dXJucyB2YWx1ZSBvZiAnZGV0YWlsJyBlbGVtZW50IGFzDQp9DQplbHNlIHtwcmludCAi
bm8gZXJyb3IuIFxuIjtwcmludCAkc29tLT5yZXN1bHQsICJcbiI7DQp9DQoNCiRyZXFfeG1sID0g
JzxPcGVuUGF0ZW50U2VydmljZXMgQUNUSU9OPSJEb2N1bWVudElucXVpcnkiPjxXT1JMRFBBVEVO
VERBVEE+PElOUVVJUlkgU0VFRD0iRVAxMDAwMDAwIiBTRUVEX0ZPUk1BVD0iRSIgU0VFRF9UWVBF
PSJQTiIvPjwvV09STERQQVRFTlREQVRBPjwvT3BlblBhdGVudFNlcnZpY2VzPic7DQokc29tID0g
JHNvYXAtPmdldFBhdGVudERhdGEoJHJlcV94bWwpOw0KcHJpbnQgJ3Jlc3VsdDogIicsICRzb20t
PnJlc3VsdCwgIlwiXG5cbiI7DQoNCiRyZXFfeG1sID0gJzxPcGVuUGF0ZW50U2VydmljZXMgQUNU
SU9OPSJEb2N1bWVudFJldHJpZXZhbCI+PFdPUkxEUEFURU5UREFUQT48RE9DVU1FTlQgSUQ9IkVQ
ICAgMTAwMDAwMFBBRlAgIiBTWVNURU09IkJOUyIgRk9STUFUPSJTSU5HTEVfUEFHRV9USUZGIiBQ
QUdFX05VTUJFUj0iMSIvPjwvV09STERQQVRFTlREQVRBPjwvT3BlblBhdGVudFNlcnZpY2VzPic7
DQoNCiMkcmVxX3htbCAgPSAnPE9wZW5QYXRlbnRTZXJ2aWNlcyBBQ1RJT049IkRvY3VtZW50UmV0
cmlldmFsIj48V09STERQQVRFTlREQVRBPjxET0NVTUVOVCBJRD0iRVAgICAxMDAwMDAwUEFGUCAi
IFNZU1RFTT0iQk5TIiBGT1JNQVQ9IlNJTkdMRV9QQUdFX1BERiIgUEFHRV9OVU1CRVI9IjEiLz48
L1dPUkxEUEFURU5UREFUQT48L09wZW5QYXRlbnRTZXJ2aWNlcz4nOw0KDQojIGNoYW5nZSB0aGUg
bmFtZXNwYWNlISAgZWxpbWluYXRlIHRoZSBlcnJvci4gDQokc29hcC0+IG5zKCd1cm46RVBPLU9w
ZW5QYXRlbnRTZXJ2aWNlcy1kb2N1bWVudERhdGEnKTsNCiRzb20gPSAkc29hcC0+Z2V0RG9jdW1l
bnREYXRhKCRyZXFfeG1sKTsNCg0KaWYgKCAkc29tLT5mYXVsdCApIHsgICAgIyB3aWxsIGJlIGRl
ZmluZWQgaWYgRmF1bHQgZWxlbWVudCBpcyBpbiB0aGUgbWVzc2FnZQ0KCXByaW50ICRzb20tPmZh
dWx0c3RyaW5nOyAgICAjIHJldHVybnMgdmFsdWUgb2YgJ2RldGFpbCcgZWxlbWVudA0KfQ0KZWxz
ZSB7DQoJbXkgJG1pbWVfZW50aXR5ID0gJHsgJHNvbS0+cGFydHMgfVswXTsNCglteSAkYm9keSAg
ICAgICAgPSAkbWltZV9lbnRpdHktPmJvZHloYW5kbGU7DQoJb3BlbiggT1VULCAnPjEudGlmJyAp
IG9yIGRpZSAid2hvb3BzICQhIjsNCg0KCSNvcGVuICggT1VUICwgJz4xLnBkZicgKSBvciBkaWUg
Indob29wcyAkISIgOw0KCWJpbm1vZGUoT1VUKTsNCglwcmludCBPVVQgJGJvZHktPmFzX3N0cmlu
ZzsNCgljbG9zZSBPVVQ7DQoJcHJpbnQgIm5vIGVycm9yIHdpdGggRG9jdW1lbnQgUmV0cmlldmFs
OyBjaGVjayBmaWxlIHN5c3RlbSBmb3Igb3V0cHV0LlxuIjsNCn0NCg==

#6013 From: "jtjustman" <jt@...>
Date: Fri Sep 14, 2007 5:09 am
Subject: Would like to hire an expert SOAP/WSDL expert for a few hours
jtjustman
Send Email Send Email
 
Hi! I've got a project going, a part of which is the development of a
WSDL-based SOAP client. I built a SOAP service from WSDL a few years
ago, but ended up doing most of the definitions by hand. I'd much
prefer to make this version as compliant as possible, and so much of
this WSDL stuff is Greek to me. I'd like someone to help me compare
the different WSDL options in CPAN and perhaps provide a little
starter code.

So if you're interested, please e-mail me off list with your rates,
and qualifications - some idea of your experience level with different
modules. I will pay via PayPal or use a mutually-agreeable escrow
service, as you see fit.

Thanks!

JT Justman

#6014 From: "guymatz" <gmatz@...>
Date: Mon Sep 17, 2007 8:39 pm
Subject: linux soap client connecting to .Net server receives "xml-escaped" output
guymatz
Send Email Send Email
 
Hello!

i'm getting xml-escaped output back from a .Net SOAP server.  It looks
like:
%lt;row>data%lt;/row>data

anyone have any idea how i can get that to look like:
<row>data</row>

without using a global search/replace?

code looks like this:

use SOAP::Lite::Simple::DotNet;
my $soap_simple = SOAP::Lite::Simple::DotNet->new({
            uri                 => $soap_uri,
            proxy               => $soap_proxy,
            xmlns               => $soap_uri,
            soapversion         => '1.1', # defaults to 1.1
            timeout             => '30', # detauls to 30 seconds
            strip_default_xmlns => 1, # defaults to 1
          }) || die "Could not create simple SOAP: $!";

$soap_simple->fetch( { 'method' => 'getData', 'xml' => '' })
                   || die $soap_simple->error();
print $xml_results = $soap_simple->results();

#6015 From: Sebastian Jaenicke <sjaenick+SOAPLITE@...>
Date: Tue Sep 18, 2007 12:00 pm
Subject: Re: linux soap client connecting to .Net server receives "xml-escaped" output
sjaenick+SOAPLITE@...
Send Email Send Email
 
On Mon, Sep 17, 2007 at 08:39:01PM -0000, guymatz wrote:
> Hello!
>
> i'm getting xml-escaped output back from a .Net SOAP server.  It looks
> like:
> %lt;row>data%lt;/row>data

HTML::Entities, decode_entities()

- Sebastian

--
Progress (n.): The process through which Usenet has evolved from
smart people in front of dumb terminals to dumb people in front
of smart terminals.
               -- obs@...

#6016 From: "Eddie" <edward.kawas@...>
Date: Tue Sep 18, 2007 8:38 pm
Subject: soaplite with mime attachments -- odd behaviour
kawas7
Send Email Send Email
 
Hi,

I am not sure if this is a soaplite problem or not, so I am looking for
some guidance.

Basically, I have the following code snippet:

#-------------------------------------
#!/usr/bin/perl
use SOAP::Lite+trace;

my $packager = SOAP::Packager::MIME->new;
$packager->initialize_parser();
$packager->parser->output_to_core(0);
$packager->parser->tmp_to_core(0);
$packager->parser->tmp_recycling(0);


my $soap = SOAP::Lite
      ->packager($packager)
      ->readable(1)
      ->uri('urn:BINDSOAP')
#    ->proxy('http://localhost:8080/services/BINDSOAP');
      ->proxy('http://soap.bind.ca/services/BINDSOAP');

#my $som = $soap->idSearchAttachment("cd00192","cdd","go","mime");
my $som = $soap->idSearchAttachment("2828026 ","gi","go","mime");

foreach my $part (@{$som->parts}) {
    print $part->stringify;
}
#--------------------------------------

When I invoke the code, I get a timeout. Some might think that the
service is down or the parameters are incorrect, but from what I can
tell, that isnt the case.

For instance, I downloaded a program called tcptrace (for windows) from
http://www.pocketsoap.com/tcptrace/. If I change the proxy() above to
use the localhost:8080 endpoint and monitor the traffic, the script runs
till completion and returns correct information.

I am using soaplite version .69. I have tried running the script on both
windows and linux. No matter how much I use soaplite, I do not
understand enough to troubleshoot this.

Anyone have any ideas?

Thanks.

Eddie

#6017 From: Bill Moseley <moseley@...>
Date: Wed Sep 19, 2007 2:18 pm
Subject: Limiting which methods can be used.
whmoseley
Send Email Send Email
 
Just starting out with SOAP::Lite, and I have a few basic questions.

I'm using SOAP::Transport::HTTP with Apache/2.2.3 mod_perl/2.0.2 and I have a
few
classes I wish to expose.

I'm using this to dispatch to my classes in my mod_perl module:

     my $server = SOAP::Transport::HTTP::Apache->dispatch_to(
         $app_dir,
         @module_list,
     );

     sub handler { $server->handler(@_) }

Now, the modules in @module_list get loaded and their methods are
exposed -- and then can be accessed by a SOAP client.

What I'm missing is how to define *which* methods should be made
available.  If the class is used outside of SOAP::Lite I'd like to make
all its methods available, but limit which methods can be called when
used by SOAP::Lite.


My other question is about Expat and mod_perl, which has been an issue
for quite a while.  I see that it's noted in the SOAP::Lite man page.
Is this still an issue with Apache2?  I'm not finding any recent
discussion of the issue.

I see some discussion of moving to libxml2 in the archives, too.
What's the status of that?




--
Bill Moseley
moseley@...

#6018 From: "leegee23" <leegee23@...>
Date: Wed Sep 19, 2007 9:35 am
Subject: Complex Data Types
leegee23
Send Email Send Email
 
After reading on this group the question "Need additional info on
setting up complex data types" by rawill4u, my answer was clear:

                 SOAP::Data->name( smiles =>
                     \SOAP::Data->value(
                         SOAP::Data->type('string')->name("string" =>
$pSmi->[$idx2] ),
                     )
                 )

Lee

Messages 5988 - 6018 of 6629   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help