N1k145 commented on PR #1429:
URL: https://github.com/apache/logging-log4j2/pull/1429#issuecomment-1624011979

   > What happens if someone puts `log4j-core` in start level 1 and `log4j-api` 
in start level 2? Will this solution work anyway or the bundles must be in the 
same start level?
   
   In theory you do not need to modify the start levels. 
   You already have the implementation where the `api` searches for the `impl` 
OSGi Service. Which throws an exception in an eclipse environment as described 
in the linked issue.
   Because Equinox, in contrast to Felix, does not activate every bundle by 
default.
   
   With this change Equinox should activate the bundle when it is accessed and 
the exception should no longer be thrown as the bundle context is there and the 
`impl` service should already be registered as it is indexed in the startup. So 
the service can be found using the OSGi Service lookup.
   
   So no need for any manual startlevel or autostart configuration and OSGi 
just has to do it's magic.
   
   But feel free to test it, I only tested it in our quite large setup, maybe 
it behaves differently in other cases.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to