Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rescue -> Resync all SSH keys seems to crash with sidekiq #169

Closed
niosHD opened this issue Apr 15, 2014 · 2 comments
Closed

Rescue -> Resync all SSH keys seems to crash with sidekiq #169

niosHD opened this issue Apr 15, 2014 · 2 comments
Assignees
Labels

Comments

@niosHD
Copy link

niosHD commented Apr 15, 2014

I just update to the current 0.7.1 version and decided to play around with sidekiq.
When I tried to Resync all SSH keys using sidekiq this jobs always fail for me with the following log:

# Logfile created on 2014-04-15 21:09:01 +0000 by logger.rb/31641
2014-04-15T21:09:13Z 14398 TID-6gndw INFO: Running in ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
2014-04-15T21:09:13Z 14398 TID-6gndw INFO: See LICENSE and the LGPL-3.0 for licensing details.
2014-04-15T21:09:13Z 14398 TID-yyux4 DEBUG: {:queues=>["git_hosting"], :concurrency=>1, :require=>"./", :environment=>"production", :timeout=>8, :error_handlers=>[#<Sidekiq::ExceptionHandler::Logger:0x00000001a067d8>], :lifecycle_events=>{:startup=>[], :quiet=>[], :shutdown=>[]}, :daemon=>true, :pidfile=>"tmp/pids/worker_redmine_git_hosting.pid", :logfile=>"log/worker_redmine_git_hosting.log", :verbose=>true, :strict=>false, :config_file=>"plugins/redmine_git_hosting/config/sidekiq-worker.yml", :tag=>"redmine-2.3"}
2014-04-15T21:09:13Z 14398 TID-yywv4 INFO: Booting Sidekiq 3.0.0 with redis options {}
2014-04-15T21:09:13Z 14398 TID-x1ymk INFO: Booting Sidekiq 3.0.0 with redis options {}
2014-04-15T21:09:56Z 14398 TID-yotsk GithostingShellWorker JID-ff7fcb8b35c87c5863eedf54 INFO: start
2014-04-15T21:09:56Z 14398 TID-yotsk GithostingShellWorker JID-ff7fcb8b35c87c5863eedf54 INFO: update_all_ssh_keys_forced | 23 | {}
2014-04-15T21:09:56Z 14398 TID-yotsk GithostingShellWorker JID-ff7fcb8b35c87c5863eedf54 INFO: fail: 0.173 sec
2014-04-15T21:09:56Z 14398 TID-yotsk WARN: {"retry"=>false, "queue"=>"git_hosting", "class"=>"GithostingShellWorker", "args"=>[{"command"=>"update_all_ssh_keys_forced", "object"=>23, "options"=>{}}], "jid"=>"ff7fcb8b35c87c5863eedf54", "enqueued_at"=>1397596196.143353}
2014-04-15T21:09:56Z 14398 TID-yotsk WARN: wrong number of arguments (1 for 0)
2014-04-15T21:09:56Z 14398 TID-yotsk WARN: /var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/admin_users.rb:14:in `update_ssh_keys'
/var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/admin_users.rb:28:in `update_all_ssh_keys_forced'
/var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/shell.rb:66:in `handle_command'
/var/redmine-2.3/plugins/redmine_git_hosting/app/workers/githosting_shell_worker.rb:9:in `perform'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:50:in `block (2 levels) in process'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:122:in `call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:122:in `block in invoke'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/active_record.rb:6:in `call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/retry_jobs.rb:62:in `call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/logging.rb:11:in `block in call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/logging.rb:22:in `with_context'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/logging.rb:7:in `call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:127:in `call'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:127:in `invoke'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:49:in `block in process'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:92:in `stats'
/var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:48:in `process'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `public_send'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `dispatch'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:122:in `dispatch'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/actor.rb:322:in `block in handle_message'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
/var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'
2014-04-15T21:09:56Z 14398 TID-yotsk ERROR: Sidekiq::Processor crashed!
ArgumentError: wrong number of arguments (1 for 0)
    /var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/admin_users.rb:14:in `update_ssh_keys'
    /var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/admin_users.rb:28:in `update_all_ssh_keys_forced'
    /var/redmine-2.3/plugins/redmine_git_hosting/lib/redmine_gitolite/shell.rb:66:in `handle_command'
    /var/redmine-2.3/plugins/redmine_git_hosting/app/workers/githosting_shell_worker.rb:9:in `perform'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:50:in `block (2 levels) in process'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:122:in `call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:122:in `block in invoke'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/active_record.rb:6:in `call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/retry_jobs.rb:62:in `call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/logging.rb:11:in `block in call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/logging.rb:22:in `with_context'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/server/logging.rb:7:in `call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:127:in `call'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/middleware/chain.rb:127:in `invoke'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:49:in `block in process'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:92:in `stats'
    /var/lib/gems/1.9.1/gems/sidekiq-3.0.0/lib/sidekiq/processor.rb:48:in `process'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `public_send'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `dispatch'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/calls.rb:122:in `dispatch'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/actor.rb:322:in `block in handle_message'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
    /var/lib/gems/1.9.1/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Other operations (e.g. changing user privileges or re-syncing projects) seem to work fine. It is nothing critical but maybe you can fix it easily.

On a side note:
I had to start my worker using the following command:

RAILS_ENV=production sidekiq -C plugins/redmine_git_hosting/config/sidekiq-worker.yml

Using the command from the step by step guide without RAILS_ENV ended with worker crashes due to incorrect database configurations. Maybe this should be added to the guide.

Anyway, thanks for this great plugin! It is really amazing how much features you packed in since the 0.6 version. Kudos for that and keep up this great work!

Regards,
niosHD

@n-rodriguez n-rodriguez self-assigned this Apr 15, 2014
@n-rodriguez
Copy link
Contributor

Hi! I've updated the wiki and fixed the bug in devel branch.
Thanks for your feedback!

@niosHD
Copy link
Author

niosHD commented Apr 16, 2014

Works as advertised! ;)
Thanks a lot!

n-rodriguez pushed a commit that referenced this issue Apr 16, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants