Displaying 20 results from an estimated 2000 matches similar to: "ActionWebService API ignoring multiple return values?"
2006 Mar 28
11
ActionWebService date casting error
I have defined a web service to return information from a database as follows.
class BackendApi < ActionWebService::API::Base
api_method :find_all_vobs,
:returns => [[:int]]
api_method :find_vob_by_id,
:expects => [:int],
:returns => [Vob]
class BackendController < ApplicationController
wsdl_service_name ''Backend''
2006 Jan 07
1
AWS, SOAP, and Exceptions
Can someone shed some light on how to convert an Exception to a
SOAPFault on Rails 1.0/AWS 1.0? I''ve been digging through the source
code and see that in soap_protocol.rb there is a method called
encode_response() that seems to perform the translation of an Exception
to a SOAPFault. However, if I use the following code block within my Web
Service controller:
def
2006 Jun 07
0
Logger in ActionWebService::Base?
I''d like to split up my directly dispatched controller into a layered
dispatch setup with one controller and two services derived from
ActionWebService::Base. However, in doing this I found that logger is
not a class_variable of AWS::Base. This kind of scares me away from
using the layered dispatch mode, as I''d like to have logging in the
method implementations. Is there a clean
2006 Jun 07
1
Web Service: NoMethodError (missing attribute: featured) !?!?!?!?!
Hi all -
I have a Player model. The database looks like this:
+-------------------+--------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+-------------------+--------------+------+-----+---------+----------------+
| id | int(11) | NO | PRI | NULL | auto_increment |
| fname |
2006 Jul 31
5
ActionWebService API
Hi *,
I need to pass a hash to a webservice, so I defined my API with:
api_method :search,
:expects => [{
:tags => :string,
:assignment => :string,
:resource => :string,
:lesson_plan => :string,
:subject => :string,
:all_types => :string
}], :returns => [[Resource]]
when I try to test the webservice with scaffold the
2005 Apr 21
0
Uninitialized constant in 0.12.1?
Is anyone else getting this error message?
[root@dev /home/users/filmfury]# ./script/console
Loading development environment.
/usr/local/lib/ruby/gems/1.8/gems/actionwebservice-0.7.1/lib/
action_web_service/protocol/abstract.rb:71:NameError: uninitialized
constant ActionWebService::Protocol::ActionController
irb(main):001:0>
The message shows up when doing other things as well, such as in
2007 Jan 27
0
Interchanging ActiveRecord and ActionWebService... Help with my problem and suggestions for Best Practices.
Okay, I''m try to support two situations "easily". I need to be able to
use either ActiveRecord or ActionWebService. So I''m trying to handle
this "switch" as transparently as possible.
I''m totally open to suggestions..
Thanks,
Jason
I''m getting the following error:
NoMethodError in Offer renewalController#payment_made
undefined method
2009 Feb 26
1
Problem w/ActionWebService and Inheritance in Service Params
I have a service method that takes a PaymentMethod which can either be a
CreditCard or a PayPal account. When I request the service and pass one
or the other it always comes over as a PaymentMethod; the service
doesn''t seem to know that the parameter is really a CreditCard or
PayPal. Here''s some sample code that illustrates what I''m talking about
more concretely:
2005 Feb 24
8
web services with ActionWebService
<noobalert>
Uh, yeah. So my noob self is showing through again. I''m trying to
write a simple hello-world type web service with the ActionWebService
thingy. I didn''t get very far. I''ve only done web services stuff in
.NET, so I''m not exactly used to this sort of thing.
Anyhow, I have a file, person_api.rb in my app/apis folder. I want to
take a single
2006 Jan 12
1
activewebservice::struct
So I''m playing with AWS. I''ve got a thing called a gallery. I''d like
to return a list of them. I can do this fine if I want to return my
ActiveRecord objects:
class WxApiApi < ActionWebService::API::Base
api_method :list_galleries,
:expects=>[{:login=>:string}],
:returns => [[Gallery]]
end
But the ActiveRecord object exposes a
2005 Jul 25
2
ActionWebService woes
I''m currently writing an app that provides a Web Service.
I''ve got a model Header and an associated has_one HeaderImage and I''m
trying to find a way to make this data available. Defining a normal API:
api_method :header, :expects => [{''id'' => :int}], :returns => [Header]
Only returns the header object without associations, has anyone got
2006 Nov 04
1
layere dispatching - please help!
Hi Folks,
I''m having trouble with setting up web services with layered
dispatching.
I''ve defined my controller (backend_controller.rb) as:
class BackendController < ApplicationController
web_service_dispatching_mode :layered
web_service_scaffold :invoke
web_service (:car) {CarService.new}
end
and my service (node_service.rb) as:
2006 May 31
2
Rails Bug when loading required files for API?
Hello,
I have seen some odd behaviour of my Web Services code plus some
''similar'' postings to this list, so I believe this may be a bug in
Rails. But I''m failry new to RoR, so maybe I''m doing something wrong.
I''ll explain:
I have a WS API defined, communicating with a remote system that
expects a stucture:
When defined like this (all
2007 Jun 19
4
ActionWebService for many APIs in rails?
Hi,
We''ve a pretty large rails application and we are currently deciding
moving a part of the application front-end to a desktop GUI.
For communication between application and GUI we decided to use an API.
So basically what I need is a way to have our models functionality
accessible by the GUI.
The basic idea:
Rails app provides API for models <-> HTTPS Connection <-> GUI
2005 May 31
2
Rails Web Services
This deals with the Rails book, but ActionWebService in general.
I''m having trouble getting the Rails book''s example in the Web Service
chapter working. Everything else works (all the ''depot'' site features up
to that point have been built and work). I don''t think it''s an issue
with the book code being wrong, because the ActionWebService API
2006 May 08
0
Including common code among multiple web services issue?
Hi all -
I''m implementing some web services and every one has at the very least a
"find_newer_than" method.
In my models, I''ve split things up like this and it works great.
----------------------------------------------------------------------------------
class XyzService < WebService
web_service_api XyzApi
.... service specific methods go here...
end
class
2006 Jul 22
0
multiple return values in action web service
Hi all,
Does anyone have any advice about returning multiple values from an
ActionWebService? That is, I''d like to implement something like the
following.
api_method :do_something,
:expects => [{:id => :string}],
:returns => [{:return_code => :int},
{:return_text => :string}]
The easy way to do it would be to
2006 May 24
2
array parameters in web services
I''m working in a web service, actually, I have:
class UnifiedLoginApi < ActionWebService::API::Base
class CLL_Metadata < ActionWebService::Struct
member :key, :string
member :type, :string
member :value, :string
member :webapplication_id, :string
member :user_tenfold_id, :string
member :login_username, :string
2006 Jun 15
2
AWS Client - There has to be a better way
I''m working on building a SOAP client with AWS, i.e:
class PersonAPI < ActionWebService::API::Base
api_method :find_all, :returns => [[Person]]
end
soap_client = ActionWebService::Client::Soap.new(PersonAPI,
"http://...")
persons = soap_client.find_all
This works well but I think it breaks down quickly when you try to do
real world work. Lets take a moderately
2006 Jan 31
0
webservice problem (cant make client)
hey, i have made a webservice
http://twodecode.pilot.localhost.be:3000/backend/wsdl
here i can see the wsdl file
i have a method string Authenticate(string twa, string login, string pass)
when i do /invoke i can test it, this all works
backend_api.rb
class BackendApi < ActionWebService::API::Base
api_method :authenticate,
:expects => [{:twa =>:string},{:login