influitive / apartment-sidekiq

Sidekiq support for the Apartment Gem
MIT License
126 stars 54 forks source link

#12 Rails 5.0 incompatibilities Fix #15

Open nimir opened 8 years ago

nimir commented 8 years ago

Cause: Debugging #12 seems when the client-side middleware is chained in server, Apartment::Tenant.current is set to base tenant overriding the correct current_tenant stored in item['apartment'].

Chaining client-side in both places is mentioned in Sidekiq docs https://github.com/mperham/sidekiq/wiki/Middleware#sometimes-client-side-middleware-should-be-registered-in-both-places but not sure why it's breaking things now in rails 5.

Fix: Removing the server chain fixes this for me [rails5, mysql, using schema=true]

P.S Not sure if this has some other side effects and it will require more testing.

ACPK commented 5 years ago

@nimi - Any word on why this hasn't been pushed in almost three years?

krtschmr commented 3 years ago

@ACPK due to conflicts :P