N
N
nd0ut2013-08-30 20:41:44
Ruby on Rails
nd0ut, 2013-08-30 20:41:44

Sidekiq confusing environments?

There are two environments: staging and production. Spinning physically on one machine.
No additional sidekick settings were made.
The problem is that each of the sidekicks takes a job from the queue and tries to execute it in its own environment, regardless of which environment it was created from. Accordingly, jobs fail due to the lack of the necessary data in the database.
Jobs are created just like baby.delay_for(9.months).born Is that
how it should be by default? How can I split the queues? Use different databases or different queues?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
nd0ut, 2013-08-31
@nd0ut

It's decided.
Sidekiq.configure_server do |config| config.redis = { :url => 'redis://localhost:6379', :namespace => Rails.env } end
Sidekiq.configure_client do |config| config.redis = { :url => 'redis://localhost:6379', :namespace => Rails.env } end

I
int03e, 2013-08-30
@int03e

It won't help?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question