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

Christian Schneider resolved SLING-8591.
----------------------------------------
    Resolution: Won't Fix

The hook turned out to be a bad idea after all. I am removing the code again. 
Instead of a hook the extract mechanism is implemented in distribution journal. 
This way it is much simpler and does not introduce a new API for this single 
case.

> Hook to support custom code when installing or deleting distribution packages
> -----------------------------------------------------------------------------
>
>                 Key: SLING-8591
>                 URL: https://issues.apache.org/jira/browse/SLING-8591
>             Project: Sling
>          Issue Type: Improvement
>          Components: Content Distribution
>            Reporter: Christian Schneider
>            Assignee: Christian Schneider
>            Priority: Major
>             Fix For: Content Distribution Core 0.4.2
>
>          Time Spent: 1h 20m
>  Remaining Estimate: 0h
>
> The concrete case for this is that some customers would like to automatically 
> install content packages that are deployed during a content distribution.
> I would like to avoid putting the content package installation code directly 
> into the content distribution core bundle. So the idea is to define a hook 
> that can be implemented to support custom code after installation of a 
> distribution package and before deletion of such a package.
> The hook could look like this:
> {code:java}
> public interface PackageInstallHook {
>     void onPostAdd(ResourceResolver resourceResolver, DistributionPackage 
> distPackage);
>     void onPreRemove(ResourceResolver resourceResolver, DistributionPackage 
> distPackage);
> }
> {code}
> The implementation of the hook can be offered as a service. A default noop 
> service is created by default. The referenced service can be overridden by 
> specifiying a installHook.target on the DistributionPackageBuilderFactory 
> config.



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

Reply via email to