| Summary: | Enhance SupportManager.getSnapshotReport() to provide more flexibility. | ||
|---|---|---|---|
| Product: | [Other] RHQ Project | Reporter: | Steven North <swn> |
| Component: | Core Server | Assignee: | Nobody <nobody> |
| Status: | NEW --- | QA Contact: | |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 4.0.0 | CC: | hrupp |
| 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: | --- | |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
Description of problem: The current snapshot operation, SupportManager.getSnapshotReport(), does not provide a caller-specified timeout value and uses a default value of 10 minutes. The caller should be able to override the default to provide a timeout more sutiable to the situation (smaller/larger). Additionally, it would be useful to be able to pass parameters (as Configuration) with the request, similar to the OperationManager.scheduleResourceOperation(). The comments below suggest wrapping all the parameters to the getSnapshotReport() into a single SnapshotReportRequest. The other way to go is to mimic scheduleResoureOperation(), adding the parameters that make sense, timeout and parameters. In either case I think you have to add a new method to preserve backwards compatibility. << Comments from discussion >> There is not, no. That snapshot feature is not really to be considered fully built out with all the bells and whistles (this is why there is no easy UI interfacing to it). There is probably lots more we can do here to fill out that feature - this customizable timeout is one such feature. Can you write up a bugzilla on this. For the record, the code gives your plugin 10 minutes to complete the building of the snapshot report. See the plugin container class called org.rhq.core.pc.support.SupportManager: public InputStream getSnapshotReport(int resourceId, String name, String description) throws Exception { SupportFacet facet = getSupportFacet(resourceId, 600000L); // give it enough time to zip up all the snapshot content What we will probably do here is change that method API, collapse those parameters into a single parameter "SnapshotReportRequest" (to mimic the plugin API). We could then add a timeout to the request and pass it to the second parameter you see there to getSupportFacet. << End comments >> Version-Release number of selected component (if applicable): RHQ 4.0.0