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 3366 - 3395 of 6629   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#3366 From: "korngerd" <korngerd@...>
Date: Tue Feb 17, 2004 5:24 pm
Subject: Perl Soap Server with Java Axis Client
korngerd
Send Email Send Email
 
Hi, I've been trying to get Perl Soap's server to return a map so that
I could type-cast it into a HashMap in Axis.  This is what I have:

sub test2_2 {
   return (SOAP::Data->name("VariOS_Settings" =>
     { SOAP::Data->name("DEVICE"), SOAP::Data->value("eth0"),
       "BOOTPROTO", SOAP::Data->value("static"),
       "IPADDR", SOAP::Data->value("192.168.101.130")
     } ));
}

Somehow, when I retrieve this data structure, the first element
(DEVICE) seems to become a reference to the "key Object", and I get
something weird like "SOAP::Data(HASH=blahblah)" as the key for
"eth0".  I tried this as well:

sub test2_2 {
   return (SOAP::Data->name("VariOS_Settings" =>
     { "DEVICE", SOAP::Data->value("eth0"),
       "BOOTPROTO", SOAP::Data->value("static"),
       "IPADDR", SOAP::Data->value("192.168.101.130")
     } ));
}

which returns a SoapStruct, instead of a Soap Map (which is what I
need).  Any help would be greatly appreciated!

#3367 From: "jpeyser" <jpeyser@...>
Date: Tue Feb 17, 2004 6:54 pm
Subject: Re: setitimer Problem with SOAP::Lite
jpeyser
Send Email Send Email
 
The reason might be that the daemon handle is in blocking mode. Try
setting it to non-blocking and then calling the handle routine using
a timer.

Jonathan

--- In soaplite@yahoogroups.com, Klaus Guenter <klaus.guenter@p...>
wrote:
> Hi, List!
>
> I have written a little SOAP Server using SOAP::Transport::HTTP
> It forks off in to background and works smoothly so far.
>
> As a watchdog functionality, the server touches a certain file
every 60 secs.
> Another process keeps monitoring the mtime of these files and
kills/restarts
> processes that didn't touch their file for > 121 secs.
>
> <CODE>
> $SIG{ALRM} = sub {
>   &SaveIntoFile("$watch_prefix.$my_port", 1);
> };
>
> #This is called after fork to set the timer on a per process basis
> setitimer(ITIMER_REAL, 10, 60);
> </CODE>
>
> Other server processes (not using SOAP::*) have no problems with
this
> approach, while the signal handler in the server using SOAP::* is
called only
> once after $daemon->handle . What did I miss? Is SOAP::* using
itimer itself?
>
> Any hint is appreciated,
> TIA
>
> Klaus
> --
> People often find it easier to be a result of the past than a cause
of
> the future.
> -

#3368 From: Tomas (NW7US) <nw7us@...>
Date: Tue Feb 17, 2004 10:03 pm
Subject: MS MapPoint / .Net (Newbie question)
nw7us
Send Email Send Email
 
Howdy,

I am very new to .Net and to SOAP::Lite.  I am, however, well-versed in Perl.

I am in need to create a client on the Un*x side, using Perl and SOAP::Lite, to
talk with the MapPoint .NET service to obtain custom maps.  I've been searching
the 'net and reading "Programming Web Services with Perl" to try and wrap my
mind around how to accomplish this.

I am wondering if any of you have already done something like this, and might
have some simple example pseudo code, or even code snippets that I might be able
to study.  And/or, know of some project code or article out on the 'net that
might cover this specific SOAP application.

Any help is appreciated.  Thank you, in advance.

73 de Tomas, NW7US
  Echolink # 152783
--
: Propagation Editor for CQ, CQ VHF, and Popular Communications :
: Quarterly Propagation Columnist for Monitoring Times Magazine :
: Creator of live propagation center - http://prop.hfradio.org/ :
: Member, US Army Miltary Affiliate Radio Service (MARS) AAR0JA :
: 122.93W 47.67N / Brinnon, Washington USA - CN87 - CW/SSB/DIGI :
: Washington State MARS Emergency Operations Officer -- AAM0EWA :
: 10x56526, FISTS 7055, FISTS NW 57,  AR Lighthouse Society 144 :

#3369 From: Jenni Bennett <jenni@...>
Date: Wed Feb 18, 2004 12:33 am
Subject: Decoding arrays of structures containing arrays
ldapgirl42
Send Email Send Email
 
I have written a SOAP::Lite Client to query a SOAP server using complex
data types. I am having problems decoding the response. The response
that is returned is similar to the following:

<?xml version="1.0" encoding="utf-8"?>
<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>
         <fooResponse xmlns="http://foo.bar/foible/">
             <fooResult>
                 <fooOut>
                     <RecordId>27745</RecordId>
                     <TransactionStatus>
                         <StatusCode>Failure</StatusCode>
                         <Messages>
                             <Message>
                                 <Description>BirthDate can not be in the
future</Description>
                                 <Severity>Error</Severity>
                             </Message>
                         </Messages>
                     </TransactionStatus>
                 </fooOut>
                 <fooOut>
                     <RecordId>31572</RecordId>
                     <TransactionStatus>
                         <StatusCode>Success</StatusCode>
                         <Messages />
                     </TransactionStatus>
                 </fooOut>
                 <ResponseControlTable>
                     <RequestId>1</RequestId>
                     <RequestStatus>
                         <StatusCode>Success</StatusCode>
                         <Messages>
                            <Message>
                                <Description>2 total transactions in
request</Description>
                                <Severity>Information</Severity>
                            </Message>
                            <Message>
                                <Description>1 transactions completed
successfully</Description>
                                <Severity>Information</Severity>
                            </Message>
                            <Message>
                                <Description>0 transactions completed with
warnings</Description>
                                <Severity>Information</Severity>
                            </Message>
                            <Message>
                                <Description>1 transactions completed in
error</Description>
                                <Severity>Information</Severity>
                            </Message>
                         </Messages>
                     </RequestStatus>
                 </ResponseControlTable>
             </fooResult>
         </fooResponse>
     </soap:Body>
</soap:Envelope>

I am decoding with the following:

my $i = 0;
foreach my $elem ( $som->dataof('//fooResponse/fooResult/*') )
{
	 $i++;
	 my $value = $elem->value();
	 if ( $elem->name() eq "fooOut" )
	 {
		 print "RecordId: " . $value->{'RecordId'} . "\n";
		 my $transStatus = $value->{'TransactionStatus'};
		 print "StatusCode: " . $transStatus->{'StatusCode'} . "\n";

		 foreach my $m (
$som->dataof('//fooResponse/fooResult/[$i]/TransactionStatus/Messages/*'))
		 {
			 print "Code: " . $m->{'Code'} . "\n";
		 }
	 }
	 elsif ( $elem->name() eq "ResponseControlTable" )
	 {
		 print "RequestId: " . $value->{'RequestId'} . "\n";
		 my $reqStatus = $value->{'RequestStatus'};
		 print "        StatusCode: " . $reqStatus->{'StatusCode'} . "\n";

		 foreach my $m (
$som->valueof('//fooResponse/fooResult/[$i]/RequestStatus/Messages/Message') )
		 {
			 print "Code: " . $m->{'Code'} . "\n";
		 }
	 }
}

I am having problems accessing the "Message" elements returned in both the
"fooOut" and "ResponseControlTable" elements. The two attempts
above do not return any results. I have seen examples of accessing
arrays of arrays but not arrays of structures containing arrays.

Can someone suggest how I might be able to access this data?

Jenni.
--
Jenni Bennett (jenni@...)                          /\
IT Strategies and Developments (Emerging Technologies)      _/./
The University of Melbourne                              ,-'    `-:..-'/
                                                         : o )      _  (
+61-3-8344-7497                                         "`-....,--; `-.\
                                                             `'

#3370 From: "Joseph Norris" <sirronj@...>
Date: Wed Feb 18, 2004 4:52 pm
Subject: Newbie with build of first soap server - HELP!
sirronj777
Send Email Send Email
 
Group,

I am really enjoying working with SOAP::Lite - but I have run into a
problem
when building my own Server. I have been successful in building
clients for
a variety of soap servers but now I wish to do my own.

I keep getting Denied Access to method error and I am not sure just
how to
begin troubleshooting this problem. It appears that my little server
finds
the subs in my PM that I am using but then I get this error. This
happens
when I have a package of routines in the Soap server script in accord
with
the example scripts. I have the following:

use SOAP::Transport::HTTP;
use lib "/usr/local/cs/lib";
use CSSOAP;

SOAP::Transport::HTTP::CGI
     -> dispatch_to('/usr/local/cs/lib/CSSOAP')
     -> handle;


The rountines in CSSOAP.pm are not being found. I get the following:

Denied access to method (cslogin) in class (CSSOAP) at
/usr/lib/perl5/site_perl/5.6.1/SOAP/Lite.pm line 2267.

my client:


use SOAP::Lite
     on_fault => sub { my($soap_response, $res) = @_;
       die ref $res ? $res->faultstring : $soap_response->transport-
>status,
"\n"; };

my $soap_response = SOAP::Lite
   -> readable(1)
   -> uri('http://spare.test.com/CSSOAP')
   -> proxy('http://spare.test.com/cs/admin/soap');

my $cs_handle = $soap_response->cslogin
('esb.test.com', 'joseph','12345cs');
if (!$cs_handle){
     print "error in login\n";
     exit();
}

Thanks.

#3371 From: Joseph Norris <sirronj@...>
Date: Wed Feb 18, 2004 8:59 pm
Subject: First server newbie question - Please Help
sirronj777
Send Email Send Email
 
Group,

I am really enjoying working with SOAP::Lite - but I have run into a
problem
when building my own Server. I have been successful in building
clients for
a variety of soap servers but now I wish to do my own.

I keep getting Denied Access to method error and I am not sure just
how to
begin troubleshooting this problem. It appears that my little server
finds
the subs in my PM that I am using but then I get this error. This
happens
when I have a package of routines in the Soap server script in accord
with
the example scripts. I have the following:

use SOAP::Transport::HTTP;
use lib "/usr/local/cs/lib";
use CSSOAP;

SOAP::Transport::HTTP::CGI
-> dispatch_to('/usr/local/cs/lib/CSSOAP')
-> handle;


The rountines in CSSOAP.pm are not being found. I get the following:

Denied access to method (cslogin) in class (CSSOAP) at
/usr/lib/perl5/site_perl/5.6.1/SOAP/Lite.pm line 2267.

my client:


use SOAP::Lite
on_fault => sub { my($soap_response, $res) = @_;
die ref $res ? $res->faultstring : $soap_response->transport-
>status,
"\n"; };

my $soap_response = SOAP::Lite
-> readable(1)
-> uri('
http://spare.test.com/CSSOAP')
-> proxy('
http://spare.test.com/cs/admin/soap');

my $cs_handle = $soap_response->cslogin
('esb.test.com', 'joseph','12345cs');
if (!$cs_handle){
print "error in login\n";
exit();
}

Thanks.



#3372 From: "ask4uk" <jon@...>
Date: Thu Feb 19, 2004 12:15 am
Subject: nexted XML output under single node from while loop
ask4uk
Send Email Send Email
 
Hello,

I am trying to produce XML output of the form:

<attributes>
           <RadiusAttribute>
             <type>string</type>
             <value>string</value>
           </RadiusAttribute>
           <RadiusAttribute>
             <type>string</type>
             <value>string</value>
           </RadiusAttribute>
</attributes>

I am using the code snippet below, based on the various samples in
this list:

while (($name, $value) = $p->get_attr_val_n($i++))
     {
	 #push(@args, SOAP::Data->name('attribute' => [$name,
$value]));


	 push(@args,( SOAP::Data->name("attributes"=>
	 \SOAP::Data->name
	 ("RadiusAtrtibute"=>
	 \SOAP::Data->value(SOAP::Data->name
	 ("type"=>$name)),
	 \SOAP::Data->value(SOAP::Data->name
	 ("value"=>$value))
	 )
	 )));
}

