Bug 1747178

Summary: [CFME Insights Integration] Failed Payload Upload to Insights Showing as Success in evm.log
Product: Red Hat CloudForms Management Engine Reporter: juwatts
Component: APIAssignee: Libor Pichler <lpichler>
Status: CLOSED CURRENTRELEASE QA Contact: juwatts
Severity: high Docs Contact: Red Hat CloudForms Documentation <cloudforms-docs>
Priority: high    
Version: 5.11.0CC: dmetzger, obarenbo, smallamp
Target Milestone: GAKeywords: TestOnly, ZStream
Target Release: 5.12.0Flags: mfeifer: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1784533 (view as bug list) Environment:
Last Closed: 2020-10-26 16:25:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: Bug
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1784533    

Description juwatts 2019-08-29 20:05:54 UTC
Description of problem:
When a payload upload to insights, the insights-client binary doesn't return !=0 when it fails which CFME reports as a success

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

How reproducible:
100%

Steps to Reproduce:
1. Register the appliance to RHSM and insights as insights-qa user 
2. Initiate a platform sync
3. Check the evm.log

Actual results:
evm.log shows upload was a success

Expected results:
Upload failed

Additional info:
Adam  Grare:
data uploader is checking for != 0 => failure
looks like it needs to parse stdout/stderr

Comment 2 dmetzger 2019-08-30 13:52:16 UTC
Is this a logging only issue, do we provide the failed status information to the user?

Comment 3 juwatts 2019-08-30 13:55:00 UTC
No, CFME was going the upload as a success:

root@dhcp-8-198-4 log]# tail -f evm.log | grep cloud.redhat.com

[----] I, [2019-08-29T10:07:35.797598 #7959:2ac63e8bba58]  INFO -- : MIQ(MiqTask.generic_action_with_callback) Task: [4] Queued the action: [Collect and upload inventory to cloud.redhat.com] being run for user: [admin]
[----] I, [2019-08-29T10:07:35.851365 #7959:2ac63e8bba58]  INFO -- : MIQ(MiqTask.generic_action_with_callback) Task: [5] Queued the action: [Collect and upload inventory to cloud.redhat.com] being run for user: [admin]
[----] I, [2019-08-29T10:07:38.226550 #7885:2ac63af1c5b8]  INFO -- : MIQ(Cfme::CloudServices::DataUploader.upload) Uploading /tmp/cfme_inventory-20190829-7885-w9yoc4.tar.gz to cloud.redhat.com...
[----] I, [2019-08-29T10:07:41.628897 #7885:2ac63af1c5b8]  INFO -- : MIQ(Cfme::CloudServices::DataUploader.upload) Uploading /tmp/cfme_inventory-20190829-7885-w9yoc4.tar.gz to cloud.redhat.com...Success - 
[----] I, [2019-08-29T11:26:41.949114 #1060:2ae83a8b05b8]  INFO -- : MIQ(Cfme::CloudServices::DataUploader.upload) Uploading /tmp/cfme_inventory-20190829-1060-1cwaq5p.tar.gz to cloud.redhat.com...
[----] I, [2019-08-29T11:26:45.746698 #1060:2ae83a8b05b8]  INFO -- : MIQ(Cfme::CloudServices::DataUploader.upload) Uploading /tmp/cfme_inventory-20190829-1060-1cwaq5p.tar.gz to cloud.redhat.com...Success -