这是indexloc提供的服务,不要输入任何密码
Skip to content

Add perform_after_commit to ActiveJob jobs? #27

@sunny

Description

@sunny

Since it is a common use to use after_commit around ActiveJob calls (like in #19), would it make sense to add to this gem a perform_after_commit method to all ActiveJob jobs?

I use the following concern in my app:

module AfterCommitableJob
  extend ActiveSupport::Concern

  class_methods do
    def perform_after_commit(...)
      AfterCommitEverywhere.after_commit do
        perform_later(...)
      end
    end
  end
end

Would more people benefit from including this in after_commit_everywhere directly?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions