Skip to content

Latest commit

 

History

History
153 lines (102 loc) · 6.64 KB

CHANGELOG.md

File metadata and controls

153 lines (102 loc) · 6.64 KB

Changelog

5.1.0 (2024-01-21)

Features

  • use zeitwerk loader instead of ActiveSupport::Autoload (b5082fd)

5.0.1 (2024-01-21)

Features

  • add release workflow (5d32520)
  • add ruby 3.1 test/support (#60) (514f042)
  • Add testing for activerecord 7.1 and support for trilogy adapter (#77) (69c23fe)
  • add truffleruby support (#62) (ec34bd4)

Bug Fixes

  • User may sometimes pass in non-strings, such as integers (#55) (9885597)

5.0.0

  • Drop support for EOL rubies and activerecord (ruby below 2.7 and activerecord below 6.1).
  • Allow lock name to be integer
  • Jruby support
  • Truffleruby support
  • Add with_advisory_lock!, which raises an error if the lock acquisition fails
  • Add disable_query_cache option to with_advisory_lock
  • Drop support for mysql < 5.7.5

4.6.0

  • Support for ActiveRecord 6
  • Add Support for nested locks in MySQL

4.0.0

  • Drop support for unsupported versions of activerecord
  • Drop support for unsupported versions of ruby

3.2.0

3.1.1

  • Joel Turkel added require 'active_support' (it was required, but relied on downstream gems to pull in active_support before pulling in with_advisory_lock). Thanks!

3.1.0

3.0.0

  • Added jruby/PostgreSQL support for Rails 4.x
  • Reworked threaded tests to allow jruby tests to pass

API changes

  • yield_with_lock_and_timeout and yield_with_lock now return instances of WithAdvisoryLock::Result, so blocks that return false are not misinterpreted as a failure to lock. As this changes the interface (albeit internal methods), the major version number was incremented.
  • with_advisory_lock_result was introduced, which clarifies whether the lock was acquired versus the yielded block returned false.

2.0.0

  • Lock timeouts of 0 now attempt the lock once, as per suggested by Jon Leighton and implemented by Abdelkader Boudih. Thanks to both of you!
  • Pull request 11 fixed a downstream issue with jruby support! Thanks, Aaron Todd!
  • Added Travis tests for jruby
  • Dropped support for Rails 3.0, 3.1, and Ruby 1.8.7, as they are no longer receiving security patches. See http://rubyonrails.org/security/ for more information. This required the major version bump.
  • Refactored advisory_lock_exists? to use existing functionality
  • Fixed sqlite's implementation so parallel tests could be run against it

1.0.0

  • Releasing 1.0.0. The interface will be stable.
  • Added advisory_lock_exists?. Thanks, Sean Devine, for the great pull request!
  • Added Travis test for Rails 4.1

0.0.10

  • Explicitly added MIT licensing to the gemspec.

0.0.9

  • Merged in Postgis Adapter Support to address issue 7 Thanks for the pull request, Abdelkader Boudih!
  • The database switching code had to be duplicated by Closure Tree, so I extracted a new WithAdvisoryLock::DatabaseAdapterSupport one-trick pony.
  • Builds were failing on Travis, so I introduced a global lock prefix that can be set with the WITH_ADVISORY_LOCK_PREFIX environment variable. I'm not going to advertise this feature yet. It's a secret. Only you and I know, now. shhh

0.0.8

  • Addressed issue 5 by using a deterministic hash for Postgresql + MRI >= 1.9. Thanks for the pull request, Joel Turkel!
  • Addressed issue 2 by using a cache-busting query for MySQL and Postgres to deal with AR value caching bug. Thanks for the pull request, Jaime Giraldo!
  • Addressed issue 4 by adding support for em-postgresql-adapter. Thanks, lestercsp!

(Hey, github—your notifications are WAY too easy to ignore!)

0.0.7

  • Added Travis tests for Rails 3.0, 3.1, 3.2, and 4.0
  • Fixed MySQL bug with select_value returning a string instead of an integer when using AR 3.0.x

0.0.6

  • Only require ActiveRecord >= 3.0.x
  • Fixed MySQL error reporting

0.0.5

  • Asking for the currently acquired advisory lock doesn't re-ask for the lock now.
  • Introduced NestedAdvisoryLockError when asking for different, nested advisory locksMySQL

0.0.4

  • Moved require into on_load, which should speed loading when AR doesn't have to spin up

0.0.3

  • Fought with ActiveRecord 3.0.x and 3.1.x. You don't want them if you use threads—they fail predictably.

0.0.2

  • Added warning log message for nested MySQL lock calls
  • Randomized lock wait time, which can help ameliorate lock contention

0.0.1

  • First whack