Summary: | [api] Redesign message retrieval for different service | ||
---|---|---|---|
Product: | [Tools] Target Management | Reporter: | Xuan Chen <xuanchen> |
Component: | RSE | Assignee: | David McKnight <dmcknigh> |
Status: | RESOLVED FIXED | QA Contact: | Martin Oberhuber <mober.at+eclipse> |
Severity: | enhancement | ||
Priority: | P3 | CC: | ddykstal.eclipse, wbprio |
Version: | 3.0 | Keywords: | api |
Target Milestone: | 3.0 M6 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: | |||
Bug Depends on: | 216252 | ||
Bug Blocks: |
Description
Xuan Chen
2007-11-27 10:12:02 EST
As per http://wiki.eclipse.org/DSDP/TM/Committer_Phone_Meeting_27-Nov-2007 : DaveD: SystemMessages are heavily used in IBM products, they rely on having message ID's. There are two problems: (a) the whole interface, and (b) the format in which messages are stored. What does SystemMessage have, that could not be mapped to an IStatus object? --> The Level 2 Text. But the namespace spanned by IStatus is more general, (plugin id + severity + status code); SystemMessage codes need to be "administered" to ensure uniqueness Could we define an "RSEStatus" object that has all the properties we need from SystemMessage but still conforms to IStatus? i.e. extend IStatus interface to add the levelTwoText? - DaveD: There must be an associated Property, or code, with the IStatus (to do something useful, in case the message is not being translated). That code could perhaps be the plugin-id / code tuple but not sure about that. It looks like for 3.0 we'll have to stick with SystemMessages? Do we want to look at this for 3.0 or mark it as "Future"? This bug is related to UI/Non-UI splitting (bug 190231) because in a plain headless environment, no SystemMessageProvider would be injected into the core services, leading to NPE's as we have seen before. I'd thus like to target this issue 3.0 M6 since I really want headless RSE to work with that milestone. Here are the possible solutions: a) Change Services to use Eclipse NLS Strings instead of Message IDs Potentially also creating a kind of IStatus handling for Services b) Create a second, headless SystemMessageProvider and split up SystemMessages.xml into a UI and a non-UI part. The XML Dependency would still bring in quite a bit of extra load on a headless RSE. Assigning Xuan to drive the discussion. I think this has been addressed via Bug 216252. The strings used for messages are divided among services in .properties files. The messages (if required) can be constructed directly via SimpleSystemMessage in the services. Is there anything we're missing now? With the latest changes as per bug 216252 comment 23, this will indeed be fixed. But references to ISystemMessageProvider need to be removed from the service implementations completely, and constructors need to be updated accordingly. ISystemMessageProvider is no longer, due to fixes in 216252, so I'm marking this one as fixed. |