Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-21995

Restoring backward compatibility for ThreadGroup.max_threads after its removal in oslo.service 4.4.0.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • None
    • None
    • Oslo
    • None
    • Sprint 9, Sprint 10
    • 2
    • Critical

      Description

      The refactor introduced in commit `8c74d0718dc11ed5` removed the `ThreadGroup.max_threads` attribute and replaced it with `thread_pool_size`. Several OpenStack services, notably Heat, still rely on the old attribute and fail when upgrading to oslo.service >= 4.4.0.

      This regression leads to cascading failures across dependent services — growing in impact much like a Fibonacci sequence: each failing component amplifies issues in others, resulting in an increasingly complex upgrade path.

      A patch is now proposed to restore `max_threads` as a read-only, deprecated property that maps to `thread_pool_size` and emits a `DeprecationWarning`. Applications are expected to migrate to the new attribute.

      Impact

      • Breaks compatibility for services still using `ThreadGroup.max_threads`
      • Prevents smooth upgrades to oslo.service 4.4.0 and later
      • Causes service startup failures (e.g., Heat)
      • Introduces cumulative dependency issues (Fibonacci-like propagation)

      Proposed Fix

      • Reintroduce `max_threads` as an alias to `thread_pool_size`
      • Emit `DeprecationWarning` to encourage migration
      • Document the change in release notes
      • Plan removal of the deprecated attribute in a future cycle

      Steps to Reproduce

      1. Upgrade to oslo.service >= 4.4.0
      2. Start a service still referencing `ThreadGroup.max_threads`
      3. Observe `AttributeError` on startup

      Expected Behavior

      Existing services continue functioning using `max_threads` until they migrate to `thread_pool_size`.

      Environment

      • oslo.service 4.4.0+
      • Services depending on legacy `ThreadGroup.max_threads`

              mbollo@redhat.com Daniel Mats Niklas Bengtsson
              mbollo@redhat.com Daniel Mats Niklas Bengtsson
              rhos-dfg-pidone
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: