0

In my features.xml file I modified a custom bundle to use a Pax URL Wrap in order to dynamically Import dependencies. I changed the below line:

<bundle start-level='78'>mvn:abc.def/aid/1.1</bundle>

to

<bundle start-level='78'>wrap:mvn:abc.def/aid/1.1\$DynamicImport-Package=*&amp;overwrite=merge;</bundle>

I was able to confirm this worked by running the following commands from karaf prompt:

karaf@root> uninstall <aid id>
karaf@root> install -s wrap:mvn:abc.def/aid/1.1\$DynamicImport-Package=*&overwrite=merge;

Doing that worked but defeated the purpose of modifying my features.xml file. Is there a way to update my currently installed aid bundle without having to restart it?

Things I tried include

  1. restarting karaf

karaf@root> features:refreshurl

karaf@root> osgi:update

karaf@root> osgi:restart

greenTea
  • 5
  • 2
  • Depending in the Karaf version used, you may also have access to `features:refresh` command, which re-reads all the feature files AND etc/org.apache.karaf.features.xml overrides. – Grzegorz Grzybek Jun 27 '22 at 11:34

1 Answers1

0

It has been a while ... but you might try:

features:refreshurl
features:install yourfeature

The new features:install you

Christian Schneider
  • 19,420
  • 2
  • 39
  • 64