Bug 1879587
Summary: | simultaneous POST requests to some endpoints result in Different response payload format | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Roman Plevka <rplevka> |
Component: | API | Assignee: | Eric Helms <ehelms> |
Status: | CLOSED ERRATA | QA Contact: | Lukáš Hellebrandt <lhellebr> |
Severity: | high | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.8.0 | CC: | apatel, gtalreja, lzap, pcreech, rabajaj, tbrisker |
Target Milestone: | 6.9.0 | Keywords: | Triaged |
Target Release: | Unused | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | foreman-2.3.0-1 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2021-04-21 13:17:46 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
Roman Plevka
2020-09-16 14:58:06 UTC
I was able to reproduce this on some different endpoints. Looks like this is not related to Discovery component but rather API. /api/v2/roles/clone /api/v2/discovered_hosts/facts /api/v2/discovery_rules/ It's insteresting that this is not reproducible on /api/v2/roles endpoint but it is on /api/v2/roles/clone. Copying my comment from discourse: That’s quite odd, the response content should be generated by the foreman application, regardless of which webserver it is running under. However, I did find one thing in common for all three endpoints identified: They don’t have matching view templates. I wounder if copying e.g. <$discovery_plugin>/app/views/api/v2/discovery_rules/show.json.rabl to <$discovery_plugin>/app/views/api/v2/discovery_rules/create.json.rabl would lead to any difference? Connecting redmine issue https://projects.theforeman.org/issues/30946 from this bug Verified with Sat 6.9 snap 12. Used reproducer from OP in 6 simultaneous processes, each of them doing 1000 calls. All of the responses were formed like this: {"name":"2392011492","enabled":true,"hostgroup_id":1,"hostgroup_name":"testgrp","hostname":"myhost-<%= rand(99999) %>","priority":26362,"search":"memory > 500","hosts_limit":0,"id":5794,"hosts":[],"organizations":[{"id":1,"name":"Default Organization","title":"Default Organization","description":null}],"locations":[{"id":2,"name":"Default Location","title":"Default Location","description":null}]} None of them had top-level entity key. 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 |