IronWorker Master/slave setup results in typhoeus typhoeus_wrapper.rb:66:in `handle_response': HTTP 400 Error.

8 views
Skip to first unread message

Daniel Gutmann

unread,
Dec 9, 2013, 10:27:43 AM12/9/13
to ironwork...@googlegroups.com
Hi,

I am setting up a simple Ironworker Master/Slave worker,

but Iam consistently getting this error

/Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/rest-2.6.3/lib/rest/wrappers/typhoeus_wrapper.rb:66:in `handle_response': HTTP 400 Error. (Rest::HttpError)from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/rest-2.6.3/lib/rest/wrappers/typhoeus_wrapper.rb:74:in `post'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/rest-2.6.3/lib/rest/client.rb:195:in `block in post'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/rest-2.6.3/lib/rest/client.rb:142:in `perform_op'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/rest-2.6.3/lib/rest/client.rb:194:in `post'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/iron_core-1.0.1/lib/iron_core/client.rb:192:in `post'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/iron_worker_ng-1.0.4/lib/iron_worker_ng/api_client.rb:71:in `tasks_create'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/iron_worker_ng-1.0.4/lib/iron_worker_ng/client.rb:282:in `tasks_create'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/iron_worker_ng-1.0.4/lib/iron_worker_ng/client.rb:18:in `method_missing'

from /var/folders/lf/gbbgv7mn7_15znyc0m92x3nh0000gn/T/iron-worker-ng-20131209-65715-1wav70r-container/messages_dispatcher.rb:26:in `block in <top (required)>'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/activerecord-4.0.0/lib/active_record/relation/delegation.rb:13:in `each'

from /Users/Dan/.rvm/gems/ruby-1.9.3-head@healthberry/gems/activerecord-4.0.0/lib/active_record/relation/delegation.rb:13:in `each'

from /var/folders/lf/gbbgv7mn7_15znyc0m92x3nh0000gn/T/iron-worker-ng-20131209-65715-1wav70r-container/messages_dispatcher.rb:24:in `<top (required)>'

from __runner__.rb:213:in `require'

from __runner__.rb:213:in `<main>'



Here is the code that is producing this error:

Master:
# require 'models/authentication'
require 'iron_worker_ng'
require 'active_record'
require 'models/authentication'
require 'models/user'
ActiveRecord::Base.establish_connection('token and secret deleted')
client = IronWorkerNG::Client.new(:token => "token here", :project_id => "project id here")
@auth = Authentication.all
@auth.each do |a|
client.tasks.create("TweetMessagesWorker", user_id: a.user_id)
end

master.worker:
runtime "ruby"
gem "pg"
gem "activerecord"
exec "messages_dispatcher.rb"
# Merging models
dir '../app/models/'
full_remote_build true # Or remote


Slave:
require 'iron_worker_ng'
puts params[:user_id]

Slave.worker:
runtime "ruby"
name 'TweetMessagesWorker'
exec 'messages_worker.rb'
full_remote_build true # Or remote

Does someone know how to solve this issue?

~ Dan



Chad Arimura

unread,
Dec 9, 2013, 1:21:15 PM12/9/13
to ironwork...@googlegroups.com
Hey Daniel,

This list has been mostly deprecated for some time. Can you repost your question to stackoverflow using a label Iron.io or IronWorker?

Thanks!!




--
Chad Arimura
CEO, Iron.io
415-935-3448
http://www.iron.io

@chadarimura @getiron


--
You received this message because you are subscribed to the Google Groups "IronWorker" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ironworker-use...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages