Skip to content

Commit 07e913e

Browse files
committed
CAMEL-22243: camel-launcher docs
1 parent 4aab786 commit 07e913e

File tree

3 files changed

+72
-2
lines changed

3 files changed

+72
-2
lines changed

docs/user-manual/modules/ROOT/nav.adoc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66
** xref:building.adoc[Building]
77
** xref:camel-console.adoc[Camel Developer Console]
88
** xref:camel-jbang.adoc[Camel JBang]
9-
*** xref:camel-jbang-kubernetes.adoc[Camel Kubernetes plugin]
10-
*** xref:camel-jbang-test.adoc[Camel Testing plugin]
9+
*** xref:camel-jbang-launcher.adoc[Camel JBang Launcher]
10+
*** xref:camel-jbang-kubernetes.adoc[Camel JBang Kubernetes plugin]
11+
*** xref:camel-jbang-test.adoc[Camel JBang Testing plugin]
1112
** xref:camel-maven-plugin.adoc[Camel Maven Plugin]
1213
** xref:camel-component-maven-plugin.adoc[Camel Component Maven Plugin]
1314
** xref:camel-report-maven-plugin.adoc[Camel Maven Report Plugin]
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
= Camel JBang Launcher
2+
3+
*Available as of Camel 4.13*
4+
5+
This module provides a self-contained executable JAR that includes all dependencies required to run Camel JBang without the need for the JBang two-step process.
6+
7+
The launcher uses Spring Boot's loader tools to create a self-executing JAR with a nested structure, similar to Spring Boot's executable JARs. This provides better performance and avoids classpath conflicts compared to traditional fat JARs.
8+
9+
== Downloading
10+
11+
You can download the `camel-launcher` JAR from https://repo1.maven.org/maven2/org/apache/camel/camel-launcher/[Maven Central].
12+
13+
== Using the fat-jar directly
14+
15+
Then you can run the JAR using standard Java as follows:
16+
17+
[source,bash]
18+
----
19+
java -jar camel-launcher-<version>.jar [command] [options]
20+
----
21+
22+
For example:
23+
24+
[source,bash]
25+
----
26+
java -jar camel-launcher-<version>.jar version
27+
java -jar camel-launcher-<version>.jar run hello.java
28+
----
29+
30+
== Using the distribution (recommended)
31+
32+
Extract the distribution archive:
33+
34+
[source,bash]
35+
----
36+
unzip camel-launcher-<version>-bin.zip
37+
# or
38+
tar -xzf camel-launcher-<version>-bin.tar.gz
39+
----
40+
41+
And then use the provided scripts:
42+
43+
[source,bash]
44+
----
45+
# On Unix/Linux
46+
./bin/camel.sh [command] [options]
47+
48+
# On Windows
49+
bin\camel.bat [command] [options]
50+
----
51+
52+
== Benefits of using Camel Launcher
53+
54+
- No need for JBang installation
55+
- Single executable JAR with all dependencies included
56+
- Faster startup time (no dependency resolution step, on-demand class loading)
57+
- Better memory usage (only loads classes that are actually used)
58+
- Avoids classpath conflicts (dependencies kept as separate JARs)
59+
- Each self-executing JAR is its own release, avoiding version complexity
60+
- Can still be used with JBang if preferred
61+
62+
== More Information
63+
64+
See the general xref:camel-jbang.adoc[Camel JBang] documentation.

docs/user-manual/modules/ROOT/pages/camel-jbang.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ Note: It requires access to the internet, in case of using a proxy, please ensur
3030
If Camel JBang is not working with your current configuration,
3131
please look to https://www.jbang.dev/documentation/jbang/latest/configuration.html#proxy-configuration[Proxy configuration in JBang documentation].
3232

33+
=== Installing without JBang
34+
35+
It is also possible to install and run Camel JBang without _JBang_ using the xref:camel-jbang-launcher.adoc[Camel JBang Launcher] which essentially is
36+
a standard Java _fat-jar_ with launch scripts.
37+
3338
=== Installing a specific Camel JBang version
3439

3540
By default, Camel JBang installs the latest release, which may not be the desired version.

0 commit comments

Comments
 (0)