Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2280692

Summary: The foreman-rake command warns that config.options[:key] = value is deprecated
Product: Red Hat Satellite Reporter: Alexon Oliveira <alolivei>
Component: Foreman ProxyAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED WONTFIX QA Contact: Satellite QE Team <sat-qe-bz-list>
Severity: low Docs Contact:
Priority: unspecified    
Version: 6.14.2CC: aruzicka, rlavi
Target Milestone: Unspecified   
Target Release: Unused   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-05-30 14:56:06 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Alexon Oliveira 2024-05-15 17:46:19 UTC
Description of problem:

When preparing Satellite 6.14.2 for an upgrade to 6.15, a task cleanup is executed previously using foreman-rake, but the output warns about a deprecated parameter in the code, as follows:

WARN: `config.options[:key] = value` is deprecated, use `config[:key] = value`: ["/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:103:in `sidekiq_worker?'", "/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:155:in `block in world_config'"]

WARN: `config.options[:key] = value` is deprecated, use `config[:key] = value`: ["/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:103:in `sidekiq_worker?'", "/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:99:in `increase_db_pool_size?'"]


Version-Release number of selected component (if applicable):

Satellite 6.14.2

How reproducible:

Always, but before upgrading to 6.15

Steps to Reproduce:

1. Run the following command and see the output: foreman-rake foreman_tasks:cleanup TASK_SEARCH='label ~ *' STATES='running,pending,stopped,paused' VERBOSE=true

Actual results:

Despite the command runs successfully, a warning message is thrown due a deprecated code.

Expected results:

No deprecation message should be thrown to the user when running the command.

Additional info:

Here's the full output:

===
[root@satellite ~]# foreman-rake foreman_tasks:cleanup TASK_SEARCH='label ~ *' STATES='running,pending,stopped,paused' VERBOSE=true
2024-05-13T19:12:15.740Z pid=3717 tid=121p WARN: `config.options[:key] = value` is deprecated, use `config[:key] = value`: ["/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:103:in `sidekiq_worker?'", "/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:155:in `block in world_config'"]
2024-05-13T19:12:29.152Z pid=3717 tid=121p WARN: `config.options[:key] = value` is deprecated, use `config[:key] = value`: ["/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:103:in `sidekiq_worker?'", "/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:99:in `increase_db_pool_size?'"]
2024-05-13T19:12:29.240Z pid=3717 tid=121p WARN: `config.options[:key] = value` is deprecated, use `config[:key] = value`: ["/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:103:in `sidekiq_worker?'", "/usr/share/gems/gems/dynflow-1.7.0/lib/dynflow/rails/configuration.rb:99:in `increase_db_pool_size?'"]
About to remove 557 tasks matching filter
0/557
557/557
Deleted 557 tasks matching filter
No orphaned task locks found, skipping.
About to remove 741 orphaned task links
0/741
741/741
Deleted 741 orphaned task links
No orphaned execution plans found, skipping.
No orphaned job invocations found, skipping.
===

I could finish the command successfully and proceed with the upgrade with no further issues. After upgrading to Satellite 6.15, the warning message is gone, as follows:

===
[root@satellite ~]# foreman-rake foreman_tasks:cleanup TASK_SEARCH='label ~ *' STATES='running,pending,stopped,paused' VERBOSE=true
About to remove 71 tasks matching filter
0/71
71/71
Deleted 71 tasks matching filter
About to remove 13 orphaned task locks
0/13
13/13
Deleted 13 orphaned task locks
About to remove 176 orphaned task links
0/176
176/176
Deleted 176 orphaned task links
No orphaned execution plans found, skipping.
No orphaned job invocations found, skipping.
===

I suppose the issue is fixed in the newer version, but it would be good to have this fix backported to 6.14 if it's possible.

Comment 1 Ron Lavi 2024-05-30 14:56:06 UTC
Hi, since there are no planned 6.14.z releases at the moment, and the issue is fixed in 6.15.0
we decided to close this bug, feel free to re-open if there's any concerns of customer's impact