| Summary: | [log] equinox log should be substitutable | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] Equinox | Reporter: | Thomas Watson <tjwatson> | ||||
| Component: | Compendium | Assignee: | Thomas Watson <tjwatson> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P3 | CC: | remy.suen, simon_kaegi | ||||
| Version: | 3.7 | Flags: | simon_kaegi:
review+
|
||||
| Target Milestone: | 3.7 M5 | ||||||
| Hardware: | PC | ||||||
| OS: | Mac OS X - Carbon (unsup.) | ||||||
| Whiteboard: | |||||||
| Bug Depends on: | |||||||
| Bug Blocks: | 292135 | ||||||
| Attachments: |
|
||||||
|
Description
Thomas Watson
Created attachment 183009 [details]
patch
This patch changes org.eclipse.equinox.log to allow a substitutable org.eclipse.equinox.log export. This allows for only one copy of the package to be available when the framework also exports the package. This patch also tightens up the import ranges of the other packages.
This patch also modifies the activator to not register the log services if the ExtendedLogService is already registered by the system bundle.
Finally I updated the log.tests to use Import-Package instead of requiring org.eclipse.equinox.log. I also removed the code that was using internals to set the error stream. Not sure why that was needed. As far as I can tell it was to avoid messages being written to standard error, but I don't think that is required.
Is this the same logger that's used when some EventHandler listening for stuff from EventAdmin throws an exception? Yes, the eventAdmin implementation uses the LogService to log any errors. My thoughts are that we would encourage bundles to use the LogService to log all their errors so that we have a common logging API for all our clients. For our old logging APIs we will have to map them onto the (Extended)LogService. Simon, can you review this patch also. If the patch in bug292135 is to be released I also want to release this patch. +1 Looks fine. Patch released. |