[ https://issues.apache.org/jira/browse/KARAF-4824?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15724810#comment-15724810 ]
Guillaume Nodet commented on KARAF-4824: ---------------------------------------- If you have the bundle id, you can easily do the following: {code} do-update = { bnd = (($.context getService ($.context getServiceReference org.apache.karaf.bundle.core.BundleService)) getBundle $1) $bnd update ((new java.net.URL $2) openStream) } {code} Then call the function: {code} do-update org.apache.sshd.core mvn:org.apache.sshd/sshd-core/1.2.0 {code} That said, I agree we could provide an option to the {{bundle:update}} command. > Add Option to bundle:update which doesn't rewrite MANIFEST file > --------------------------------------------------------------- > > Key: KARAF-4824 > URL: https://issues.apache.org/jira/browse/KARAF-4824 > Project: Karaf > Issue Type: New Feature > Components: karaf-shell > Affects Versions: 4.0.7 > Reporter: Markus Eckert > Labels: bundle, shell, update > Fix For: 4.1.0 > > > Using the Karaf shell, if someone updates a bundle using the *bundle:update* > command, the command unzips the .jar file and manipulates the MANIFEST > without questioning it. > *BundleUtils.fixBundleWithUpdateLocation* is responsible for this. > This is a severe issue when using JAR files with signature (JRE jarsigner) > and signature checking. If a bundle is only allowed to start with a valid > signature this will break it and the bundle won't activate again. > Update of the bundles was done using: > *update <bundle name> file:/<location on file system>* > The only workaround is to uninstall the bundle and install it again. > An option to tell update if it should update the MANIFEST or not would be a > nice feature to have. > Maybe there is another CLI command to achieve this? Updating the bundle using > the Karaf Webconsole doesn't have this issue at all. -- This message was sent by Atlassian JIRA (v6.3.4#6332)