rails-on-services / apartment

Database multi-tenancy for Rack (and Rails) applications
376 stars 151 forks source link

Use ActiveSupport::CurrentAttributes in apartment-sidekiq for apartment name #205

Open jordan-brough opened 2 years ago

jordan-brough commented 2 years ago

Sidekiq recently added support for ActiveSupport::CurrentAttributes:

Would y'all be open to a PR that updates apartment-sidekiq to use CurrentAttributes for persisting the tenant on Sidekiq jobs if the Sidekiq version is high enough (>= 6.3.0)? Or maybe a configuration option to enable that?

mnovelo commented 6 months ago

Sounds good! We'd definitely be open to taking a look if you wrote a PR