| Summary: | [api] unified error handling | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Steffen Pingel <steffen.pingel> | ||||||||||
| Component: | Mylyn | Assignee: | Steffen Pingel <steffen.pingel> | ||||||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||||||
| Severity: | enhancement | ||||||||||||
| Priority: | P3 | CC: | robert.elves, wmitsuda | ||||||||||
| Version: | dev | ||||||||||||
| Target Milestone: | 2.0 M3 | ||||||||||||
| Hardware: | PC | ||||||||||||
| OS: | All | ||||||||||||
| Whiteboard: | |||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Steffen Pingel
Created attachment 56935 [details]
Error handling related fixes
Created attachment 56936 [details]
mylar/context/zip
I think it makes sense to log all errors that have status.getCode() == IMylarStatusConstants.INTERNAL_ERROR to the error log so users can easily submit them as bug reports. We should probably also use the failure dialog for those. > Error handling related fixes
Applied.
Reminder: Look at error reporting of failed Trac searches. (In reply to comment #3) > I think it makes sense to log all errors that have status.getCode() == > IMylarStatusConstants.INTERNAL_ERROR to the error log so users can easily submit > them as bug reports. We should probably also use the failure dialog for those. The Mylar error dialog will now be displayed for INTERNAL_ERROR. I updated the bug report submission url and now indicate that Report as Bug can be used as well. Created attachment 66042 [details]
makes status API more robust
The patch introduces RepositoryStatus that takes a mandatory URL which points to the repository the status is related to. Factory methods are provided to create status objects with default error messages for common errors (such as failed logins).
The patch moves the current Status implementation to the Bugzilla plug-in to avoid breakage. Rob, I think factory methods are a good way to communicate the required parameters to construct a meaningful status object for specific errors. I leave it to you to refactor the Bugzilla code.
Handling of HTML messages is stil work in progress. Let's discuss that on the next conference call.
Created attachment 66043 [details]
mylar/context/zip
Rob: please review. Patch applied. Fixed failing test cases. Resolving. As part of the renaming (bug 191406) MylarStatus was merged with RepositoryStatus. RepositoryStatus.getRepositoryUrl() can now return null if the status does not relate to a repository. |