| Summary: | Config Admin does not call updated() in some cases | ||
|---|---|---|---|
| Product: | [ECD] Orion | Reporter: | Mark Macdonald <mamacdon> |
| Component: | Client | Assignee: | Mark Macdonald <mamacdon> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | simon_kaegi |
| Version: | 1.0 | ||
| Target Milestone: | 1.0 M2 | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| Whiteboard: | |||
| Bug Depends on: | 389194 | ||
| Bug Blocks: | |||
|
Description
Mark Macdonald
I think this requires additional support from the PluginRegistry. When a plugin is entering the LOADED state, and the plugin provides a Managed Service, the Config Admin has to (asynchronously) obtain the configuration data, and queue up a call to deliver it via managedService.updated(). Right now this does not work because the Plugin loads, and allows other service methods to be called, before Config Admin has finished loading the configuration. This could be done by having PluginRegistry check for a Deferred returned by dispatchEvent(), and wait for it to call back before the Plugin's _deferredLoad resolves. (In reply to comment #1) > I think this requires additional support from the PluginRegistry. When a > plugin is entering the LOADED state, and the plugin provides a Managed > Service, the Config Admin has to (asynchronously) obtain the configuration > data, and queue up a call to deliver it via managedService.updated(). > > This could be done by having PluginRegistry check for a Deferred returned by > dispatchEvent(), and wait for it to call back before the Plugin's > _deferredLoad resolves. The dispatchEvent-Deferred support is no longer present (see bug 385657, bug 389194). As part of the work done in 389194, obtaining configuration data for a PID is no longer an async operation, so the call to managedService.updated() can be queued right away. This fixes the problem 1. http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=c118603aeb77ebcfb7904c2e69f52d1f50ea8a50 (main part) 2. http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=78d8b71ebb69343b9b21ecf03c1c93086ae39a8e (minor omission) |