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 1900533 - responses to /api/v2/settings/<id> no longer contain 'created_at' and 'updated_at' attrs
Summary: responses to /api/v2/settings/<id> no longer contain 'created_at' and 'update...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Settings
Version: 6.9.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.9.0
Assignee: Ondřej Ezr
QA Contact: Devendra Singh
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-11-23 10:09 UTC by Roman Plevka
Modified: 2021-04-21 13:18 UTC (History)
4 users (show)

Fixed In Version: foreman-2.3.1.1-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-04-21 13:18:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 31285 0 Normal Closed responses to /api/v2/settings/<id> no longer contain 'created_at' and 'updated_at' attrs 2021-01-20 10:00:20 UTC

Description Roman Plevka 2020-11-23 10:09:06 UTC
foreman-2.3.0-0.7.rc1.el7sat.noarch

The attrs are missing in responses to both GET and PUT requests (and possibly POST too)


```
020-11-10T13:03:46 [I|app|12f445d8] Started PUT "/api/v2/settings/discovery_location" for 127.0.0.1 at 2020-11-10 13:03:46 +0100
2020-11-10T13:03:46 [I|app|12f445d8] Processing by Api::V2::SettingsController#update as JSON
2020-11-10T13:03:46 [I|app|12f445d8]   Parameters: {"setting"=>{"value"=>"[FILTERED]"}, "apiv"=>"v2", "id"=>"discovery_location"}
2020-11-10T13:03:46 [D|app|12f445d8] Authenticated user admin against INTERNAL authentication source
2020-11-10T13:03:46 [D|app|12f445d8] Post-login processing for admin
2020-11-10T13:03:46 [I|app|12f445d8] Authorized user admin(Admin User)
2020-11-10T13:03:46 [D|app|12f445d8] Post-login processing for admin
2020-11-10T13:03:47 [D|tax|12f445d8] Current location set to none
2020-11-10T13:03:47 [D|tax|12f445d8] Current organization set to none
2020-11-10T13:03:47 [D|tax|12f445d8] Current location set to none
2020-11-10T13:03:47 [D|tax|12f445d8] Current organization set to none
2020-11-10T13:03:47 [I|app|12f445d8]   Rendering api/v2/settings/update.json.rabl
2020-11-10T13:03:47 [I|app|12f445d8]   Rendered api/v2/settings/update.json.rabl (Duration: 10.0ms | Allocations: 9623)
2020-11-10T13:03:47 [D|app|12f445d8] Body: {"description":"The default location to place discovered hosts in","category":"Setting::Discovered","settings_type":"string","default":"","id":"discovery_location","name":"discovery_location","full_name":"Discovery location","value":"rdrbVOgGL","category_name":"Discovered","readonly":false,"config_file":"settings.yaml","encrypted":false,"select_values":{"Default Location":"Default Location","hSifWeKfZA":"hSifWeKfZA","InvpeNKSWxY":"InvpeNKSWxY","KVKnKAVhOPuN":"KVKnKAVhOPuN","mfHnRd":"mfHnRd","plkDdIVt":"plkDdIVt","pVdbkevdTXD":"pVdbkevdTXD","rdrbVOgGL":"rdrbVOgGL","roCPQxZwGx":"roCPQxZwGx","SPwWAicNZ":"SPwWAicNZ","umgWgPLbmU":"umgWgPLbmU","zEZwsKid":"zEZwsKid"}}

```

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

Comment 1 Roman Plevka 2020-11-23 10:10:17 UTC
this is a regression from 6.8

Comment 2 Bryan Kearney 2020-12-08 04:04:11 UTC
Upstream bug assigned to oezr

Comment 3 Bryan Kearney 2020-12-08 04:04:13 UTC
Upstream bug assigned to oezr

Comment 4 Bryan Kearney 2020-12-10 16:04:26 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/31285 has been resolved.

Comment 6 Devendra Singh 2021-01-20 10:46:17 UTC
Verified on 6.9 Snap 9

Verification points:

1: Hit the GET request of discovery_location and now we able to see the "created_at" and "updated_at" attributes.

{
    "description": "The default location to place discovered hosts in",
    "category": "Setting::Discovered",
    "settings_type": "string",
    "default": "",
    "created_at": "2021-01-19 17:37:39 UTC",
    "updated_at": "2021-01-19 17:37:39 UTC",
    "id": "discovery_location",
    "name": "discovery_location",
    "full_name": "Discovery location",
    "value": "",
    "category_name": "Discovered",
    "readonly": false,
    "config_file": "settings.yaml",
    "encrypted": false,
    "select_values": {
        "Default Location": "Default Location"
    }
}

2: Checked other APIs fix_db_cache and they are also working.

{
    "description": "Fix DB cache on next Foreman restart",
    "category": "Setting::General",
    "settings_type": "boolean",
    "default": false,
    "created_at": "2021-01-19 17:37:03 UTC",
    "updated_at": "2021-01-19 17:37:40 UTC",
    "id": "fix_db_cache",
    "name": "fix_db_cache",
    "full_name": "Fix DB cache",
    "value": false,
    "category_name": "General",
    "readonly": false,
    "config_file": "settings.yaml",
    "encrypted": false,
    "select_values": null
}

3: Check the fixed package

# rpm -qa|grep "foreman-2.3.1"
foreman-2.3.1.2-1.el7sat.noarch

Comment 9 errata-xmlrpc 2021-04-21 13:18:56 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: Satellite 6.9 Release), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:1313


Note You need to log in before you can comment on or make changes to this bug.