JustinLove / autoscaler

Start/stop Sidekiq workers on Heroku
226 stars 42 forks source link

403 Forbidden when scaling worker #35

Closed pabloivan57 closed 10 years ago

pabloivan57 commented 10 years ago

I'm having problems with the autoscaler gem. This is a new app I just picked up and seems it was working fine a month ago, this is the problematic strack_trave

2014-04-09T19:25:16.043768+00:00 app[web.1]: "Scaling sidekiq to 1"
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/excon-0.25.1/lib/excon/connection.rb:353:in `response'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/excon-0.25.1/lib/excon/connection.rb:247:in `request'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/excon-0.25.1/lib/excon/middlewares/expects.rb:6:in `response_call'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/heroku-api-0.3.13/lib/heroku/api.rb:76:in `request'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/autoscaler-0.2.1/lib/autoscaler/heroku_scaler.rb:38:in `workers='
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/heroku-api-0.3.13/lib/heroku/api/processes.rb:36:in `post_ps_scale'
2014-04-09T19:25:16.188312+00:00 app[web.1]: Expected(200) <=> Actual(403 Forbidden)
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/autoscaler-0.2.1/lib/autoscaler/sidekiq.rb:17:in `call'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/middleware/chain.rb:114:in `call'
2014-04-09T19:25:16.188542+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/middleware/chain.rb:114:in `invoke'
2014-04-09T19:25:16.188921+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/worker.rb:68:in `client_push'
2014-04-09T19:25:16.188921+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/client.rb:113:in `process_single'
2014-04-09T19:25:16.188921+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/extensions/generic_proxy.rb:17:in `method_missing'
2014-04-09T19:25:16.188921+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/activerecord-3.2.17/lib/active_record/associations/collection_proxy.rb:91:in `each'
2014-04-09T19:25:16.188921+00:00 app[web.1]: /app/vendor/bundle/ruby/2.0.0/gems/sidekiq-2.10.1/lib/sidekiq/client.rb:41:in `push'

The code around is just a call to send an email where we use a worker, I'm receiving 403 Forbidden as it seems we are unable scale the sidekiq worker. I double checked the HEROKU env variables and they seem fine. Is this something related to changes on the API? What can I try? Thanks a lot

JustinLove commented 10 years ago

My guess would be that the heroku app name and/or api key isn't set up correctly.