However, this creates a separate "attributes" node for each iteration
of the loop (fairly obviously, when you think about it...) and I only
want one attributes node with multiple children. I have scoured the
net without much luck on this one and am now banging my head on the
desk. Any thoughts gratefully received!

Regards

Jonathan

#3373 From: "jpeyser" <jpeyser@...>
Date: Thu Feb 19, 2004 3:05 pm
Subject: Re: nexted XML output under single node from while loop
jpeyser
Send Email Send Email
 
Try

for (1..2) {
   push(@args,(
     SOAP::Data->name("RadiusAttribute"=> \SOAP::Data->value(
       SOAP::Data->name("type"=>$name),
       SOAP::Data->name("value"=>$value)
   ))));
}

$args = SOAP::Data->name("attributes"=> \SOAP::Data->value(@args));

Jonathan

--- In soaplite@yahoogroups.com, "ask4uk" <jon@a...> wrote:
> Hello,
>
> I am trying to produce XML output of the form:
>
> <attributes>
>           <RadiusAttribute>
>             <type>string</type>
>             <value>string</value>
>           </RadiusAttribute>
>           <RadiusAttribute>
>             <type>string</type>
>             <value>string</value>
>           </RadiusAttribute>
> </attributes>
>
> I am using the code snippet below, based on the various samples in
> this list:
>
> while (($name, $value) = $p->get_attr_val_n($i++))
>     {
>  #push(@args, SOAP::Data->name('attribute' => [$name,
> $value]));
>
>
>  push(@args,( SOAP::Data->name("attributes"=>
>  \SOAP::Data->name
>  ("RadiusAtrtibute"=>
>  \SOAP::Data->value(SOAP::Data->name
>  ("type"=>$name)),
>  \SOAP::Data->value(SOAP::Data->name
>  ("value"=>$value))
>  )
>  )));
> }
>
> However, this creates a separate "attributes" node for each
iteration
> of the loop (fairly obviously, when you think about it...) and I
only
> want one attributes node with multiple children. I have scoured the
> net without much luck on this one and am now banging my head on the
> desk. Any thoughts gratefully received!
>
> Regards
>
> Jonathan

#3374 From: "kvclarkusa" <kvclarkusa@...>
Date: Thu Feb 19, 2004 3:28 pm
Subject: (No subject)
kvclarkusa
Send Email Send Email
 
Hello,

I am connecting a Perl client to a .NET web service.  I have
succesfully
tested calling methods and passing simple parameters such as
strings, integers, etc to the server.

