Preventing a module from being loaded by sidekiq

8 views
Skip to first unread message

Jordan Brock

unread,
Jun 26, 2015, 3:34:57 AM6/26/15
to sid...@googlegroups.com
I have a module within the config/initializers directory that my Rails app needs to load upon boot. However, I don't want the sidekiq processes to load the file. The module contains an EventMachine, which ends being started by both the Rails process and Sidekiq process.

Is there a simple way from preventing the module from being loaded by sidekiq when it starts?

Thanks,

Jordan

Mike Perham

unread,
Jun 26, 2015, 8:55:03 AM6/26/15
to sid...@googlegroups.com
Sidekiq.configure_client do |config|
  require 'module'
end
--
You received this message because you are subscribed to the Google Groups "Sidekiq" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sidekiq+u...@googlegroups.com.
To post to this group, send email to sid...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sidekiq/9c335903-debd-453a-a344-f33125f098aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages