Bug 1309639
Summary: | [RFE] reporting needs to improve handling of displayed values, including failures | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Zdenek Kabelac <zkabelac> |
Component: | lvm2 | Assignee: | Peter Rajnoha <prajnoha> |
Status: | NEW --- | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | rawhide | CC: | agk, bmarzins, bmr, dwysocha, heinzm, jonathan, lvm-team, msnitzer, prajnoha, zkabelac |
Target Milestone: | --- | Keywords: | FutureFeature |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Enhancement | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 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
Zdenek Kabelac
2016-02-18 11:12:22 UTC
This is about reporting failures along the way we do reporting itself (it's a bit related to our plans for reporting errors/warnings while processing and make this to go through the reporting engine too). It's true indeed that we need to check error code from the reporting command when it's finished but this one only returns the overall code for the whole command run and so we need to parse stderr to check in which part the reporting failed exactly (e.g. failed lv_info for certain LV segments and similar). This is not about binary fields, it's about making the failure in reporting to be visible for each field we report - so maybe a global value (above all the report types!) to represent FAILURE could help here (in that case the reporting engine itself could report "FAIL" in place of the field where the *_disp function failed so we don't need to change all the existing *_disp function to handle this). Currently, all the *_disp functions that reporting code calls for each field to report itself only return 0 for success or 1 for failure. We could enhance this to return more error codes which the reporting code could recognize and report a special value like "FAILED" or more variants of it for the failed field if needed. So whatever we do here to make it easier to recognize failed states, it must be done globally, it's not bound to certain field type like the "binary" one! For example, the memory allocation can fail when we dup string field and various other sources of failures... |