Skip to content

Releases: Shopify/maintenance_tasks

Maintenance Tasks v1.7.0

28 Jan 20:35
358db9c

Choose a tag to compare

This release brings optimistic locking to the gem to handle race conditions. In order to opt into optimistic locking, you'll need to run the necessary migration to add a lock_version column to your maintenance_tasks_runs table. See instructions in the README to learn more about copying gem migrations to your app.

New features

Deprecations

Bug Fixes

  • Support Sorbet-annotated task code display in task UI by @tyetraskshopify in #524
  • Race conditions now handled via optimistic locking by @adrianna-chang-shopify in #549

Other Changes

New Contributors

Full Changelog: v1.6.0...v1.7.0

Version v1.6.0

05 Nov 21:03
4796835

Choose a tag to compare

New features

  • Change the name of the CSV file before uploading #466
  • Change CSV collection implementation to use a strategy pattern #465
  • Delimit ticks in progress text #483
  • Introduce callbacks for Task lifecycle #484
  • Allow Run model to be injected #498

Fixes

  • Set started_at on MaintenanceTasks::Run if error occurs before #on_start #469
  • Support SQLite and Postgres #468
  • Raise Active Storage error in CSV collection method #491
  • Fix race condition when moving to running #515
  • Avoid iteration for stopping race condition #516

MaintenanceTasks v1.5.0

28 Jul 17:00
e64cdf0

Choose a tag to compare

New features

  • Allow custom backtrace cleaners to be configured. #453
  • Show Task Run's arguments in the UI. #455, #460

Fixes

  • Remove status transition of paused => cancelled from valid transitions. #434
  • Document how to upgrade the gem when migrations have been deleted. #442
  • Add reusable stuck tasks constant. #448
  • Persist job_id to the Run before it is enqueued. #451 #459
  • Add time spent running to Task show page. #452
  • Remove n+1 query for active storage attachments on index page. #461

MaintenanceTasks v1.4.0

07 Jun 15:27
64ad4a5

Choose a tag to compare

This release makes change to the database schema. Please see upgrade instructions in the README.

New features

  • Support for batched ActiveRecord::Relation collections. #409
  • Tasks support custom parameter usage. #413, #428

Fixes

  • Post-install message removed. #426
  • Ensure bin/ prefix specified with Rails commands. #429
  • Return a Duration instead of a Time, Run#estimated_completion_time => Run#time_to_completion. #430

MaintenanceTasks v1.3.0

13 May 14:09
643cce9

Choose a tag to compare

New features

  • Tasks now support throttle conditions. #400

Fixes

  • Improvements to the task_spec generator. #395
  • TaskJob behaviour extracted to a concern. #403

MaintenanceTasks v1.2.2

16 Apr 19:59
f8c53c0

Choose a tag to compare

Fixes

  • Make Active Storage optional. #391
  • Raise early when Active Storage is not set up. #392

MaintenanceTasks v1.2.1

29 Mar 19:24
fe02ba6

Choose a tag to compare

Fixes

Preserve compatibility with apps using Rails versions < 6.1 when calling .has_one_attached in Run. #385

MaintenanceTasks v1.2.0

29 Mar 13:13
befb093

Choose a tag to compare

New features

  • The Active Storage service used for storing CSV files can now be configured in the gem. #372
  • Make progress information available in the info card, rather than in the title attribute of the progress bar. #377

Fixes

  • Minimum accepted version used in ActiveRecord::Migration classes. #367
  • Handle scenario where there is no run object when an error is raised and rescued within TaskJob. #375

Other Changes

  • Pagy removed as a dependency. Runs are now paginated using cursor-based pagination. #371

MaintenanceTasks v1.1.2

02 Mar 19:41
b7aa403

Choose a tag to compare

Fixes

  • Avoid errors due to active_storage_attachments table not existing if app doesn't have Active Storage set up. #359

MaintenanceTasks v1.1.1

01 Mar 21:42
0c5813c

Choose a tag to compare

Fixes

  • Support for Rails application with config.include_all_helpers = false. #337@shouichi
  • Fix duplicated timestamps in individual Task page view. #338
  • Fix race conditions due to callback ordering by postponing the reenqueue of the job. #335, #345
  • Remove redundant index on runs table. #342, #346
  • Avoid using private_constant. #314, #344
  • Fix support for the classic autoloader. #347, #351
  • Prevent Task.named from returning constants that are not Task classes. #348, #349
  • Don't show indefinite progress bar when Task finishes. #353