[
https://issues.apache.org/jira/browse/SLING-6392?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15882823#comment-15882823
]
Karl Pauls commented on SLING-6392:
-----------------------------------
Great. I committed [^ SLING-6392-after-transform.patch] in r1784280 so that we
don't have to work via patches all the time (i.e., I'm not against adding some
form of log message).
Regarding the log message I would think it should be an INFO at a maximum but
I'd rather say it should be a DEBUG because the removal (if any) will still be
logged already (as a normal uninstall) so it really is only of interested in a
debugging scenario to figure out why it was removed.
That said, I'm not sure how to best figure out when to log because the remove
method doesn't report a remove. Maybe you have a better idea but if not, I
would probably add a protected remove method to EntityResourceList (to which
the public void remove(String url) method delegates) which returns true if
something was removed. Subsequently, in the transform, I would do a
logger.debug for every group.remove that returns true.
WDYT?
> OSGi Installer: Symbolic name changes on a resource keeping the same URL are
> not supported
> ------------------------------------------------------------------------------------------
>
> Key: SLING-6392
> URL: https://issues.apache.org/jira/browse/SLING-6392
> Project: Sling
> Issue Type: Bug
> Components: Installer
> Affects Versions: Installer Core 3.8.0
> Reporter: Konrad Windszus
> Assignee: Karl Pauls
> Fix For: Installer Core 3.8.8
>
> Attachments: SLING-6392-after-transform.patch,
> SLING-6392-Fragment.patch, SLING-6392-Fragment-v02.patch,
> SLING-6392-test-v01.patch, SLING-6392-test-v02.patch, SLING-6392-v01.patch,
> SLING-6392-v02.patch
>
>
> After deploying bundle with symbolic name {{A}} to JCR location
> {{/apps/myapp/install/mybundle.jar}} or somewhere in the filesystem it is
> correctly being picked up by the JcrInstaller or FileInstaller and deployed
> in Apache Felix. Now the symbolic name has been changed to {{B}} and the
> updated JAR has been deployed to the same location in the JCR
> {{/apps/myapp/install/mybundle.jar}} or to the file system the updated bundle
> is not correctly deployed.
> The OSGI installer console exposes that both bundles {{A}} and {{B}} are in
> state {{Installed}} but the /system/console/bundle only shows bundle {{A}}
> but not {{B}}.
> It would actually be expected that {{A}} is uninstalled, while {{B}} is
> getting installed!
> Such a change can happen if you use the {{maven-bundle-plugin}} with a
> default configuration and you just change the groupId of the underlying maven
> project. That will not affect the finalName of the artifact (by default
> artifactId) but the symbolic name of the bundle (see
> http://felix.apache.org/documentation/subprojects/apache-felix-maven-bundle-plugin-bnd.html#default-behavior).
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)