Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate UniqueJob from ApplicationJob #2187

Closed
channainfo opened this issue Dec 24, 2024 · 0 comments · Fixed by #2248
Closed

Separate UniqueJob from ApplicationJob #2187

channainfo opened this issue Dec 24, 2024 · 0 comments · Fixed by #2248
Assignees
Labels
Milestone

Comments

@channainfo
Copy link
Owner

Our current ApplicationJob is set as a unique job by default, which reduces throughput since every job inherits this uniqueness. To improve efficiency, we should configure ApplicationJob to be non-unique by default. For jobs requiring uniqueness, we can create a specialized UniqueJob class that extends ApplicationJob. This approach prevents unintentionally marking all jobs as unique while maintaining clarity and control over job behavior.

redlock (2.0.6) lib/redlock/client.rb in lock_instances at line 323
redlock (2.0.6) lib/redlock/client.rb in block in try_lock_instances at line 275
redlock (2.0.6) lib/redlock/client.rb in times at line 271
redlock (2.0.6) lib/redlock/client.rb in try_lock_instances at line 271
redlock (2.0.6) lib/redlock/client.rb in lock at line 79
activejob-uniqueness (0.3.1) lib/active_job/uniqueness/strategies/base.rb in lock at line 24
activejob-uniqueness (0.3.1) lib/active_job/uniqueness/strategies/base.rb in before_enqueue at line 59
activejob-uniqueness (0.3.1) lib/active_job/uniqueness/active_job_patch.rb in block (2 levels) in <module:ActiveJobPatch> at line 50
activesupport (7.0.8) lib/active_support/callbacks.rb in instance_exec at line 467
activesupport (7.0.8) lib/active_support/callbacks.rb in block in make_lambda at line 467
activesupport (7.0.8) lib/active_support/callbacks.rb in block (2 levels) in halting at line 199
activesupport (7.0.8) lib/active_support/callbacks.rb in block (2 levels) in default_terminator at line 687
activesupport (7.0.8) lib/active_support/callbacks.rb in catch at line 686
activesupport (7.0.8) lib/active_support/callbacks.rb in block in default_terminator at line 686
activesupport (7.0.8) lib/active_support/callbacks.rb in block in halting at line 200
activesupport (7.0.8) lib/active_support/callbacks.rb in block in invoke_before at line 595
activesupport (7.0.8) lib/active_support/callbacks.rb in each at line 595
activesupport (7.0.8) lib/active_support/callbacks.rb in invoke_before at line 595
activesupport (7.0.8) lib/active_support/callbacks.rb in block in run_callbacks at line 116
activejob (7.0.8) lib/active_job/instrumentation.rb in block in instrument at line 25
activesupport (7.0.8) lib/active_support/notifications.rb in block in instrument at line 206
activesupport (7.0.8) lib/active_support/notifications/instrumenter.rb in instrument at line 24
sentry-rails (5.11.0) lib/sentry/rails/tracing.rb in instrument at line 54
activesupport (7.0.8) lib/active_support/notifications.rb in instrument at line 206
activejob (7.0.8) lib/active_job/instrumentation.rb in instrument at line 35
activejob (7.0.8) lib/active_job/instrumentation.rb in block (2 levels) in <module:Instrumentation> at line 9
activesupport (7.0.8) lib/active_support/callbacks.rb in instance_exec at line 127
activesupport (7.0.8) lib/active_support/callbacks.rb in block in run_callbacks at line 127
semantic_logger (4.16.1) lib/semantic_logger/base.rb in block in tagged at line 190
semantic_logger (4.16.1) lib/semantic_logger/semantic_logger.rb in tagged at line 346
semantic_logger (4.16.1) lib/semantic_logger/base.rb in tagged at line 202
rails_semantic_logger (4.17.0) lib/rails_semantic_logger/extensions/active_job/logging.rb in tag_logger at line 13
activejob (7.0.8) lib/active_job/logging.rb in block (2 levels) in <module:Logging> at line 14
activesupport (7.0.8) lib/active_support/callbacks.rb in instance_exec at line 127
activesupport (7.0.8) lib/active_support/callbacks.rb in block in run_callbacks at line 127
activesupport (7.0.8) lib/active_support/callbacks.rb in run_callbacks at line 138
activejob (7.0.8) lib/active_job/enqueuing.rb in enqueue at line 63
activejob (7.0.8) lib/active_job/enqueuing.rb in perform_later at line 30
commissioner (f17c557f7772) app/interactors/spree_cm_commissioner/waiting_room_session_creator.rb in call_other_waiting_guests at line 52
commissioner (f17c557f7772) app/interactors/spree_cm_commissioner/waiting_room_session_creator.rb in call at line 16

@channainfo channainfo added the enhancement New feature or request label Dec 24, 2024
@channainfo channainfo added this to the System milestone Dec 24, 2024
@LengTech11 LengTech11 self-assigned this Jan 10, 2025
@LengTech11 LengTech11 moved this from 📒 Backlog to 👀 In review in Spree CM Commissioner Jan 10, 2025
@LengTech11 LengTech11 linked a pull request Jan 10, 2025 that will close this issue
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Spree CM Commissioner Jan 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants