sling-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andreas Schaefer (Jira)" <j...@apache.org>
Subject [jira] [Assigned] (SLING-8483) Sling Feature Launcher with Content Package depends on Classpath Order and Needs Package Init Bundle
Date Tue, 20 Aug 2019 20:49:00 GMT

     [ https://issues.apache.org/jira/browse/SLING-8483?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Andreas Schaefer reassigned SLING-8483:
---------------------------------------

    Assignee: Andreas Schaefer

> Sling Feature Launcher with Content Package depends on Classpath Order and Needs Package
Init Bundle
> ----------------------------------------------------------------------------------------------------
>
>                 Key: SLING-8483
>                 URL: https://issues.apache.org/jira/browse/SLING-8483
>             Project: Sling
>          Issue Type: Bug
>          Components: Feature Model
>    Affects Versions: Feature Model Launcher 1.0.2
>         Environment: Java 8, Sling 11, Feature Model 1.0.2
>            Reporter: Andreas Schaefer
>            Assignee: Andreas Schaefer
>            Priority: Major
>             Fix For: Feature Model Launcher 1.1.2
>
>
> There are two issues with the Feature Launcher to support Package Content installation:
>  # The feature extension content needs to be added before the launcher in the class path
>  # For the Content Package deployment to work JCR Package Init needs to be installed
> In the Feature Processor the Content Package Handler from the launcher is called first
if the launcher is ahead of the content extension in the class path:
>  
> {code:java}
> extensions: for(final Extension ext : app.getExtensions()) {
>  for (ExtensionHandler handler : ServiceLoader.load(ExtensionHandler.class, FeatureProcessor.class.getClassLoader()))
>  {
>  if (handler.handle(new ExtensionContextImpl(ctx, config.getInstallation(), loadedFeatures),
ext)) {
>  continue extensions;
> {code}
> Because this handle() method returns true the content extension's Content Handler is
never invoked and hence there is no Execution Plan making the Content Package fail later.
> I think the Extension Handler should issue a priority to select the appropriate one at
runtime.
> The Content Package deployment will not work anyhow if the JCR Package Init bundle is
not installed prior to deployment. I would suggest that the Launcher should deploy that bundle
as it does deploy the Sling Launcher as well. 



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Mime
View raw message