Skip to content

Releases: ruby-shoryuken/shoryuken

v7.0.1

07 Feb 14:53
d094ca3

Choose a tag to compare

  • Enhancement: Add non-retryable exception middleware (Saidbek)

  • Fix: ActiveJob keyword arguments support (mensfeld)

    • Jobs with keyword arguments were broken due to improper argument forwarding in SQSSendMessageParametersSupport#initialize
    • Use Ruby's argument forwarding (...) to properly pass all arguments including keyword arguments
    • #962
  • Fix: Replace ArgumentError with custom FifoDelayNotSupportedError for FIFO delay errors

    • Provides more specific error type for programmatic error handling
    • #957

v7.0.0

19 Jan 11:48
5f619b9

Choose a tag to compare

See the Upgrading to 7.0 guide for detailed migration instructions.

Breaking Changes

Version Requirements

  • Ruby 3.2.0 or higher - Minimum required Ruby version is now 3.2.0
    • Supported Ruby versions: 3.2, 3.3, 3.4
    • Users on Ruby 3.1 should upgrade or remain on Shoryuken 6.x
  • Rails 7.2 or higher - Rails 7.0 and 7.1 have reached end-of-life (April 2025)
    • Supported Rails versions: 7.2, 8.0, and 8.1
    • Users on older Rails versions should upgrade or remain on Shoryuken 6.x

Error Class Hierarchy

  • Add Shoryuken::Errors module with domain-specific error classes
    • Introduces Shoryuken::Errors::BaseError as base class for all Shoryuken errors
    • Shoryuken::Errors::QueueNotFoundError for non-existent or inaccessible SQS queues
    • Shoryuken::Errors::InvalidConfigurationError for configuration validation failures
    • Shoryuken::Errors::InvalidWorkerRegistrationError for worker registration conflicts
    • Shoryuken::Errors::InvalidPollingStrategyError for invalid polling strategy configuration
    • Shoryuken::Errors::InvalidEventError for invalid lifecycle event names
    • Shoryuken::Errors::InvalidDelayError for delays exceeding SQS 15-minute maximum
    • Shoryuken::Errors::InvalidArnError for invalid ARN format
    • Replaces generic Ruby exceptions (ArgumentError, RuntimeError) with specific error types

Other Breaking Changes

  • Removed Shoryuken::Shutdown class (unused since Celluloid removal in 2016)
  • FIFO queues now raise ArgumentError when using delay (fixes #924)
  • Removed core class monkey-patching (Hash and String extensions)
  • Replaced concurrent-ruby internal structures with pure Ruby implementations
  • Require aws-sdk-sqs >= 1.66

New Features

ActiveJob Enhancements

  • Bulk ActiveJob Enqueuing (Rails 7.1+)

    • Implements efficient bulk enqueuing using SQS send_message_batch API
    • Called by ActiveJob.perform_all_later for batching multiple jobs
    • Batches jobs in groups of 10 (SQS limit) per queue
  • ActiveJob Continuations (Rails 8.1+)

    • Implements stopping? method in ActiveJob adapters to signal graceful shutdown
    • Enables jobs to checkpoint progress and resume after interruption
    • See Rails PR #55127 for more details
  • CurrentAttributes Persistence

    • Enables Rails ActiveSupport::CurrentAttributes to flow from enqueue to job execution
    • Automatically serializes current attributes into job payload
    • Usage: require 'shoryuken/active_job/current_attributes' and Shoryuken::ActiveJob::CurrentAttributes.persist('MyApp::Current')

Infrastructure Improvements

  • Use fiber-local storage for logging context (Ruby 3.2+)
  • Implement Zeitwerk autoloading for modern Ruby module loading
  • Replace Concurrent::AtomicFixnum, AtomicBoolean, and Hash with pure Ruby implementations
  • Add comprehensive YARD documentation with yard-lint
  • Increase SendMessageBatch to 1MB to align with AWS (#864)
  • Add enqueue_after_transaction_commit? for Rails 7.2 compatibility (#777)

Bug Fixes

  • Fix ArgumentError when using delay with FIFO queues (#924)
  • Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack (#782, #783)

Full Changelog

See CHANGELOG.md for complete details.

v7.0.0.rc1

17 Nov 08:34
52f67e4

Choose a tag to compare

v7.0.0.rc1 Pre-release
Pre-release
  • Enhancement: Add ActiveJob Continuations support (Rails 8.1+)

    • Implements stopping? method in ActiveJob adapters to signal graceful shutdown
    • Enables jobs to checkpoint progress and resume after interruption
    • Handles past timestamps correctly (SQS treats negative delays as immediate delivery)
    • Tracks shutdown state in Launcher via stopping? flag
    • Leverages existing Shoryuken shutdown lifecycle (stop/stop! methods)
    • Includes comprehensive integration tests with continuable jobs
    • See Rails PR #55127 for more details on ActiveJob Continuations
  • Breaking: Remove support for Rails versions older than 7.2

    • Rails 7.0 and 7.1 have reached end-of-life and are no longer supported
    • Supported versions: Rails 7.2, 8.0, and 8.1
    • Users on older Rails versions should upgrade or remain on Shoryuken 6.x
  • Enhancement: Replace Concurrent::AtomicFixnum with pure Ruby AtomicCounter

    • Removes external dependency on concurrent-ruby for atomic fixnum operations
    • Introduces Shoryuken::Helpers::AtomicCounter as a thread-safe alternative using Mutex
    • Reduces gem footprint while maintaining full functionality
  • Enhancement: Replace Concurrent::AtomicBoolean with pure Ruby AtomicBoolean

    • Removes external dependency on concurrent-ruby for atomic boolean operations
    • Introduces Shoryuken::Helpers::AtomicBoolean extending AtomicCounter
    • Further reduces gem footprint while maintaining full functionality
  • Enhancement: Replace Concurrent::Hash with pure Ruby AtomicHash

    • Removes external dependency on concurrent-ruby for hash operations
    • Introduces Shoryuken::Helpers::AtomicHash with mutex-protected writes and concurrent reads
    • Ensures JRuby compatibility while maintaining high performance for read-heavy workloads
    • #866
    • #867
    • #868
  • Enhancement: Replace core class extensions with helper utilities

    • Removes all core Ruby class monkey-patching (Hash and String extensions)
    • Introduces Shoryuken::Helpers::HashUtils.deep_symbolize_keys for configuration processing
    • Introduces Shoryuken::Helpers::StringUtils.constantize for dynamic class loading
    • Eliminates unnecessary ActiveSupport dependencies
    • Completely removes lib/shoryuken/core_ext.rb file
    • Maintains all existing functionality while following Ruby best practices
    • Improves code maintainability and reduces global namespace pollution
  • Enhancement: Implement Zeitwerk autoloading

    • Replaces manual require statements with Zeitwerk-based autoloading
    • Adds zeitwerk dependency for modern Ruby module loading
    • Splits polling classes into properly named files (BaseStrategy, QueueConfiguration)
    • Reduces startup overhead and improves code organization
    • Maintains backward compatibility while modernizing the codebase
  • Enhancement: Increase SendMessageBatch to 1MB to align with AWS

  • Enhancement: Replace OpenStruct usage with Struct for inline execution

  • Enhancement: Configure server side logging (BenMorganMY)

  • Enhancement: Use -1 as thread priority

  • Enhancement: Add Support for message_attributes to InlineExecutor

  • Enhancement: Introduce trusted publishing

  • Enhancement: Add enqueue_after_transaction_commit? for Rails 7.2 compatibility

  • Enhancement: Bring Ruby 3.4 into the CI

  • Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack

  • Breaking: Remove support of Ruby versions older than 3.1

  • Breaking: Remove support of Rails versions older than 7.0

  • Breaking: Require aws-sdk-sqs >= 1.66:

v7.0.0.alpha2

31 Oct 14:54
dafabc5

Choose a tag to compare

v7.0.0.alpha2 Pre-release
Pre-release
  • Enhancement: Replace Concurrent::AtomicFixnum with pure Ruby AtomicCounter

    • Removes external dependency on concurrent-ruby for atomic fixnum operations
    • Introduces Shoryuken::Helpers::AtomicCounter as a thread-safe alternative using Mutex
    • Reduces gem footprint while maintaining full functionality
  • Enhancement: Replace Concurrent::AtomicBoolean with pure Ruby AtomicBoolean

    • Removes external dependency on concurrent-ruby for atomic boolean operations
    • Introduces Shoryuken::Helpers::AtomicBoolean extending AtomicCounter
    • Further reduces gem footprint while maintaining full functionality
  • Enhancement: Replace Concurrent::Hash with pure Ruby AtomicHash

    • Removes external dependency on concurrent-ruby for hash operations
    • Introduces Shoryuken::Helpers::AtomicHash with mutex-protected writes and concurrent reads
    • Ensures JRuby compatibility while maintaining high performance for read-heavy workloads
    • #866
    • #867
    • #868
  • Enhancement: Replace core class extensions with helper utilities

    • Removes all core Ruby class monkey-patching (Hash and String extensions)
    • Introduces Shoryuken::Helpers::HashUtils.deep_symbolize_keys for configuration processing
    • Introduces Shoryuken::Helpers::StringUtils.constantize for dynamic class loading
    • Eliminates unnecessary ActiveSupport dependencies
    • Completely removes lib/shoryuken/core_ext.rb file
    • Maintains all existing functionality while following Ruby best practices
    • Improves code maintainability and reduces global namespace pollution
  • Enhancement: Implement Zeitwerk autoloading

    • Replaces manual require statements with Zeitwerk-based autoloading
    • Adds zeitwerk dependency for modern Ruby module loading
    • Splits polling classes into properly named files (BaseStrategy, QueueConfiguration)
    • Reduces startup overhead and improves code organization
    • Maintains backward compatibility while modernizing the codebase
  • Enhancement: Increase SendMessageBatch to 1MB to align with AWS

  • Enhancement: Replace OpenStruct usage with Struct for inline execution

  • Enhancement: Configure server side logging (BenMorganMY)

  • Enhancement: Use -1 as thread priority

  • Enhancement: Add Support for message_attributes to InlineExecutor

  • Enhancement: Introduce trusted publishing

  • Enhancement: Add enqueue_after_transaction_commit? for Rails 7.2 compatibility

  • Enhancement: Bring Ruby 3.4 into the CI

  • Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack

  • Breaking: Remove support of Ruby versions older than 3.1

  • Breaking: Remove support of Rails versions older than 7.0

  • Breaking: Require aws-sdk-sqs >= 1.66:

v7.0.0.alpha1

28 May 19:43
546e4b8

Choose a tag to compare

v7.0.0.alpha1 Pre-release
Pre-release
  • Enhancement: Use -1 as thread priority

  • Enhancement: Add Support for message_attributes to InlineExecutor

  • Enhancement: Introduce trusted publishing

  • Enhancement: Add enqueue_after_transaction_commit? for Rails 7.2 compatibility

  • Enhancement: Bring Ruby 3.4 into the CI

  • Fix integration tests by updating aws-sdk-sqs and replacing moto with LocalStack

  • Breaking: Remove support of Ruby versions older than 2.7

  • Breaking: Remove support of Rails versions older than 6.1

  • Breaking: Require aws-sdk-sqs >= 1.66: