For my own examples I normally offer a README.txt with the commands to
install the example.
Like this one:
https://github.com/cschneider/Karaf-Tutorial/blob/master/camel/jms2rest/ReadMe.txt
Of course it is more than one command for a complex example but you can
simply copy/paste the whole commands in one step into karaf and it works.
The only thing needed before is to either call mvn install on the
example or deploy it into maven central which is the case with the camel
examples.
So I think we can simply create such readme files and it should work.
Christian
Am 18.01.2013 12:31, schrieb Claus Ibsen:
Hi
So when people get started with Apache Karaf and Camel (eg not going
down the full ESB with SMX) then I would like to make that much
easier.
For example to tell them how easy you can install some of the examples
we provided with Apache Camel
http://camel.apache.org/examples
Many of these examples have been prepared for OSGi and have embedded
features.xml file, so in theory they are ready to install.
Though I could not find a way to install the example in Karaf without pain.
eg I want to do
cd apache-karaf-2.3.0
bin/karaf
features:choose camel 2.11.0
// and how to install my example, such as camel-example-sql
?????
The camel features does not contain examples.
And frankly I would like Karaf to be able to install a bundle but use
the features.xml file that is included in the JAR in the root
classpath. (Or some other directory if Karaf has a standard for that).
Maybe I can type, eg notice the :feature in the command
osgi:install mvn:feature:org.apache/camel/camel-example-sql/2.11.0
Or some other way to install it.
Then people just need to download Karaf, and they can install Camel
and the examples from Maven.
Now I want them to be able to do this for their custom application as
well, so they can do
osgi:install file:feature:/dev/myproject/target/myapp-1.0.jar
Or something like that.
So how can we make it easier for people to install and try Camel
examples in vanilla Apache Karaf containers?
And how can we make it easier for people to install their own
applications in vanilla Apache Karaf containers,
which uses features.xml file to declare their dependencies.
And NO they do NOT want to use KAR files or some Karaf specific. Their
applications should be plain JARs
that can also run outside Karaf as well.
--
Christian Schneider
http://www.liquid-reality.de
Open Source Architect
Talend Application Integration Division http://www.talend.com