PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.lang.ruby > SOAP::RPC::StandaloneServer and WSDLs
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
SOAP::RPC::StandaloneServer and WSDLs

Réponse
 
LinkBack Outils de la discussion
Vieux 12/03/2008, 14h49   #1
Robert Gray
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut SOAP::RPC::StandaloneServer and WSDLs


I have seen this posted several times on this forum without a definitive
response. I'd imagine the incantation is pretty easy, but I've been
unable to find it.

For what it's worth, this is NOT in a rails environment.

I've got the following example server code working, but I also need to
be able to generate a WSDL for this web service.

"""
require 'soap/rpc/standaloneServer'

class TestWebServices < SOAP::RPC::StandaloneServer

def initialize(* args)
super
add_method(self, 'sayhelloto', 'username')
end

def sayhelloto(username)
t = Time.now
puts("#{username} logged on #{t}")
"Hello, #{username} on #{t}."
end

end

server =
TestWebServices.new('TestWebServiceServer','urn:Te stWebServices','localhost',8005)
trap('INT') {server.shutdown}
server.start
"""

When I go to http://localhost:8005/sayhelloto/wsdl/ I get a "Method Not
Allowed" message.

Any with this would be GREATLY appreciated!

Thanks
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 12/03/2008, 17h40   #2
Raffaele Tesi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs

Robert Gray wrote:
>
> I have seen this posted several times on this forum without a definitive
> response. I'd imagine the incantation is pretty easy, but I've been
> unable to find it.
>
> For what it's worth, this is NOT in a rails environment.
>
> I've got the following example server code working, but I also need to
> be able to generate a WSDL for this web service.
>
> """
> require 'soap/rpc/standaloneServer'
>
> class TestWebServices < SOAP::RPC::StandaloneServer
>
> def initialize(* args)
> super
> add_method(self, 'sayhelloto', 'username')
> end
>
> def sayhelloto(username)
> t = Time.now
> puts("#{username} logged on #{t}")
> "Hello, #{username} on #{t}."
> end
>
> end
>
> server =
> TestWebServices.new('TestWebServiceServer','urn:Te stWebServices','localhost',8005)
> trap('INT') {server.shutdown}
> server.start
> """
>
> When I go to http://localhost:8005/sayhelloto/wsdl/ I get a "Method Not
> Allowed" message.
>
> Any with this would be GREATLY appreciated!
>
> Thanks


you get a
"
Method Not Allowed
GET request not allowed
"


library snippet (standaloneserver.rb):
"
if request.method != 'POST'
raise SAError.new("Method '#{ request.method }' not allowed.")
end
"

clear?
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 12/03/2008, 20h23   #3
Robert Gray
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs


> library snippet (standaloneserver.rb):
> "
> if request.method != 'POST'
> raise SAError.new("Method '#{ request.method }' not allowed.")
> end
> "
>
> clear?


Kind of.

My questions was... how do you get a StandaloneServer to generate a WSDL
(preferably without writing it by hand)?

Are you saying that it cannot be done with this class?
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 13/03/2008, 11h07   #4
Raffaele Tesi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs

Robert Gray wrote:
>
>> library snippet (standaloneserver.rb):
>> "
>> if request.method != 'POST'
>> raise SAError.new("Method '#{ request.method }' not allowed.")
>> end
>> "
>>
>> clear?

>
> Kind of.
>
> My questions was... how do you get a StandaloneServer to generate a WSDL
> (preferably without writing it by hand)?
>
> Are you saying that it cannot be done with this class?


take a look at action web service
http://rubyforge.org/projects/aws/

--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 13/03/2008, 11h35   #5
Raffaele Tesi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs

verrry useful post about your question (i hope)


http://groups.google.com/group/comp....ad90beb841dfe0


--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 14/03/2008, 15h38   #6
Robert Gray
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs

Raffaele Tesi wrote:
> verrry useful post about your question (i hope)
>
>
> http://groups.google.com/group/comp....ad90beb841dfe0



Thank you for taking the time to respond to this post. I really
appreciate the .

I've got to run this outside of a rails environment and I don't think
I'll be able to use action web service.

I was able to set up and test this from within that framework and the
automatic WSDL generation worked great. I'm just looking for a way to
incorporate some of that functionality into a non rails environment.

Thanks again for your thoughts,

Brad
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 19/07/2008, 07h04   #7
Vipin Vm
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: SOAP::RPC::StandaloneServer and WSDLs

Hi Guys,

> Robert Gray wrote:
> I was able to set up and test this from within that framework and the
> automatic WSDL generation worked great.


how u able to create WSDLs automatically without AWS? can u pls me
to create WSDLs like this http://localhost:8005/sayhelloto/wsdl/ ?

thanks in advance

Vipin
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 07h22.


Édité par : vBulletin® version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,12031 seconds with 15 queries