Displaying 11 results from an estimated 11 matches for "web_service_dispatching_mode".
2009 Aug 25
5
uninitialized constant
...pi.rb.
class HelloMessageApi < ActionWebService::API::Base
api_method :hello_message, :expects => [{:firstname=>:string},
{:lastname=>:string}], :returns => [:string]
end
controller ->
class HelloMessageController < ApplicationController
web_service_api HelloMessageApi
web_service_dispatching_mode :direct
wsdl_service_name ''hello_message''
web_service_scaffold :invoke
def hello_message(firstname, lastname)
return "Hello "+ firstname +" "+lastname
end
end
but it givesthe following error
" uninitialized constant HelloMessageController::He...
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:
class CarApi < ActionWebService::API::Base
api_method :find_all_cars,
:returns => [[:int]]
api_method :find_car_by_id,
:...
2006 Mar 02
1
web serveces problem
...''you are trying to talk with Tyra version 0.25 with a different
version !''
else
''server and client versions match - 0.25''
end
end
end
3. app/controller/kate_controller.rb:
class KateController < ApplicationController
web_service_scaffold :invoke
web_service_dispatching_mode :layered
web_service :kate, KateAPIService.check_version
end
when I go to the browser to /myapp/kate/api i get:
NoMethodError in <controller not set>#<action not set>
undefined method `check_version'' for KateAPIService:Class
and in the log:
oMethodError (undefined method `ch...
2006 Aug 16
7
ActionWebService: XMLRPC Server Multicall possible?
Hi all,
I have a question concerning ActionWebService XMLRPC servers: Is it
possible to send multicall requests to the Web service? I tried to
use multicall and get the error message:
no such method ''system.multicall'' on API [MyAPI]
In Changeset 2021 there is the following commit message:
add ''system.multicall'' support to XML-RPC. boxcarred methods must
2006 Jan 04
5
Webservice External XMLRPC
...ring}],
:returns => [Customer]
end
class DirectSpoolService < ActionWebService::Base
web_service_api DirectSpoolAPI
def add(html,from)
Customer.find(:first)
end
def remove
end
end
class ApiController < ApplicationController
skip_before_filter :login_required
web_service_dispatching_mode :delegated
web_service_scaffold :invoke
web_service(:directspool) {DirectSpoolService.new}
end
The controller behaves fine when accessing it with :
http://localhost:3003/api/invoke, and
curl -d ''<?xml version="1.0"
?><methodCall><methodName>Add</me...
2006 Jan 06
6
AWS and array of Model
...api_method :listUsers,:returns=>[[User]]
end
class UserAdminService < ActionWebService::Base
web_service_api UserAdminAPI
def listUsers
User.find(:all)
end
end
class AdminController < ApplicationController
wsdl_service_name ''Admin''
web_service_dispatching_mode :delegated
web_service_scaffold :invoke
web_service(:user) { UserAdminService.new }
end
What''s the problem? (If I change the return variable to :string and I in
the implementation I use YAML.dump User.find(:all). It''s get back the value.
the flul log: http://www.rafb.net/pa...
2006 Aug 10
1
Web service SOAP URLs started failing with 1.1.4 or using 1.1.2 security patch
Railers,
I''m trying to figure out why invocations to my Web service URLs work
with Rails 1.1.2 but fail both with Rails 1.1.4 (and 1.1.5) and when I
apply the new 1.1.2 security patch to Rails 1.1.2.
It looks like they are failing with SOAP clients but succeeding with
XML-RPC clients.
The URL that used to work is of the form
http://localhost:3000/my_controller/ServiceName/api. When I
2006 Jun 07
0
Logger in ActionWebService::Base?
...yered dispatch mode, as I''d like to have logging in the
method implementations. Is there a clean way of accessing the
Rails::Configuration logger from ActionWebService::Base, or should I
stick with web_service_dispatch_mode :direct for now?
class FooController < ApplicationController
web_service_dispatching_mode :layered
web_service(:bar) { BarService.new }
end
class BarApi < ActionWebService::API::Base
api_method :qux
end
class BarService < ActionWebService::Base
def qux
p logger
end
end
gives:
NameError (undefined local variable or method `logger'' for
#<BarService:0xb76...
2006 Nov 21
2
before_filter in actionwebservice controller using direct dispatching
...ation instead even
with direct dispatching mode? Or can I not have the authorize method
in application.rb?
undefined method `authorize'' for #<CustomerController:0x8ee54e0>
class CustomerController < ActionController::Base
after_filter :end_session
before_filter :authorize
web_service_dispatching_mode :direct
web_service_scaffold :invoke
web_service_api CustomerApi
end
Chris
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-t...
2010 Nov 02
0
webservice - get client ip address
Hi
I have the following problem in my application I have
in the controller:
class XmlrpcController < ApplicationController
web_service_dispatching_mode :layered
wsdl_service_name ''weblogUpdates.ping''
web_service_scaffold :invoke
web_service :weblogUpdates, WeblogUpdates.new
end
in the api definition file:
-------
class WeblogUpdatesApi < ActionWebService::API::Base
inflect_names false
api_method :ping, :e...
2006 May 17
3
WebServices: execution expired
...g to test this web service:
Pointed to: http://localhost:3000/news/list
class NewsService < ActionWebService::Base
web_service_api NewsApi
def list
[NewsTopic.new, NewsTopic.new]
end
end
class NewsController < ApplicationController
wsdl_service_name ''news''
web_service_dispatching_mode :delegated
web_service :news, NewsService.new
def list
news = ActionWebService::Client::Soap.new(
NewsApi, "http://localhost:3000/news/news")
rsp = news.list
render_text rsp.to_s
end
end
Strange, but I have successful log message:
Web Service Response (0.024314)...