[
https://issues.apache.org/jira/browse/SLING-2174?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Felix Meschberger closed SLING-2174.
------------------------------------
Close after release.
> Leverage Framework interface to better control framework startup
> ----------------------------------------------------------------
>
> Key: SLING-2174
> URL: https://issues.apache.org/jira/browse/SLING-2174
> Project: Sling
> Issue Type: Improvement
> Components: Launchpad
> Affects Versions: Launchpad Base 2.3.0
> Reporter: Felix Meschberger
> Assignee: Carsten Ziegeler
> Fix For: Launchpad Base 2.4.0
>
> Attachments: SLING-2174.patch
>
>
> During startup the bootstrap installer may install, update or uninstall
> system extension fragments which require the framework to be restarted for
> the action to properly complete.
> The current implementation solves the problem like this:
> - initialize the framework (Framework.init())
> - start the framework into startlevel 1 (Framework.start())
> - call bootstrap installer for install, update, uninstall
> - check whether a restart is required:
> - if yes: restart
> - otherwise: set start level to originally requested start level
> This is clumsy and dilutes the startup. Particularly the FRAMEWORK_STARTED
> event is fired without the framework startup to actually have completed.
> To fix this we can solve this easily using the Framework interface like this:
> Framework tmpFramework = createFramework(notifiable, logger,
> props);
> init(tmpFramework);
> if (new BootstrapInstaller(tmpFramework.getBundleContext(),
> logger, resourceProvider).install()) {
> init(tmpFramework);
> }
> tmpFramework.start();
> this.framework = tmpFramework;
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira