This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 5d858e237618 CAMEL-23169: camel-jbang - Export to standalone should
package fat-jar using camel-repacker-plugin which we use in camel-launcher and
spring boot as well.
5d858e237618 is described below
commit 5d858e23761814dfe9d3db977338910293543a71
Author: Claus Ibsen <[email protected]>
AuthorDate: Wed Mar 11 12:49:07 2026 +0100
CAMEL-23169: camel-jbang - Export to standalone should package fat-jar
using camel-repacker-plugin which we use in camel-launcher and spring boot as
well.
---
.../dsl/jbang/core/commands/ExportCamelMain.java | 3 --
.../src/main/resources/assembly/runner.xml | 34 ----------------------
.../resources/templates/main-kubernetes-pom.tmpl | 27 +++++------------
3 files changed, 8 insertions(+), 56 deletions(-)
diff --git
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/ExportCamelMain.java
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/ExportCamelMain.java
index 0d9fe58cc3ec..9a0a3a3f3ef3 100644
---
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/ExportCamelMain.java
+++
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/ExportCamelMain.java
@@ -414,9 +414,6 @@ class ExportCamelMain extends Export {
ExportHelper.safeCopy(is,
srcResourcesDir.resolve("log4j2.properties"));
is =
ExportCamelMain.class.getResourceAsStream("/log4j2.component.properties");
ExportHelper.safeCopy(is,
srcResourcesDir.resolve("log4j2.component.properties"));
- // assembly for runner jar
- is = ExportCamelMain.class.getResourceAsStream("/assembly/runner.xml");
- ExportHelper.safeCopy(is,
srcResourcesDir.resolve("assembly/runner.xml"));
}
protected void copyGroovyPrecompiled(Path srcResourcesDir) throws
Exception {
diff --git
a/dsl/camel-jbang/camel-jbang-core/src/main/resources/assembly/runner.xml
b/dsl/camel-jbang/camel-jbang-core/src/main/resources/assembly/runner.xml
deleted file mode 100644
index 9aba8dd0baf4..000000000000
--- a/dsl/camel-jbang/camel-jbang-core/src/main/resources/assembly/runner.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
--->
-<assembly>
- <id>runner</id>
- <formats>
- <format>jar</format>
- </formats>
- <includeBaseDirectory>false</includeBaseDirectory>
- <dependencySets>
- <dependencySet>
- <outputDirectory>/</outputDirectory>
- <useProjectArtifact>true</useProjectArtifact>
- <unpack>true</unpack>
- <scope>runtime</scope>
- </dependencySet>
- </dependencySets>
-</assembly>
\ No newline at end of file
diff --git
a/dsl/camel-jbang/camel-jbang-core/src/main/resources/templates/main-kubernetes-pom.tmpl
b/dsl/camel-jbang/camel-jbang-core/src/main/resources/templates/main-kubernetes-pom.tmpl
index 9e2925440e95..04b2e9607e4c 100644
---
a/dsl/camel-jbang/camel-jbang-core/src/main/resources/templates/main-kubernetes-pom.tmpl
+++
b/dsl/camel-jbang/camel-jbang-core/src/main/resources/templates/main-kubernetes-pom.tmpl
@@ -93,30 +93,19 @@
</plugin>
<!-- package as runner jar -->
<plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <version>3.7.1</version>
- <configuration>
- <descriptors>
-
<descriptor>src/main/resources/assembly/runner.xml</descriptor>
- </descriptors>
- <archive>
- <manifest>
- <mainClass>{{ .MainClassname }}</mainClass>
- </manifest>
- <manifestEntries>
- <Multi-Release>true</Multi-Release>
- </manifestEntries>
- </archive>
- <appendAssemblyId>false</appendAssemblyId>
- </configuration>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-repackager-maven-plugin</artifactId>
+ <version>{{ .CamelVersion }}</version>
<executions>
<execution>
- <id>make-assembly</id>
+ <id>repackage-executable</id>
<phase>package</phase>
<goals>
- <goal>single</goal>
+ <goal>repackage</goal>
</goals>
+ <configuration>
+ <mainClass>{{ .MainClassname }}</mainClass>
+ </configuration>
</execution>
</executions>
</plugin>