However, one method in the .NET web service declares an input
parameter as an object of a
complex data type.  I am having problems passing this data type from
my
perl client.  I believe what I want to do is referenced in section 3
of this article
(http://www.perl.com/pub/a/2003/03/26/perlanddotnet.html), but it is
not working.  If anyone has any experience, I would appreciate some
help.

Here is the example of the code from the .NET web service:

		 public class Car
		 {
			 public string color;
			 public string size;
		 }


		 [WebMethod]
		 public string GetCar(Car NewCar)
		 {
			 return "Your car will be colored " +
NewCar.color + " and have a size of " + NewCar.size;
		 }

Here is the perl client:

my $uri = "...";
my $proxy = "...";

my $soap = SOAP::Lite
	 ->uri($uri)
	 ->on_action( sub { join '/', $uri, $_[1]} )
	 ->proxy($proxy)
	 ->ClientLogin2(SOAP::Data->name('NewCar')
				  ->uri($uri)
				  ->value(bless { color => 'red',
		      				  size => 'large'},
		      				    'Car')
	 );

Thanks in advance.  Here's what I get in response when I turn on
debugging:

POST http://.../test_3.asmx
Accept: text/xml
Accept: multipart/*
Content-Length: 757
Content-Type: text/xml; charset=utf-8
SOAPAction: http://.../GetCar

<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:SOAP-
ENC="http://
schemas.xmlsoap.org/soap/encoding/"
xmlns:namesp3="http://namespaces.soaplite.co
m/perl" SOAP-
ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns
:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.o
rg/1999/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"><SOAP-E
NV:Body><namesp1:GetCar
xmlns:namesp1="http://onwardhealthcare.com"><names
p2:NewCar xmlns:namesp2="http://onwardhealthcare.com"
xsi:type="namesp3:Car"><color xsi:type="xsd:string">red</color><size
xsi
:type="xsd:string">large</size></namesp2:NewCar></namesp1:GetCar
></SOAP-ENV:Body></SOAP-ENV:Envelope>
HTTP/1.1 500 (Internal Server Error) Internal Server Error.
Cache-Control: private
Connection: close
Date: Thu, 19 Feb 2004 14:57:27 GMT
Server: Microsoft-IIS/5.0
Content-Length: 771
Content-Type: text/xml; charset=utf-8
Client-Date: Thu, 19 Feb 2004 14:57:26 GMT
Client-Peer: xx.xx.xx.xx:80
Client-Response-Num: 1
X-AspNet-Version: 1.1.4322
X-Powered-By: ASP.NET

<?xml version="1.0" encoding="utf-8"?>
<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/XM
LSchema">
   <soap:Body>
     <soap:Fault>
       <faultcode>soap:Server</faultcode>
       <faultstring>System.Web.Services.Protocols.SoapException:
Server was unabl
e to process request. ---> System.NullReferenceException: Object
reference no
t set to an instance of an object.
    at OH_User_Interface.web_service.test_3.GetCar(ClientLoginInfo
ClientIn
fo) in \\...\test_3.asmx.cs:line 37
    --- End of inner exception stack trace ---</faultstring>
       <detail />
     </soap:Fault>
   </soap:Body>
</soap:Envelope>

#3375 From: "Joseph Norris" <sirronj@...>
Date: Thu Feb 19, 2004 3:32 pm
Subject: Attempting to understand ->proxy
sirronj777
Send Email Send Email
 
Group,

I am a little confused about the proxy side of SOAP::Lite. What is
its purpose and how do I determine on a system where soap is running
if proxy for soap is set up as it should be. I have attempted to
bypass this but I get the following errror:

Transport is not specified (using proxy() method or service
description)

The documentation leads me to believe that I do not have to use proxy
but maybe I am reading it wrong - or I am just confused.

Thanks.

#3376 From: "Duncan Cameron" <duncan_cameron2002@...>
Date: Thu Feb 19, 2004 7:35 pm
Subject: Re: Attempting to understand ->proxy
duncan_camer...
Send Email Send Email
 
At 15:32:24 on 2004-02-19 Joseph Norris <sirronj@...> wrote:

>Group,
>
>I am a little confused about the proxy side of SOAP::Lite. What is
>its purpose and how do I determine on a system where soap is running
>if proxy for soap is set up as it should be. I have attempted to
>bypass this but I get the following errror:
>
>Transport is not specified (using proxy() method or service
>description)
>
>The documentation leads me to believe that I do not have to use proxy
>but maybe I am reading it wrong - or I am just confused.
>

In SOAP::Lite the term proxy is used simply for the server to which you
want to connect. It is not a 'http proxy' as you would understand that.

Regards
Duncan

#3377 From: "Byrne Reese" <byrne@...>
Date: Tue Feb 24, 2004 3:51 pm
Subject: Re: Decoding arrays of structures containing arrays
byrnereese
Send Email Send Email
 
Could it be as simple as:

-- CUT HERE --
foreach my $m ( $som->dataof('//Messages')) {
   print $m->{description};
}
-- CUT HERE --

It is a valid XPath statement afterall... but you may want to access each
segment of message elements independently from one another...

>
>
>
>
> I have written a SOAP::Lite Client to query a SOAP server using complex
> data types. I am having problems decoding the response. The response
> that is returned is similar to the following:
>
>>?xml version="1.0" encoding="utf-8"?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:BodyfooResponse
>>
xmlns="http://foo.bar/foible/"fooResultfooOutRecordId/RecordIdTransactionStatusS\
tatusCode/StatusCodeMessagesMessageDescription/DescriptionSeverity/Severity/Mess\
age/Messages/TransactionStatus/fooOutfooOutRecordId/RecordIdTransactionStatusSta\
tusCode/StatusCodeMessages
>>
//TransactionStatus/fooOutResponseControlTableRequestId/RequestIdRequestStatusSt\
atusCode/StatusCodeMessagesMessageDescription/DescriptionSeverity/Severity/Messa\
geMessageDescription/DescriptionSeverity/Severity/MessageMessageDescription/Desc\
riptionSeverity/Severity/MessageMessageDescription/DescriptionSeverity/Severity/\
Message/Messages/RequestStatus/ResponseControlTable/fooResult/fooResponse/soap:B\
ody/soap:Envelope
>
>
>
>
>
>
>
> Yahoo! Groups Links
>
> To visit your group on the web, go
> to:http://groups.yahoo.com/group/soaplite/
> To unsubscribe from this group, send an email
> to:soaplite-unsubscribe@yahoogroups.com
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
>
>
>
>
>
>
>
>
>
>


^byrne :/

#3378 From: NOVAK Judit <judit@...>
Date: Tue Feb 24, 2004 4:36 pm
Subject: Digest authentication
njudy79
Send Email Send Email
 
Dear all,


I want to use Digest authentication method accessing the server
class. The solutions I found mentioned together with Basic
authentication (overriding
SOAP::Transport::HTTP::Client::get_basic_credentials to return
'username' => 'password' or using
$soapobj->transport->credentials('port', 'realm', 'user' => 'password')), did
not work for me. I still get the error message:

client used wrong authentication scheme: Basic for <myscriptlocation>

Though searching the web quite some time now, I couldn't find anything, that
could help me :(

Does anyone have some suggestion/experiance?
I'm not so expert in SOAP and web authentication...


Thanks a lot!
Judit

#3379 From: Jenni Bennett <jenni@...>
Date: Wed Feb 25, 2004 1:38 am
Subject: Re: Decoding arrays of structures containing arrays
ldapgirl42
Send Email Send Email
 
Byrne,

On Tue, 24 Feb 2004, Byrne Reese wrote:

> Could it be as simple as:
>
> -- CUT HERE --
> foreach my $m ( $som->dataof('//Messages')) {
>   print $m->{description};
> }
> -- CUT HERE --
>
> It is a valid XPath statement afterall... but you may want to access each
> segment of message elements independently from one another...

It was as simple as substituting double quotes for single...

i.e.
foreach my $m (
$som->dataof("//fooResponse/fooResult/[$i]/TransactionStatus/Messages/*"))
{
   print "Code: " . $m->{'Code'} . "\n";
}

instead of:

foreach my $m (
$som->dataof('//fooResponse/fooResult/[$i]/TransactionStatus/Messages/*'))
{
   print "Code: " . $m->{'Code'} . "\n";
}

Oops. :-/

Thanks for the response.

Jenni.

#3380 From: "drfousth" <yahoo@...>
Date: Wed Feb 25, 2004 3:18 pm
Subject: SOAP::Lite vanished from CPAN ?
drfousth
Send Email Send Email
 
Hello,

I can't find SOAP::Lite with the CPAN shell anymore since a few days.
What happened?

Sven

#3381 From: Byrne Reese <byrne@...>
Date: Wed Feb 25, 2004 6:31 pm
Subject: Re: SOAP::Lite vanished from CPAN ?
byrnereese
Send Email Send Email
 
I am actively working to resolve this with CPAN. Since Paul transitioned
ownership/management of SOAP::Lite to me (Paul is still involved of
course) there has been issues on the CPAN network... they won't let me
post updates, and they are far too busy to respond to my support requests.

Please be patient - this will get resolved.

drfousth wrote:

> Hello,
>
> I can't find SOAP::Lite with the CPAN shell anymore since a few days.
> What happened?
>
> Sven
>
>
> *Yahoo! Groups Sponsor*
> ADVERTISEMENT
>
>
> ------------------------------------------------------------------------
> *Yahoo! Groups Links*
>
>     * To visit your group on the web, go to:
>       http://groups.yahoo.com/group/soaplite/
>
>     * To unsubscribe from this group, send an email to:
>       soaplite-unsubscribe@yahoogroups.com
>       <mailto:soaplite-unsubscribe@yahoogroups.com?subject=Unsubscribe>
>
>     * Your use of Yahoo! Groups is subject to the Yahoo! Terms of
>       Service <http://docs.yahoo.com/info/terms/>.
>
>

#3382 From: "epfreed1" <efreed@...>
Date: Wed Feb 25, 2004 7:37 pm
Subject: cookie problems
epfreed1
Send Email Send Email
 
I am having problems either sending or receiving cookies with
SOAP::Lite, but I don't know where the problem is.

I can create cookies (I checked by saving them to a file), and I try
to send like this:

    $soap = SOAP::Lite
         ->readable(1)
         -> uri('http://localhost/test/SOAP') #
         -> proxy($endpoint, cookie_jar => $cookie_jar );

     $result = $soap->$method;

and I try to recieve like this (mod_perl server):

sub handler  {
     my ($request) = @_;
     my $cookies = $request->header_in('cookie');
...

but I have nothing in $cookies. When I look at the packets using
Ethereal, I don't see anything that looks like a cookie on the wire,
and when I look at the (rather nice) java tcpmon tool, I also see no
sign of the cookies. How can I tell if I am *really* sending the
cookie? And if I am not, what can the problem be?

thanks

#3383 From: Alasdair Allan <aa@...>
Date: Wed Feb 25, 2004 7:49 pm
Subject: Re: cookie problems
dr_aallan
Send Email Send Email
 
> I am having problems either sending or receiving cookies with
> SOAP::Lite, but I don't know where the problem is.

Have a look at my example cookie code here

   http://www.astro.ex.ac.uk/people/aa/software/cookie_daemon.tar.gz

Cheers,
Al.
--
Dr. A. Allan, School of Physics, University of Exeter

#3384 From: Eric Freed <efreed@...>
Date: Wed Feb 25, 2004 8:24 pm
Subject: Re: cookie problems
epfreed1
Send Email Send Email
 
I take it back. Having your working code helped me to see what was not
happening, and where it wasn't.

I was right, my client was not sending cookies, and it turned out to be
that my $endpoint has to be a fully qualified name:

for example:
     my $endpoint = 'http://machinename/test';
     my $uri = URI->new($endpoint);
     my $cookie = make_cookie( "user", "password" );

     my $cookie_jar = HTTP::Cookies->new();
     $cookie_jar->set_cookie(0, user => $cookie, '/', $uri->host(),
         $uri->port());

     my $soap = SOAP::Lite
         -> readable(1)
         -> uri('http://machinename/test/SOAP') # .pm location
         -> proxy($endpoint, cookie_jar => $cookie_jar );

     $result = $soap->$method;

will not attach a cookie, but :

     my $endpoint = 'http://machinename.domain.com/test';

will.

I don't know why that is, and I suspect it is a HTTP::Cookies thing and
not SOAP::Lite, but thanks

-Eric

On Wed, 2004-02-25 at 14:59, Eric Freed wrote:
> Thanks,
>
> I actually already found your examples (via Google), but they have not
> helped me (or they have not helped me with *this* problem, they were
> helpful otherwise).
>
> Eric

On Wed, 2004-02-25 at 14:49, Alasdair Allan wrote:
> > I am having problems either sending or receiving cookies with
> > SOAP::Lite, but I don't know where the problem is.
>
> Have a look at my example cookie code here
>
>   http://www.astro.ex.ac.uk/people/aa/software/cookie_daemon.tar.gz
>
> Cheers,
> Al.
--
Eric Freed <efreed@...>

#3385 From: Alasdair Allan <aa@...>
Date: Wed Feb 25, 2004 8:28 pm
Subject: Re: cookie problems
dr_aallan
Send Email Send Email
 
> I was right, my client was not sending cookies, and it turned out to be
> that my $endpoint has to be a fully qualified name:
>
>     my $endpoint = 'http://machinename/test';
>
> will not attach a cookie, but :
>
>     my $endpoint = 'http://machinename.domain.com/test';
>
> will. I don't know why that is, and I suspect it is a HTTP::Cookies
> thing and not SOAP::Lite, but thanks

Yes, I've come across this problem as well. I did spend some time trying
to figure out why this was the case but I eventually gave it up as a bad
job. I should probably add that into the cookie_dameon documentation...

Al.

#3386 From: Byrne Reese <byrne@...>
Date: Wed Feb 25, 2004 9:21 pm
Subject: Re: cookie problems
byrnereese
Send Email Send Email
 
This has for so many people been a point of confusion about cookies... and not just for SOAP::Lite, but for web developers in general.

According to Netscape's Cookie specification (http://wp.netscape.com/newsref/std/cookie_spec.html), the domain a cookie is appied to MUST have at least two decimals within it.

Excerpt:
domain=DOMAIN_NAME

Only hosts within the specified domain can set a cookie for a domain and domains must have at least two (2) or three (3) periods in them to prevent domains of the form: ".com", ".edu", and "va.us". Any domain that fails within one of the seven special top level domains listed below only require two periods. Any other domain requires at least three. The seven special top level domains are: "COM", "EDU", "NET", "ORG", "GOV", "MIL", and "INT".

Therefore most HTTP clients will often not set a cookie for an application deployed to "http://localhost/" for example... So if  you are doing test development, it is always advised that you create some virtualhosts like "http://test.localhost/"

Anyway - that is why some cookies work and others don't.

Eric Freed wrote:
for example:
    my $endpoint = 'http://machinename/test';

will not attach a cookie, but :

    my $endpoint = 'http://machinename.domain.com/test';

will.

I don't know why that is, and I suspect it is a HTTP::Cookies thing and
not SOAP::Lite, but thanks

-Eric

On Wed, 2004-02-25 at 14:59, Eric Freed wrote:
> Thanks,
>
> I actually already found your examples (via Google), but they have not
> helped me (or they have not helped me with *this* problem, they were
> helpful otherwise).
>
> Eric

On Wed, 2004-02-25 at 14:49, Alasdair Allan wrote:
> > I am having problems either sending or receiving cookies with
> > SOAP::Lite, but I don't know where the problem is.
>
> Have a look at my example cookie code here
>
>   http://www.astro.ex.ac.uk/people/aa/software/cookie_daemon.tar.gz
>
> Cheers,
> Al.
--
Eric Freed <efreed@...>


#3387 From: "c002928" <scoldan@...>
Date: Thu Feb 26, 2004 4:39 am
Subject: accept-encoding gzip
c002928
Send Email Send Email
 
The web service I am using requires messages to have an http header
that looks like this:

Accept-Encoding: gzip, deflate
  or like this:
Accept-Encoding: gzip

I added the following line to my client code

-> proxy($endpoint, options => {compress_threshold => 10});

I hoped this would add the http header but it only looks like this:

Accept-Encoding: deflate

  so the request fails

Is there a way to do this with SOAP::Lite without resorting to
rolling your own POST message by adding headers and soap line by
line?

#3388 From: "Duncan Cameron" <duncan_cameron2002@...>
Date: Thu Feb 26, 2004 1:34 pm
Subject: Re: accept-encoding gzip
duncan_camer...
Send Email Send Email
 
----- Original Message -----
From: "c002928" <scoldan@...>
To: <soaplite@yahoogroups.com>
Sent: Thursday, February 26, 2004 4:39 AM
Subject: [soaplite] accept-encoding gzip


> The web service I am using requires messages to have an http header
> that looks like this:
>
> Accept-Encoding: gzip, deflate
>  or like this:
> Accept-Encoding: gzip
>
> I added the following line to my client code
>
> -> proxy($endpoint, options => {compress_threshold => 10});
>
> I hoped this would add the http header but it only looks like this:
>
> Accept-Encoding: deflate
>
>  so the request fails
>
> Is there a way to do this with SOAP::Lite without resorting to
> rolling your own POST message by adding headers and soap line by
> line?
>
From what I can see the only reason why the header would not be
"Accept-Encoding: gzip" is if you do not have Compress::Zlib installed.
The content of your message will then be gzipped if the length is
greater than the threshold.
  Try stepping through SOAP/Transport/HTTP.pm from the start of the
send_receive() routine to see where the problem is.
If that doesn't clear it up then post a copy of your client code.

Regards

Duncan Cameron

#3389 From: Zazie Queneau <zazie_6969@...>
Date: Fri Feb 27, 2004 5:45 pm
Subject: Problem with stubmaker.pl
zazie_6969
Send Email Send Email
 
Hi

I'm just curious, but while generating
Perl code from a WSDL file, I had the following
problem: the SOAP call from the generated class
looks like:

    <namesp1:authoriseApplicationEvent ...
       <event xsi:type="tns:Event">

but to work properly with the server, the WSDL
comes from, it has to be:

    <namesp1:authoriseApplicationEvent ...
       <event xsi:type="namesp1:Event">
                        ^^^^^^^ -> only difference

Is that a bug in the stubmaker.pl script or
is the SOAP server more Catholic than the Pope?

The mentioned WSDL can be reached under
http://www.tmref-de.t-motion.co.uk/service/soap/1.0/

Best regards

     Thomas Nitsche






Mit schönen Grüßen von Yahoo! Mail - http://mail.yahoo.de

#3390 From: "Raj***" <click35mm@...>
Date: Fri Feb 27, 2004 11:15 pm
Subject: found this email site
click35mm
Send Email Send Email
 
sacmail.com

#3391 From: "Maurice McCabe" <mmccabe@...>
Date: Sat Feb 28, 2004 12:55 am
Subject: Returning a .NET DataSet to a .NET Client
orb_soft
Send Email Send Email
 
Has anyone tried to return a .NET Dataset to a .NET client from a
SOAPLite server?

I want to be able to pass a list of queries from a .NET client and
receive a DataSet of tables for each query which I want to display as a
DataGrid on a web page.

For example, I want the code to look something like the following:

Dim mySOAPLiteServer as SOAPLiteServer = New SOAPLiteServer()
Dim myQueries as New HashTable()
myQueries("Authors") = "select * from Authors"
myQueries("Publishers") = "select * from Publishers"
Dim myDataSet as Dataset = mySOAPLiteServer.GetDataSet(myQueries)
myWebPageAuthorsDataGrid.DataSource =
myDataSet.Tables("Authors").DefaultView
myWebPageAuthorsDataGrid.DataBind()

Any ideas/suggestions?

Maurice

#3392 From: "jakeryder3344" <jakeryder3344@...>
Date: Sun Feb 29, 2004 6:25 am
Subject: C# client throws XML exception, perl client works (SOAP::Lite perl CGI server)
jakeryder3344
Send Email Send Email
 
I'm integrating a C# client with a perl cgi soap
server. Using perl as the client, I am able to access
the web service via WSDL with no problem. Using, C#,
however, I get this message:

"System.Xml.XmlException: The data at the root level
is invalid. Line 1, position 1."

I'm not sure if this is a problem with my WSDL file or
not (http://www.simplepics.com/soap/SimplePics.wsdl)

-------------------------
The response that I get from my perl client to this
web service (using +trace) is:
-------------------------
<?xml version="1.0"
encoding="UTF-8"?><SOAP-ENV:Envelope
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"><SOAP-
ENV:Body><namesp1:verifyUserResponse
xmlns:namesp1="http://www.simplepics.com/SimplePics"><s-gensym3
xsi:type="xsd:int">1</s-gensym3></namesp1:verifyUserResponse></SOAP-
ENV:Body></SOAP-ENV:Envelope>

-------------------------
perl client code is:
-------------------------
#!perl -w
use SOAP::Lite +trace;
print SOAP::Lite
   -> uri('http://www.simplepics.com/SimplePics')
   ->
proxy('http://www.simplepics.com/cgi-bin/soap.cgi')
   -> verifyUser('a','b')
   -> result;

-------------------------
CGI server code is:
-------------------------
#!/usr/bin/perl -w

print "content-type: text/xml\n\n";
use SOAP::Transport::HTTP;


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

package SimplePics;

sub verifyUser(){

         my ($username, $password) = @_;

         if($username && $password){
                return (1);
         }else{
                return (0);
         }

}



Any help would be appriciated.

#3393 From: "techrg99" <bhess@...>
Date: Sun Feb 29, 2004 3:46 pm
Subject: non-blocking calls...
techrg99
Send Email Send Email
 
Using SOAP::Lite from a Perl/Tk client calling a mod_soap/Apache
server as a middle tier to access a database - the client "locks" when
the call is made.  I was told in another list this was because that
libwww/LWP blocks - I did not think this was the case.  Does
SOAP::Lite block when using HTTP?  Anyone else seen this or have a
workaround?  Thanks...

#3394 From: "Marcus" <teasysmail@...>
Date: Sun Feb 29, 2004 5:40 pm
Subject: Access to Header on server before dispatching request
teasysmail
Send Email Send Email
 
Hi all,

I'm looking for a way to access the header information on server side
before actualy executing the request.

My header includes session information that I want to validate before
continuing with the request.

I have something like...

$soap->request( HTTP::Request ref );

... validate session from Header ...

$soap->handle();

return $soap->response();

To be more precise I would like to read from the header before
executing the request and I need to "enhance" the header after the
called method returned before returning the result document. The
basic idea is to include server side session authentification that is
transparent to the module called.

Thanks for any idea/help!

BR
Marcus

#3395 From: "Maurice McCabe" <mmccabe@...>
Date: Wed Mar 3, 2004 5:22 am
Subject: RE: Returning a .NET DataSet to a .NET Client
orb_soft
Send Email Send Email
 
I got this working. I created a module I am calling DataSet.pm which
makes this possible. DataSet.pm contains the template for constucting
the XML for a .NET DataSet. It constructs the XML from hashes passed in
as parameters. These hashes were returned from the requested DBI
queries. SOAPLite returns it as a SOAP message. A .NET client displays
each DataSet table in a web page as a DataGrid (for example, using VB
code similar to below).

Anyone interested in this module (and the related WSDL file)?

Maurice


-----Original Message-----
From: Maurice McCabe [mailto:mmccabe@...]
Sent: Friday, February 27, 2004 4:56 PM
To: soaplite@yahoogroups.com
Subject: [soaplite] Returning a .NET DataSet to a .NET Client


Has anyone tried to return a .NET Dataset to a .NET client from a
SOAPLite server?

I want to be able to pass a list of queries from a .NET client and
receive a DataSet of tables for each query which I want to display as a
DataGrid on a web page.

For example, I want the code to look something like the following:

Dim mySOAPLiteServer as SOAPLiteServer = New SOAPLiteServer()
Dim myQueries as New HashTable()
myQueries("Authors") = "select * from Authors"
myQueries("Publishers") = "select * from Publishers"
Dim myDataSet as Dataset = mySOAPLiteServer.GetDataSet(myQueries)
myWebPageAuthorsDataGrid.DataSource =
myDataSet.Tables("Authors").DefaultView
myWebPageAuthorsDataGrid.DataBind()

Any ideas/suggestions?

Maurice




Yahoo! Groups Links

Messages 3366 - 3395 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