felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mansour Al Akeel <mansour.alak...@gmail.com>
Subject Exploded bundle auto update
Date Sun, 02 Jun 2013 04:59:33 GMT
Hello all,

I was looking for a way to update the bundles in an exploded directory. The
documentation for FileInstall:

File Install is a directory based OSGi management agent. It uses a
directory in the file system to install and start a bundle when it is first
placed there. It updates the bundle when you update the bundle file in the
directory and, when the file is deleted, it will stop and uninstall the


What I couldn't understand is:
1- how do we specify the path to the directory to monitor. For example do
we give the path of the directory containing jars, or the exploded bundle.

Here's the relevant part of my configuration felix/conf/config.properties:





felix.fileinstall.poll=1000 ms


I tried to point to the directory containing the exploded bundle and the
directory containing the resulting jar. So under maven project
these are  example/target/classes  and example/target, but no luck. I tried
to rebuild the project after some modification with:

 example $ mvn clean install org.apache.felix:maven-bundle-plugin:bundle

but nothing was picked by felix. I am not sure if I am missing something. I
under stand that other tools like bndtools can help, but I don't want to
use eclipse for this.

in the gogo shell:

g! lb
   ID|State      |Level|Name
    0|Active     |    0|System Bundle (4.2.1)
    1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
    2|Active     |    1|Apache Felix Gogo Command (0.12.0)
    3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
    4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
    5|Active     |    1|osgi.cmpn (
   13|Active     |    1|Apache Felix Configuration Admin Service (1.6.0)
   26|Active     |    1|example OSGi Bundle (1.0.0.SNAPSHOT)

I don't know if theres is other bundles I need to install to get this to

Basically, the work flow I am trying to get to is, modify code, invoke
maven build, view the new code in felix, or what otheres may call it hot
swap. Now I can invoke:

g! update 26
de-activated the bundle class com.example.Activator
DEBUG: WIRE: [26.1] osgi.wiring.package;
-> [0]
activated the bundle class com.example.Activator

To get the updated version, but I need a way to avoid doing this.

Is this possible without using any additional ide plugins ?

Is there anything I am missing, or misunderstood ?

Thank you.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message