You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ma...@apache.org on 2023/07/14 20:27:08 UTC
[camel-karavan] 02/02: Join code back to app #817
This is an automated email from the ASF dual-hosted git repository.
marat pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-karavan.git
commit 13ade01d51318e66cd4477751e66e80421da1e7f
Author: Marat Gubaidullin <ma...@gmail.com>
AuthorDate: Fri Jul 14 16:26:56 2023 -0400
Join code back to app #817
---
karavan-cloud/karavan-app/pom.xml | 29 +-
.../camel/karavan/api/ConfigurationResource.java | 2 +-
.../camel/karavan/api/InfrastructureResource.java | 2 +-
.../apache/camel/karavan/api/LogWatchResource.java | 2 +-
.../camel/karavan/datagrid/DatagridService.java | 16 +-
.../karavan/datagrid/DevModeCommandListener.java | 0
.../karavan/datagrid/DevModeStatusListener.java | 0
.../camel/karavan/datagrid/model/CamelStatus.java | 0
.../karavan/datagrid/model/CamelStatusName.java | 0
.../camel/karavan/datagrid/model/CommitInfo.java | 0
.../karavan/datagrid/model/ContainerInfo.java | 0
.../karavan/datagrid/model/DeploymentStatus.java | 0
.../karavan/datagrid/model/DevModeCommand.java | 0
.../karavan/datagrid/model/DevModeCommandName.java | 0
.../karavan/datagrid/model/DevModeCommandType.java | 0
.../karavan/datagrid/model/DevModeStatus.java | 0
.../camel/karavan/datagrid/model/Environment.java | 0
.../camel/karavan/datagrid/model/GitConfig.java | 0
.../camel/karavan/datagrid/model/GitRepo.java | 0
.../camel/karavan/datagrid/model/GitRepoFile.java | 0
.../camel/karavan/datagrid/model/GroupedKey.java | 0
.../karavan/datagrid/model/KaravanSchema.java | 0
.../karavan/datagrid/model/PipelineStatus.java | 0
.../camel/karavan/datagrid/model/PodStatus.java | 0
.../camel/karavan/datagrid/model/Project.java | 0
.../camel/karavan/datagrid/model/ProjectFile.java | 3 -
.../karavan/datagrid/model/ServiceStatus.java | 0
.../camel/karavan}/docker/DockerEventListener.java | 5 +-
.../camel/karavan}/docker/DockerService.java | 100 ++++---
.../camel/karavan/docker/InfinispanContainer.java | 48 ++++
.../apache/camel/karavan}/docker/LogCallback.java | 2 +-
.../DeploymentEventHandler.java | 3 +-
.../{service => kubernetes}/KubernetesService.java | 4 +-
.../PipelineRunEventHandler.java | 3 +-
.../{handler => kubernetes}/PodEventHandler.java | 3 +-
.../ServiceEventHandler.java | 3 +-
.../karavan/listener/DevModeCommandListener.java | 2 +-
.../apache/camel/karavan/service/CamelService.java | 1 +
.../apache/camel/karavan/service/CodeService.java | 1 +
.../apache/camel/karavan/service/GitService.java | 1 +
.../camel/karavan/service/KaravanService.java | 41 ++-
.../camel/karavan/service/ProjectService.java | 1 +
.../src/main/resources/application.properties | 21 +-
.../main/resources/cache}/command-cache-config.xml | 0
.../main/resources/cache}/data-cache-config.xml | 0
.../camel/karavan/datagrid/DataGridTest.java | 4 +-
.../src/test/resources/application.properties | 11 +
karavan-cloud/karavan-bashi/.dockerignore | 5 -
karavan-cloud/karavan-bashi/.gitignore | 43 ---
karavan-cloud/karavan-bashi/.java-version | 1 -
.../karavan-bashi/.mvn/wrapper/.gitignore | 1 -
.../.mvn/wrapper/MavenWrapperDownloader.java | 98 -------
.../.mvn/wrapper/maven-wrapper.properties | 18 --
karavan-cloud/karavan-bashi/mvnw | 308 ---------------------
karavan-cloud/karavan-bashi/mvnw.cmd | 205 --------------
karavan-cloud/karavan-bashi/pom.xml | 120 --------
.../karavan-bashi/src/main/docker/Dockerfile.jvm | 95 -------
.../src/main/docker/Dockerfile.legacy-jar | 91 ------
.../src/main/docker/Dockerfile.native | 27 --
.../src/main/docker/Dockerfile.native-micro | 30 --
.../camel/karavan/bashi/ConductorService.java | 168 -----------
.../org/apache/camel/karavan/bashi/Constants.java | 9 -
.../apache/camel/karavan/bashi/KaravanBashi.java | 35 ---
.../apache/camel/karavan/bashi/LoggerService.java | 42 ---
.../src/main/resources/application.properties | 28 --
karavan-cloud/karavan-datagrid/.java-version | 1 -
.../.mvn/wrapper/maven-wrapper.properties | 18 --
karavan-cloud/karavan-datagrid/mvnw | 308 ---------------------
karavan-cloud/karavan-datagrid/mvnw.cmd | 205 --------------
karavan-cloud/karavan-datagrid/pom.xml | 175 ------------
.../camel/karavan/datagrid/model/LogLine.java | 17 --
.../src/main/resources/application.properties | 15 -
.../src/test/resources/application.properties | 14 -
karavan-cloud/pom.xml | 2 -
74 files changed, 208 insertions(+), 2179 deletions(-)
diff --git a/karavan-cloud/karavan-app/pom.xml b/karavan-cloud/karavan-app/pom.xml
index bc3a7a07..620584ec 100644
--- a/karavan-cloud/karavan-app/pom.xml
+++ b/karavan-cloud/karavan-app/pom.xml
@@ -26,11 +26,6 @@
</parent>
<dependencies>
- <dependency>
- <groupId>org.apache.camel.karavan</groupId>
- <artifactId>karavan-datagrid</artifactId>
- <version>${project.version}</version>
- </dependency>
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-smallrye-reactive-messaging</artifactId>
@@ -109,6 +104,22 @@
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>
+ <!-- Infinispan -->
+ <dependency>
+ <groupId>io.quarkus</groupId>
+ <artifactId>quarkus-infinispan-client</artifactId>
+ </dependency>
+ <!-- Docker -->
+ <dependency>
+ <groupId>com.github.docker-java</groupId>
+ <artifactId>docker-java-core</artifactId>
+ <version>${docker-java.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.github.docker-java</groupId>
+ <artifactId>docker-java-transport-httpclient5</artifactId>
+ <version>${docker-java.version}</version>
+ </dependency>
<!-- Code generator -->
<dependency>
<groupId>org.apache.camel</groupId>
@@ -150,6 +161,14 @@
<include>kamelets/**</include>
<include>snippets/**</include>
<include>META-INF/**</include>
+ <include>**/**.xml</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>target/classes/proto</directory>
+ <filtering>true</filtering>
+ <includes>
+ <include>karavan.proto</include>
</includes>
</resource>
</resources>
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/ConfigurationResource.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/ConfigurationResource.java
index 3bd0f2de..795f61be 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/ConfigurationResource.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/ConfigurationResource.java
@@ -17,7 +17,7 @@
package org.apache.camel.karavan.api;
import org.apache.camel.karavan.datagrid.DatagridService;
-import org.apache.camel.karavan.service.KubernetesService;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import javax.inject.Inject;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/InfrastructureResource.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/InfrastructureResource.java
index f525f6a5..8e0032f1 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/InfrastructureResource.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/InfrastructureResource.java
@@ -24,7 +24,7 @@ import org.apache.camel.karavan.datagrid.model.DeploymentStatus;
import org.apache.camel.karavan.datagrid.model.PodStatus;
import org.apache.camel.karavan.datagrid.model.Project;
import org.apache.camel.karavan.datagrid.model.ServiceStatus;
-import org.apache.camel.karavan.service.KubernetesService;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.jboss.logging.Logger;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/LogWatchResource.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/LogWatchResource.java
index 4df1807a..b6d14670 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/LogWatchResource.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/api/LogWatchResource.java
@@ -20,7 +20,7 @@ import io.fabric8.kubernetes.client.dsl.LogWatch;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.DevModeCommand;
import org.apache.camel.karavan.datagrid.model.DevModeCommandName;
-import org.apache.camel.karavan.service.KubernetesService;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.microprofile.context.ManagedExecutor;
import org.jboss.logging.Logger;
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java
similarity index 96%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java
index 5df37b50..eb898981 100644
--- a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DatagridService.java
@@ -21,7 +21,6 @@ import io.smallrye.mutiny.tuples.Tuple2;
import io.vertx.core.eventbus.EventBus;
import io.vertx.core.json.JsonObject;
import org.apache.camel.karavan.datagrid.model.*;
-import org.apache.camel.karavan.datagrid.model.KaravanSchemaImpl;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.infinispan.client.hotrod.RemoteCache;
import org.infinispan.client.hotrod.RemoteCacheManager;
@@ -56,11 +55,11 @@ public class DatagridService {
protected static final String ADDRESS_DEVMODE_COMMAND_INTERNAL = "ADDRESS_DEVMODE_COMMAND_INTERNAL";
protected static final String ADDRESS_DEVMODE_STATUS_INTERNAL = "ADDRESS_DEVMODE_STATUS_INTERNAL";
- @ConfigProperty(name ="quarkus.infinispan-client.hosts")
+ @ConfigProperty(name ="infinispan.hosts")
String infinispanHosts;
- @ConfigProperty(name ="quarkus.infinispan-client.username")
+ @ConfigProperty(name ="infinispan.username")
String infinispanUsername;
- @ConfigProperty(name ="quarkus.infinispan-client.password")
+ @ConfigProperty(name ="infinispan.password")
String infinispanPassword;
private RemoteCache<GroupedKey, Project> projects;
@@ -77,7 +76,7 @@ public class DatagridService {
private RemoteCache<GroupedKey, DevModeCommand> devmodeCommands;
private final AtomicBoolean ready = new AtomicBoolean(false);
- RemoteCacheManager cacheManager;
+ private RemoteCacheManager cacheManager;
@Inject
EventBus eventBus;
@@ -85,11 +84,6 @@ public class DatagridService {
private static final Logger LOGGER = Logger.getLogger(DatagridService.class.getName());
private static final String DEFAULT_ENVIRONMENT = "dev";
- private static final String CACHE_CONFIG = "<distributed-cache name=\"%s\">"
- + " <encoding media-type=\"application/x-protostream\"/>"
- + " <groups enabled=\"true\"/>"
- + "</distributed-cache>";
-
public void start() {
LOGGER.info("DatagridService is starting in remote mode");
@@ -138,7 +132,7 @@ public class DatagridService {
}
private <K, V> RemoteCache<K, V> getOrCreateCache(String name, boolean command) {
- String config = getResourceFile(command ? "/command-cache-config.xml" : "/data-cache-config.xml");
+ String config = getResourceFile(command ? "/cache/command-cache-config.xml" : "/cache/data-cache-config.xml");
return cacheManager.administration().getOrCreateCache(name, new StringConfiguration(String.format(config, name)));
}
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DevModeCommandListener.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DevModeCommandListener.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DevModeCommandListener.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DevModeCommandListener.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DevModeStatusListener.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DevModeStatusListener.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/DevModeStatusListener.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/DevModeStatusListener.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatus.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatusName.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatusName.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatusName.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CamelStatusName.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CommitInfo.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CommitInfo.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/CommitInfo.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/CommitInfo.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ContainerInfo.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ContainerInfo.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ContainerInfo.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ContainerInfo.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DeploymentStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DeploymentStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DeploymentStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DeploymentStatus.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommand.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommand.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommand.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommand.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandName.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandName.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandName.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandName.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandType.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandType.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandType.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeCommandType.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/DevModeStatus.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/Environment.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/Environment.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/Environment.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/Environment.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitConfig.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitConfig.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitConfig.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitConfig.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepo.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepo.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepo.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepo.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepoFile.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepoFile.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepoFile.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GitRepoFile.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GroupedKey.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GroupedKey.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/GroupedKey.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/GroupedKey.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/KaravanSchema.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/KaravanSchema.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/KaravanSchema.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/KaravanSchema.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/PipelineStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/PipelineStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/PipelineStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/PipelineStatus.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/PodStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/PodStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/PodStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/PodStatus.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/Project.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/Project.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/Project.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/Project.java
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java
similarity index 95%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java
index ff1e1311..853be3a6 100644
--- a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ProjectFile.java
@@ -1,12 +1,9 @@
package org.apache.camel.karavan.datagrid.model;
-import org.infinispan.api.annotations.indexing.Indexed;
import org.infinispan.protostream.annotations.ProtoDoc;
import org.infinispan.protostream.annotations.ProtoFactory;
import org.infinispan.protostream.annotations.ProtoField;
-import java.time.Instant;
-
public class ProjectFile {
public static final String CACHE = "project_files";
@ProtoField(number = 1)
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ServiceStatus.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ServiceStatus.java
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/ServiceStatus.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/datagrid/model/ServiceStatus.java
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerEventListener.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerEventListener.java
similarity index 96%
rename from karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerEventListener.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerEventListener.java
index d8961b75..2480ee80 100644
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerEventListener.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerEventListener.java
@@ -1,4 +1,4 @@
-package org.apache.camel.karavan.bashi.docker;
+package org.apache.camel.karavan.docker;
import com.github.dockerjava.api.async.ResultCallback;
import com.github.dockerjava.api.model.Container;
@@ -6,7 +6,6 @@ import com.github.dockerjava.api.model.ContainerPort;
import com.github.dockerjava.api.model.Event;
import com.github.dockerjava.api.model.EventType;
import io.vertx.core.eventbus.EventBus;
-import org.apache.camel.karavan.bashi.ConductorService;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.ContainerInfo;
import org.apache.camel.karavan.datagrid.model.DevModeStatus;
@@ -83,7 +82,7 @@ public class DockerEventListener implements ResultCallback<Event> {
String status = event.getStatus();
String health = status.replace("health_status: ", "");
LOGGER.infof("Container %s health status: %s", container.getNames()[0], health);
- eventBus.publish(ConductorService.ADDRESS_INFINISPAN_HEALTH, health);
+ eventBus.publish(DockerService.ADDRESS_INFINISPAN_STARTED, health);
}
public void onDevModeEvent(Event event, Container container) {
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerService.java
similarity index 93%
rename from karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerService.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerService.java
index a49f8ebf..357b5d87 100644
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/DockerService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/DockerService.java
@@ -1,11 +1,10 @@
-package org.apache.camel.karavan.bashi.docker;
+package org.apache.camel.karavan.docker;
import com.github.dockerjava.api.DockerClient;
import com.github.dockerjava.api.async.ResultCallback;
import com.github.dockerjava.api.command.CreateContainerResponse;
import com.github.dockerjava.api.command.CreateNetworkResponse;
import com.github.dockerjava.api.command.HealthState;
-import com.github.dockerjava.api.command.LogContainerCmd;
import com.github.dockerjava.api.model.*;
import com.github.dockerjava.core.DefaultDockerClientConfig;
import com.github.dockerjava.core.DockerClientConfig;
@@ -25,19 +24,18 @@ import java.io.IOException;
import java.text.DecimalFormat;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.TimeUnit;
import java.util.stream.Collectors;
-import static org.apache.camel.karavan.bashi.ConductorService.ADDRESS_CONTAINER_STATS;
-import static org.apache.camel.karavan.bashi.ConductorService.ADDRESS_INFINISPAN_HEALTH;
-import static org.apache.camel.karavan.bashi.Constants.DATAGRID_CONTAINER_NAME;
-import static org.apache.camel.karavan.bashi.Constants.NETWORK_NAME;
-import static org.apache.camel.karavan.datagrid.model.DevModeCommand.DEVMODE_SUFFIX;
+import static org.apache.camel.karavan.service.KaravanService.DEVMODE_SUFFIX;
@ApplicationScoped
public class DockerService {
private static final Logger LOGGER = Logger.getLogger(DockerService.class.getName());
+
+ public static final String ADDRESS_INFINISPAN_STARTED = "ADDRESS_INFINISPAN_STARTED";
+
+ public static final String NETWORK_NAME = "karavan";
private static final DecimalFormat formatCpu = new DecimalFormat("0.00");
private static final DecimalFormat formatMiB = new DecimalFormat("0.0");
private static final DecimalFormat formatGiB = new DecimalFormat("0.00");
@@ -63,50 +61,10 @@ public class DockerService {
"memory", memoryUsage + " / " + memoryLimit,
"cpu", formatCpu(name, stats)
);
- eventBus.publish(ADDRESS_CONTAINER_STATS, data);
+// eventBus.publish(ADDRESS_CONTAINER_STATS, data);
});
}
- private String formatMemory(Long memory) {
- try {
- if (memory < (1073741824)) {
- return formatMiB.format(memory.doubleValue() / 1048576) + "MiB";
- } else {
- return formatGiB.format(memory.doubleValue() / 1073741824) + "GiB";
- }
- } catch (Exception e) {
- return "";
- }
- }
-
- private String formatCpu(String containerName, Statistics stats) {
- try {
- double cpuUsage = 0;
- long previousCpu = previousStats.containsKey(containerName) ? previousStats.get(containerName).getItem1() : -1;
- long previousSystem = previousStats.containsKey(containerName) ? previousStats.get(containerName).getItem2() : -1;
-
- CpuStatsConfig cpuStats = stats.getCpuStats();
- if (cpuStats != null) {
- CpuUsageConfig cpuUsageConfig = cpuStats.getCpuUsage();
- long systemUsage = cpuStats.getSystemCpuUsage();
- long totalUsage = cpuUsageConfig.getTotalUsage();
-
- if (previousCpu != -1 && previousSystem != -1) {
- float cpuDelta = totalUsage - previousCpu;
- float systemDelta = systemUsage - previousSystem;
-
- if (cpuDelta > 0 && systemDelta > 0) {
- cpuUsage = cpuDelta / systemDelta * cpuStats.getOnlineCpus() * 100;
- }
- }
- previousStats.put(containerName, Tuple2.of(totalUsage, systemUsage));
- }
- return formatCpu.format(cpuUsage) + "%";
- } catch (Exception e) {
- return "";
- }
- }
-
public void startListeners() {
getDockerClient().eventsCmd().exec(dockerEventListener);
}
@@ -131,8 +89,8 @@ public class DockerService {
.filter(c -> c.getState().equals("running"))
.forEach(c -> {
HealthState hs = getDockerClient().inspectContainerCmd(c.getId()).exec().getState().getHealth();
- if (c.getNames()[0].equals("/" + DATAGRID_CONTAINER_NAME)) {
- eventBus.publish(ADDRESS_INFINISPAN_HEALTH, hs.getStatus());
+ if (c.getNames()[0].equals("/" + InfinispanContainer.INFINISPAN_CONTAINER_NAME)) {
+// eventBus.publish(ADDRESS_INFINISPAN_HEALTH, hs.getStatus());
}
});
}
@@ -288,4 +246,44 @@ public class DockerService {
private DockerClient getDockerClient() {
return DockerClientImpl.getInstance(getDockerClientConfig(), getDockerHttpClient());
}
+
+ private String formatMemory(Long memory) {
+ try {
+ if (memory < (1073741824)) {
+ return formatMiB.format(memory.doubleValue() / 1048576) + "MiB";
+ } else {
+ return formatGiB.format(memory.doubleValue() / 1073741824) + "GiB";
+ }
+ } catch (Exception e) {
+ return "";
+ }
+ }
+
+ private String formatCpu(String containerName, Statistics stats) {
+ try {
+ double cpuUsage = 0;
+ long previousCpu = previousStats.containsKey(containerName) ? previousStats.get(containerName).getItem1() : -1;
+ long previousSystem = previousStats.containsKey(containerName) ? previousStats.get(containerName).getItem2() : -1;
+
+ CpuStatsConfig cpuStats = stats.getCpuStats();
+ if (cpuStats != null) {
+ CpuUsageConfig cpuUsageConfig = cpuStats.getCpuUsage();
+ long systemUsage = cpuStats.getSystemCpuUsage();
+ long totalUsage = cpuUsageConfig.getTotalUsage();
+
+ if (previousCpu != -1 && previousSystem != -1) {
+ float cpuDelta = totalUsage - previousCpu;
+ float systemDelta = systemUsage - previousSystem;
+
+ if (cpuDelta > 0 && systemDelta > 0) {
+ cpuUsage = cpuDelta / systemDelta * cpuStats.getOnlineCpus() * 100;
+ }
+ }
+ previousStats.put(containerName, Tuple2.of(totalUsage, systemUsage));
+ }
+ return formatCpu.format(cpuUsage) + "%";
+ } catch (Exception e) {
+ return "";
+ }
+ }
}
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/InfinispanContainer.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/InfinispanContainer.java
new file mode 100644
index 00000000..dd7b596c
--- /dev/null
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/InfinispanContainer.java
@@ -0,0 +1,48 @@
+package org.apache.camel.karavan.docker;
+
+import com.github.dockerjava.api.model.HealthCheck;
+import org.eclipse.microprofile.config.inject.ConfigProperty;
+import org.jboss.logging.Logger;
+
+import javax.enterprise.context.ApplicationScoped;
+import javax.inject.Inject;
+import java.util.List;
+import java.util.Map;
+
+@ApplicationScoped
+public class InfinispanContainer {
+
+ @ConfigProperty(name = "infinispan.image")
+ String infinispanImage;
+ @ConfigProperty(name = "infinispan.port")
+ String infinispanPort;
+ @ConfigProperty(name = "infinispan.username")
+ String infinispanUsername;
+ @ConfigProperty(name = "infinispan.password")
+ String infinispanPassword;
+
+ @Inject
+ DockerService dockerService;
+
+ private static final Logger LOGGER = Logger.getLogger(InfinispanContainer.class.getName());
+
+ public static final String INFINISPAN_CONTAINER_NAME = "infinispan";
+
+ public void startInfinispan() {
+ try {
+ LOGGER.info("Infinispan is starting...");
+
+ HealthCheck healthCheck = new HealthCheck().withTest(List.of("CMD", "curl", "-f", "http://localhost:11222/rest/v2/cache-managers/default/health/status"))
+ .withInterval(10000000000L).withTimeout(10000000000L).withStartPeriod(10000000000L).withRetries(30);
+
+ dockerService.createContainer(INFINISPAN_CONTAINER_NAME, infinispanImage,
+ List.of("USER=" + infinispanUsername, "PASS=" + infinispanPassword),
+ infinispanPort, true, healthCheck, Map.of()
+ );
+ dockerService.startContainer(INFINISPAN_CONTAINER_NAME);
+ LOGGER.info("Infinispan is started");
+ } catch (Exception e) {
+ LOGGER.error(e.getMessage());
+ }
+ }
+}
\ No newline at end of file
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/LogCallback.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/LogCallback.java
similarity index 90%
rename from karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/LogCallback.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/LogCallback.java
index c3d4ad5a..a05efb31 100644
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/docker/LogCallback.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/docker/LogCallback.java
@@ -1,4 +1,4 @@
-package org.apache.camel.karavan.bashi.docker;
+package org.apache.camel.karavan.docker;
import com.github.dockerjava.api.async.ResultCallback;
import com.github.dockerjava.api.model.Frame;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/DeploymentEventHandler.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/DeploymentEventHandler.java
similarity index 97%
rename from karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/DeploymentEventHandler.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/DeploymentEventHandler.java
index 8cb28816..a94b121e 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/DeploymentEventHandler.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/DeploymentEventHandler.java
@@ -1,10 +1,9 @@
-package org.apache.camel.karavan.handler;
+package org.apache.camel.karavan.kubernetes;
import io.fabric8.kubernetes.api.model.apps.Deployment;
import io.fabric8.kubernetes.client.informers.ResourceEventHandler;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.DeploymentStatus;
-import org.apache.camel.karavan.service.KubernetesService;
import org.jboss.logging.Logger;
public class DeploymentEventHandler implements ResourceEventHandler<Deployment> {
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KubernetesService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/KubernetesService.java
similarity index 99%
rename from karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KubernetesService.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/KubernetesService.java
index cc02c5af..8ded5a49 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KubernetesService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/KubernetesService.java
@@ -14,7 +14,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.apache.camel.karavan.service;
+package org.apache.camel.karavan.kubernetes;
import io.fabric8.knative.internal.pkg.apis.Condition;
import io.fabric8.kubernetes.api.model.*;
@@ -32,7 +32,7 @@ import io.vertx.mutiny.core.eventbus.EventBus;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.Project;
import org.apache.camel.karavan.datagrid.model.ProjectFile;
-import org.apache.camel.karavan.handler.*;
+import org.apache.camel.karavan.service.CodeService;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.eclipse.microprofile.health.HealthCheck;
import org.eclipse.microprofile.health.HealthCheckResponse;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PipelineRunEventHandler.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PipelineRunEventHandler.java
similarity index 97%
rename from karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PipelineRunEventHandler.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PipelineRunEventHandler.java
index 25f1112f..441e019c 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PipelineRunEventHandler.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PipelineRunEventHandler.java
@@ -1,11 +1,10 @@
-package org.apache.camel.karavan.handler;
+package org.apache.camel.karavan.kubernetes;
import io.fabric8.kubernetes.client.informers.ResourceEventHandler;
import io.fabric8.tekton.pipeline.v1beta1.PipelineRun;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.PipelineStatus;
import org.apache.camel.karavan.datagrid.model.Project;
-import org.apache.camel.karavan.service.KubernetesService;
import org.jboss.logging.Logger;
import java.time.Instant;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PodEventHandler.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PodEventHandler.java
similarity index 97%
rename from karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PodEventHandler.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PodEventHandler.java
index 2a79bd7b..ab4aad86 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/PodEventHandler.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/PodEventHandler.java
@@ -1,4 +1,4 @@
-package org.apache.camel.karavan.handler;
+package org.apache.camel.karavan.kubernetes;
import io.fabric8.kubernetes.api.model.ContainerBuilder;
import io.fabric8.kubernetes.api.model.Pod;
@@ -7,7 +7,6 @@ import io.fabric8.kubernetes.api.model.ResourceRequirements;
import io.fabric8.kubernetes.client.informers.ResourceEventHandler;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.PodStatus;
-import org.apache.camel.karavan.service.KubernetesService;
import org.jboss.logging.Logger;
import static org.apache.camel.karavan.service.CodeService.DEFAULT_CONTAINER_RESOURCES;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/ServiceEventHandler.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/ServiceEventHandler.java
similarity index 96%
rename from karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/ServiceEventHandler.java
rename to karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/ServiceEventHandler.java
index 8a4cfed5..01c97b9c 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/handler/ServiceEventHandler.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/kubernetes/ServiceEventHandler.java
@@ -1,10 +1,9 @@
-package org.apache.camel.karavan.handler;
+package org.apache.camel.karavan.kubernetes;
import io.fabric8.kubernetes.api.model.Service;
import io.fabric8.kubernetes.client.informers.ResourceEventHandler;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.ServiceStatus;
-import org.apache.camel.karavan.service.KubernetesService;
import org.jboss.logging.Logger;
public class ServiceEventHandler implements ResourceEventHandler<Service> {
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/listener/DevModeCommandListener.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/listener/DevModeCommandListener.java
index 8c1956ad..152ebe52 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/listener/DevModeCommandListener.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/listener/DevModeCommandListener.java
@@ -6,7 +6,7 @@ import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.DevModeCommand;
import org.apache.camel.karavan.datagrid.model.DevModeCommandName;
import org.apache.camel.karavan.datagrid.model.Project;
-import org.apache.camel.karavan.service.KubernetesService;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import javax.enterprise.context.ApplicationScoped;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CamelService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CamelService.java
index 3f3ee96d..c8cca2b9 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CamelService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CamelService.java
@@ -26,6 +26,7 @@ import io.vertx.mutiny.ext.web.client.HttpResponse;
import io.vertx.mutiny.ext.web.client.WebClient;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.*;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.eclipse.microprofile.faulttolerance.CircuitBreaker;
import org.jboss.logging.Logger;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CodeService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CodeService.java
index 572d64e8..261bad1f 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CodeService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/CodeService.java
@@ -31,6 +31,7 @@ import org.apache.camel.karavan.datagrid.model.GitRepo;
import org.apache.camel.karavan.datagrid.model.GitRepoFile;
import org.apache.camel.karavan.datagrid.model.Project;
import org.apache.camel.karavan.datagrid.model.ProjectFile;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.jboss.logging.Logger;
import org.yaml.snakeyaml.Yaml;
import org.yaml.snakeyaml.constructor.SafeConstructor;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/GitService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/GitService.java
index 8930d550..4135cf34 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/GitService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/GitService.java
@@ -20,6 +20,7 @@ import io.fabric8.kubernetes.api.model.Secret;
import io.smallrye.mutiny.tuples.Tuple2;
import io.vertx.core.Vertx;
import org.apache.camel.karavan.datagrid.model.*;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.jgit.api.CheckoutCommand;
import org.eclipse.jgit.api.CloneCommand;
import org.eclipse.jgit.api.FetchCommand;
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KaravanService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KaravanService.java
index b0b1f359..cb97a85b 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KaravanService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/KaravanService.java
@@ -18,9 +18,13 @@ package org.apache.camel.karavan.service;
import io.quarkus.runtime.ShutdownEvent;
import io.quarkus.runtime.StartupEvent;
+import io.quarkus.vertx.ConsumeEvent;
import io.vertx.core.eventbus.EventBus;
import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.Environment;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
+import org.apache.camel.karavan.docker.DockerService;
+import org.apache.camel.karavan.docker.InfinispanContainer;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.jboss.logging.Logger;
@@ -33,12 +37,22 @@ public class KaravanService {
private static final Logger LOGGER = Logger.getLogger(KaravanService.class.getName());
+ public static final String DEVMODE_SUFFIX = "-devmode";
+
+ private static final String HEALTHY = "healthy";
+
@Inject
DatagridService datagridService;
@Inject
KubernetesService kubernetesService;
+ @Inject
+ DockerService dockerService;
+
+ @Inject
+ InfinispanContainer infinispanContainer;
+
@Inject
EventBus bus;
@@ -46,12 +60,27 @@ public class KaravanService {
String environment;
void onStart(@Observes StartupEvent ev) {
- LOGGER.info("Start Karavan");
- datagridService.start();
- datagridService.clearAllStatuses();
- setEnvironment();
- initialImport();
- startInformers();
+ if (!kubernetesService.inKubernetes()) {
+ LOGGER.info("Start Karavan with Docker");
+ dockerService.createNetwork();
+ dockerService.checkDataGridHealth();
+ dockerService.startListeners();
+ infinispanContainer.startInfinispan();
+ } else {
+ LOGGER.info("Start Karavan in " + (kubernetesService.isOpenshift() ? "OpenShift" : "Kubernetes"));
+ startServices(HEALTHY);
+ }
+ }
+
+ @ConsumeEvent(value = DockerService.ADDRESS_INFINISPAN_STARTED, blocking = true, ordered = true)
+ void startServices(String infinispanHealth){
+ if (infinispanHealth.equals(HEALTHY)) {
+ datagridService.start();
+ datagridService.clearAllStatuses();
+ setEnvironment();
+ initialImport();
+ startInformers();
+ }
}
void onStop(@Observes ShutdownEvent ev) {
diff --git a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/ProjectService.java b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/ProjectService.java
index 5a1a8952..13dbaf38 100644
--- a/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/ProjectService.java
+++ b/karavan-cloud/karavan-app/src/main/java/org/apache/camel/karavan/service/ProjectService.java
@@ -23,6 +23,7 @@ import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.GitRepo;
import org.apache.camel.karavan.datagrid.model.Project;
import org.apache.camel.karavan.datagrid.model.ProjectFile;
+import org.apache.camel.karavan.kubernetes.KubernetesService;
import org.eclipse.jgit.revwalk.RevCommit;
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.eclipse.microprofile.health.HealthCheck;
diff --git a/karavan-cloud/karavan-app/src/main/resources/application.properties b/karavan-cloud/karavan-app/src/main/resources/application.properties
index 4c7a49e6..9d5ac6fe 100644
--- a/karavan-cloud/karavan-app/src/main/resources/application.properties
+++ b/karavan-cloud/karavan-app/src/main/resources/application.properties
@@ -4,6 +4,8 @@ karavan.default-runtime=quarkus
karavan.runtimes=quarkus,spring-boot
karavan.camel-status-interval=10s
karavan.devmode-status-interval=2s
+karavan.container-status-interval=10s
+karavan.container-stats-interval=10s
quarkus.scheduler.enabled=true
# Git repository Configuration
@@ -13,13 +15,14 @@ karavan.git-password=${GIT_TOKEN}
karavan.git-branch=main
karavan.git-pull-interval=disabled
-# Infinispan Server address
-#quarkus.infinispan-client.hosts=infinispan.karavan:11222
-quarkus.infinispan-client.username=admin
-quarkus.infinispan-client.password=karavan
+# Infinispan container config in Docker
+infinispan.image=quay.io/infinispan/server:14.0.6.Final
+infinispan.port=11222:11222
+infinispan.username=admin
+infinispan.password=karavan
+infinispan.hosts=localhost:11222
quarkus.infinispan-client.devservices.enabled=false
-quarkus.infinispan-client.health.enabled=false
# Infinispan client intelligence
# Use BASIC as a Docker for Mac workaround
@@ -33,6 +36,14 @@ quarkus.infinispan-client.client-intelligence=BASIC
%dev.quarkus.http.auth.permission.authenticated.enabled=false
%dev.quarkus.http.auth.permission.public.enabled=false
+# Public Test
+%test.karavan.auth=public
+%test.quarkus.oidc.enabled=false
+%test.quarkus.http.auth.basic=false
+%test.quarkus.security.users.embedded.enabled=false
+%test.quarkus.http.auth.permission.authenticated.enabled=false
+%test.quarkus.http.auth.permission.public.enabled=false
+
# Public
%public.karavan.auth=public
%public.quarkus.oidc.enabled=false
diff --git a/karavan-cloud/karavan-datagrid/src/main/resources/command-cache-config.xml b/karavan-cloud/karavan-app/src/main/resources/cache/command-cache-config.xml
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/resources/command-cache-config.xml
rename to karavan-cloud/karavan-app/src/main/resources/cache/command-cache-config.xml
diff --git a/karavan-cloud/karavan-datagrid/src/main/resources/data-cache-config.xml b/karavan-cloud/karavan-app/src/main/resources/cache/data-cache-config.xml
similarity index 100%
rename from karavan-cloud/karavan-datagrid/src/main/resources/data-cache-config.xml
rename to karavan-cloud/karavan-app/src/main/resources/cache/data-cache-config.xml
diff --git a/karavan-cloud/karavan-datagrid/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java b/karavan-cloud/karavan-app/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java
similarity index 95%
rename from karavan-cloud/karavan-datagrid/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java
rename to karavan-cloud/karavan-app/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java
index 86c11346..4a07ba7f 100644
--- a/karavan-cloud/karavan-datagrid/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java
+++ b/karavan-cloud/karavan-app/src/test/java/org/apache/camel/karavan/datagrid/DataGridTest.java
@@ -4,6 +4,7 @@ package org.apache.camel.karavan.datagrid;
import io.quarkus.test.junit.QuarkusTest;
import io.quarkus.vertx.ConsumeEvent;
import io.vertx.core.json.JsonObject;
+import org.apache.camel.karavan.datagrid.DatagridService;
import org.apache.camel.karavan.datagrid.model.*;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test;
@@ -12,7 +13,8 @@ import org.junit.jupiter.api.TestInstance;
import javax.inject.Inject;
import java.util.ArrayList;
import java.util.List;
-import java.util.concurrent.*;
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
import static org.junit.jupiter.api.Assertions.assertEquals;
diff --git a/karavan-cloud/karavan-app/src/test/resources/application.properties b/karavan-cloud/karavan-app/src/test/resources/application.properties
new file mode 100644
index 00000000..0eacb003
--- /dev/null
+++ b/karavan-cloud/karavan-app/src/test/resources/application.properties
@@ -0,0 +1,11 @@
+#
+#%test.quarkus.infinispan-client.hosts=infinispan:11222
+#%test.quarkus.infinispan-client.username=admin
+#%test.quarkus.infinispan-client.password=password
+#
+#%test.quarkus.infinispan-client.devservices.enabled=true
+#%test.quarkus.infinispan-client.devservices.service-name=infinispan
+#%test.quarkus.infinispan-client.devservices.image-name=quay.io/infinispan/server:14.0.6.Final
+#%test.quarkus.infinispan-client.devservices.port=11222
+#%test.quarkus.infinispan-client.health.enabled=false
+#%test.quarkus.infinispan-client.client-intelligence=BASIC
diff --git a/karavan-cloud/karavan-bashi/.dockerignore b/karavan-cloud/karavan-bashi/.dockerignore
deleted file mode 100644
index 94810d00..00000000
--- a/karavan-cloud/karavan-bashi/.dockerignore
+++ /dev/null
@@ -1,5 +0,0 @@
-*
-!target/*-runner
-!target/*-runner.jar
-!target/lib/*
-!target/quarkus-app/*
\ No newline at end of file
diff --git a/karavan-cloud/karavan-bashi/.gitignore b/karavan-cloud/karavan-bashi/.gitignore
deleted file mode 100644
index 8c7863e7..00000000
--- a/karavan-cloud/karavan-bashi/.gitignore
+++ /dev/null
@@ -1,43 +0,0 @@
-#Maven
-target/
-pom.xml.tag
-pom.xml.releaseBackup
-pom.xml.versionsBackup
-release.properties
-.flattened-pom.xml
-
-# Eclipse
-.project
-.classpath
-.settings/
-bin/
-
-# IntelliJ
-.idea
-*.ipr
-*.iml
-*.iws
-
-# NetBeans
-nb-configuration.xml
-
-# Visual Studio Code
-.vscode
-.factorypath
-
-# OSX
-.DS_Store
-
-# Vim
-*.swp
-*.swo
-
-# patch
-*.orig
-*.rej
-
-# Local environment
-.env
-
-# Plugin directory
-/.quarkus/cli/plugins/
diff --git a/karavan-cloud/karavan-bashi/.java-version b/karavan-cloud/karavan-bashi/.java-version
deleted file mode 100644
index b4de3947..00000000
--- a/karavan-cloud/karavan-bashi/.java-version
+++ /dev/null
@@ -1 +0,0 @@
-11
diff --git a/karavan-cloud/karavan-bashi/.mvn/wrapper/.gitignore b/karavan-cloud/karavan-bashi/.mvn/wrapper/.gitignore
deleted file mode 100644
index e72f5e8b..00000000
--- a/karavan-cloud/karavan-bashi/.mvn/wrapper/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-maven-wrapper.jar
diff --git a/karavan-cloud/karavan-bashi/.mvn/wrapper/MavenWrapperDownloader.java b/karavan-cloud/karavan-bashi/.mvn/wrapper/MavenWrapperDownloader.java
deleted file mode 100644
index 84d1e60d..00000000
--- a/karavan-cloud/karavan-bashi/.mvn/wrapper/MavenWrapperDownloader.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * 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.
- */
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.Authenticator;
-import java.net.PasswordAuthentication;
-import java.net.URL;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.nio.file.Paths;
-import java.nio.file.StandardCopyOption;
-
-public final class MavenWrapperDownloader
-{
- private static final String WRAPPER_VERSION = "3.2.0";
-
- private static final boolean VERBOSE = Boolean.parseBoolean( System.getenv( "MVNW_VERBOSE" ) );
-
- public static void main( String[] args )
- {
- log( "Apache Maven Wrapper Downloader " + WRAPPER_VERSION );
-
- if ( args.length != 2 )
- {
- System.err.println( " - ERROR wrapperUrl or wrapperJarPath parameter missing" );
- System.exit( 1 );
- }
-
- try
- {
- log( " - Downloader started" );
- final URL wrapperUrl = new URL( args[0] );
- final String jarPath = args[1].replace( "..", "" ); // Sanitize path
- final Path wrapperJarPath = Paths.get( jarPath ).toAbsolutePath().normalize();
- downloadFileFromURL( wrapperUrl, wrapperJarPath );
- log( "Done" );
- }
- catch ( IOException e )
- {
- System.err.println( "- Error downloading: " + e.getMessage() );
- if ( VERBOSE )
- {
- e.printStackTrace();
- }
- System.exit( 1 );
- }
- }
-
- private static void downloadFileFromURL( URL wrapperUrl, Path wrapperJarPath )
- throws IOException
- {
- log( " - Downloading to: " + wrapperJarPath );
- if ( System.getenv( "MVNW_USERNAME" ) != null && System.getenv( "MVNW_PASSWORD" ) != null )
- {
- final String username = System.getenv( "MVNW_USERNAME" );
- final char[] password = System.getenv( "MVNW_PASSWORD" ).toCharArray();
- Authenticator.setDefault( new Authenticator()
- {
- @Override
- protected PasswordAuthentication getPasswordAuthentication()
- {
- return new PasswordAuthentication( username, password );
- }
- } );
- }
- try ( InputStream inStream = wrapperUrl.openStream() )
- {
- Files.copy( inStream, wrapperJarPath, StandardCopyOption.REPLACE_EXISTING );
- }
- log( " - Downloader complete" );
- }
-
- private static void log( String msg )
- {
- if ( VERBOSE )
- {
- System.out.println( msg );
- }
- }
-
-}
diff --git a/karavan-cloud/karavan-bashi/.mvn/wrapper/maven-wrapper.properties b/karavan-cloud/karavan-bashi/.mvn/wrapper/maven-wrapper.properties
deleted file mode 100644
index 70f4f50f..00000000
--- a/karavan-cloud/karavan-bashi/.mvn/wrapper/maven-wrapper.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# 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.
-distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.8/apache-maven-3.8.8-bin.zip
-wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
diff --git a/karavan-cloud/karavan-bashi/mvnw b/karavan-cloud/karavan-bashi/mvnw
deleted file mode 100755
index 8d937f4c..00000000
--- a/karavan-cloud/karavan-bashi/mvnw
+++ /dev/null
@@ -1,308 +0,0 @@
-#!/bin/sh
-# ----------------------------------------------------------------------------
-# 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.
-# ----------------------------------------------------------------------------
-
-# ----------------------------------------------------------------------------
-# Apache Maven Wrapper startup batch script, version 3.2.0
-#
-# Required ENV vars:
-# ------------------
-# JAVA_HOME - location of a JDK home dir
-#
-# Optional ENV vars
-# -----------------
-# MAVEN_OPTS - parameters passed to the Java VM when running Maven
-# e.g. to debug Maven itself, use
-# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
-# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
-# ----------------------------------------------------------------------------
-
-if [ -z "$MAVEN_SKIP_RC" ] ; then
-
- if [ -f /usr/local/etc/mavenrc ] ; then
- . /usr/local/etc/mavenrc
- fi
-
- if [ -f /etc/mavenrc ] ; then
- . /etc/mavenrc
- fi
-
- if [ -f "$HOME/.mavenrc" ] ; then
- . "$HOME/.mavenrc"
- fi
-
-fi
-
-# OS specific support. $var _must_ be set to either true or false.
-cygwin=false;
-darwin=false;
-mingw=false
-case "$(uname)" in
- CYGWIN*) cygwin=true ;;
- MINGW*) mingw=true;;
- Darwin*) darwin=true
- # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
- # See https://developer.apple.com/library/mac/qa/qa1170/_index.html
- if [ -z "$JAVA_HOME" ]; then
- if [ -x "/usr/libexec/java_home" ]; then
- JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME
- else
- JAVA_HOME="/Library/Java/Home"; export JAVA_HOME
- fi
- fi
- ;;
-esac
-
-if [ -z "$JAVA_HOME" ] ; then
- if [ -r /etc/gentoo-release ] ; then
- JAVA_HOME=$(java-config --jre-home)
- fi
-fi
-
-# For Cygwin, ensure paths are in UNIX format before anything is touched
-if $cygwin ; then
- [ -n "$JAVA_HOME" ] &&
- JAVA_HOME=$(cygpath --unix "$JAVA_HOME")
- [ -n "$CLASSPATH" ] &&
- CLASSPATH=$(cygpath --path --unix "$CLASSPATH")
-fi
-
-# For Mingw, ensure paths are in UNIX format before anything is touched
-if $mingw ; then
- [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] &&
- JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)"
-fi
-
-if [ -z "$JAVA_HOME" ]; then
- javaExecutable="$(which javac)"
- if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then
- # readlink(1) is not available as standard on Solaris 10.
- readLink=$(which readlink)
- if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then
- if $darwin ; then
- javaHome="$(dirname "\"$javaExecutable\"")"
- javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac"
- else
- javaExecutable="$(readlink -f "\"$javaExecutable\"")"
- fi
- javaHome="$(dirname "\"$javaExecutable\"")"
- javaHome=$(expr "$javaHome" : '\(.*\)/bin')
- JAVA_HOME="$javaHome"
- export JAVA_HOME
- fi
- fi
-fi
-
-if [ -z "$JAVACMD" ] ; then
- if [ -n "$JAVA_HOME" ] ; then
- if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
- # IBM's JDK on AIX uses strange locations for the executables
- JAVACMD="$JAVA_HOME/jre/sh/java"
- else
- JAVACMD="$JAVA_HOME/bin/java"
- fi
- else
- JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)"
- fi
-fi
-
-if [ ! -x "$JAVACMD" ] ; then
- echo "Error: JAVA_HOME is not defined correctly." >&2
- echo " We cannot execute $JAVACMD" >&2
- exit 1
-fi
-
-if [ -z "$JAVA_HOME" ] ; then
- echo "Warning: JAVA_HOME environment variable is not set."
-fi
-
-# traverses directory structure from process work directory to filesystem root
-# first directory with .mvn subdirectory is considered project base directory
-find_maven_basedir() {
- if [ -z "$1" ]
- then
- echo "Path not specified to find_maven_basedir"
- return 1
- fi
-
- basedir="$1"
- wdir="$1"
- while [ "$wdir" != '/' ] ; do
- if [ -d "$wdir"/.mvn ] ; then
- basedir=$wdir
- break
- fi
- # workaround for JBEAP-8937 (on Solaris 10/Sparc)
- if [ -d "${wdir}" ]; then
- wdir=$(cd "$wdir/.." || exit 1; pwd)
- fi
- # end of workaround
- done
- printf '%s' "$(cd "$basedir" || exit 1; pwd)"
-}
-
-# concatenates all lines of a file
-concat_lines() {
- if [ -f "$1" ]; then
- # Remove \r in case we run on Windows within Git Bash
- # and check out the repository with auto CRLF management
- # enabled. Otherwise, we may read lines that are delimited with
- # \r\n and produce $'-Xarg\r' rather than -Xarg due to word
- # splitting rules.
- tr -s '\r\n' ' ' < "$1"
- fi
-}
-
-log() {
- if [ "$MVNW_VERBOSE" = true ]; then
- printf '%s\n' "$1"
- fi
-}
-
-BASE_DIR=$(find_maven_basedir "$(dirname "$0")")
-if [ -z "$BASE_DIR" ]; then
- exit 1;
-fi
-
-MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR
-log "$MAVEN_PROJECTBASEDIR"
-
-##########################################################################################
-# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
-# This allows using the maven wrapper in projects that prohibit checking in binary data.
-##########################################################################################
-wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar"
-if [ -r "$wrapperJarPath" ]; then
- log "Found $wrapperJarPath"
-else
- log "Couldn't find $wrapperJarPath, downloading it ..."
-
- if [ -n "$MVNW_REPOURL" ]; then
- wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- else
- wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- fi
- while IFS="=" read -r key value; do
- # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' )
- safeValue=$(echo "$value" | tr -d '\r')
- case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;;
- esac
- done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties"
- log "Downloading from: $wrapperUrl"
-
- if $cygwin; then
- wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath")
- fi
-
- if command -v wget > /dev/null; then
- log "Found wget ... using wget"
- [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet"
- if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
- wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
- else
- wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
- fi
- elif command -v curl > /dev/null; then
- log "Found curl ... using curl"
- [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent"
- if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
- curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath"
- else
- curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath"
- fi
- else
- log "Falling back to using Java to download"
- javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java"
- javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class"
- # For Cygwin, switch paths to Windows format before running javac
- if $cygwin; then
- javaSource=$(cygpath --path --windows "$javaSource")
- javaClass=$(cygpath --path --windows "$javaClass")
- fi
- if [ -e "$javaSource" ]; then
- if [ ! -e "$javaClass" ]; then
- log " - Compiling MavenWrapperDownloader.java ..."
- ("$JAVA_HOME/bin/javac" "$javaSource")
- fi
- if [ -e "$javaClass" ]; then
- log " - Running MavenWrapperDownloader.java ..."
- ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath"
- fi
- fi
- fi
-fi
-##########################################################################################
-# End of extension
-##########################################################################################
-
-# If specified, validate the SHA-256 sum of the Maven wrapper jar file
-wrapperSha256Sum=""
-while IFS="=" read -r key value; do
- case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;;
- esac
-done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties"
-if [ -n "$wrapperSha256Sum" ]; then
- wrapperSha256Result=false
- if command -v sha256sum > /dev/null; then
- if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then
- wrapperSha256Result=true
- fi
- elif command -v shasum > /dev/null; then
- if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then
- wrapperSha256Result=true
- fi
- else
- echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available."
- echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties."
- exit 1
- fi
- if [ $wrapperSha256Result = false ]; then
- echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2
- echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2
- echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2
- exit 1
- fi
-fi
-
-MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS"
-
-# For Cygwin, switch paths to Windows format before running java
-if $cygwin; then
- [ -n "$JAVA_HOME" ] &&
- JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME")
- [ -n "$CLASSPATH" ] &&
- CLASSPATH=$(cygpath --path --windows "$CLASSPATH")
- [ -n "$MAVEN_PROJECTBASEDIR" ] &&
- MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR")
-fi
-
-# Provide a "standardized" way to retrieve the CLI args that will
-# work with both Windows and non-Windows executions.
-MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*"
-export MAVEN_CMD_LINE_ARGS
-
-WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
-
-# shellcheck disable=SC2086 # safe args
-exec "$JAVACMD" \
- $MAVEN_OPTS \
- $MAVEN_DEBUG_OPTS \
- -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
- "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
- ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"
diff --git a/karavan-cloud/karavan-bashi/mvnw.cmd b/karavan-cloud/karavan-bashi/mvnw.cmd
deleted file mode 100755
index c4586b56..00000000
--- a/karavan-cloud/karavan-bashi/mvnw.cmd
+++ /dev/null
@@ -1,205 +0,0 @@
-@REM ----------------------------------------------------------------------------
-@REM Licensed to the Apache Software Foundation (ASF) under one
-@REM or more contributor license agreements. See the NOTICE file
-@REM distributed with this work for additional information
-@REM regarding copyright ownership. The ASF licenses this file
-@REM to you under the Apache License, Version 2.0 (the
-@REM "License"); you may not use this file except in compliance
-@REM with the License. You may obtain a copy of the License at
-@REM
-@REM http://www.apache.org/licenses/LICENSE-2.0
-@REM
-@REM Unless required by applicable law or agreed to in writing,
-@REM software distributed under the License is distributed on an
-@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-@REM KIND, either express or implied. See the License for the
-@REM specific language governing permissions and limitations
-@REM under the License.
-@REM ----------------------------------------------------------------------------
-
-@REM ----------------------------------------------------------------------------
-@REM Apache Maven Wrapper startup batch script, version 3.2.0
-@REM
-@REM Required ENV vars:
-@REM JAVA_HOME - location of a JDK home dir
-@REM
-@REM Optional ENV vars
-@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
-@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending
-@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
-@REM e.g. to debug Maven itself, use
-@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
-@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
-@REM ----------------------------------------------------------------------------
-
-@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
-@echo off
-@REM set title of command window
-title %0
-@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
-@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
-
-@REM set %HOME% to equivalent of $HOME
-if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
-
-@REM Execute a user defined script before this one
-if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
-@REM check for pre script, once with legacy .bat ending and once with .cmd ending
-if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %*
-if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %*
-:skipRcPre
-
-@setlocal
-
-set ERROR_CODE=0
-
-@REM To isolate internal variables from possible post scripts, we use another setlocal
-@setlocal
-
-@REM ==== START VALIDATION ====
-if not "%JAVA_HOME%" == "" goto OkJHome
-
-echo.
-echo Error: JAVA_HOME not found in your environment. >&2
-echo Please set the JAVA_HOME variable in your environment to match the >&2
-echo location of your Java installation. >&2
-echo.
-goto error
-
-:OkJHome
-if exist "%JAVA_HOME%\bin\java.exe" goto init
-
-echo.
-echo Error: JAVA_HOME is set to an invalid directory. >&2
-echo JAVA_HOME = "%JAVA_HOME%" >&2
-echo Please set the JAVA_HOME variable in your environment to match the >&2
-echo location of your Java installation. >&2
-echo.
-goto error
-
-@REM ==== END VALIDATION ====
-
-:init
-
-@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
-@REM Fallback to current working directory if not found.
-
-set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
-IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
-
-set EXEC_DIR=%CD%
-set WDIR=%EXEC_DIR%
-:findBaseDir
-IF EXIST "%WDIR%"\.mvn goto baseDirFound
-cd ..
-IF "%WDIR%"=="%CD%" goto baseDirNotFound
-set WDIR=%CD%
-goto findBaseDir
-
-:baseDirFound
-set MAVEN_PROJECTBASEDIR=%WDIR%
-cd "%EXEC_DIR%"
-goto endDetectBaseDir
-
-:baseDirNotFound
-set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
-cd "%EXEC_DIR%"
-
-:endDetectBaseDir
-
-IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
-
-@setlocal EnableExtensions EnableDelayedExpansion
-for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
-@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
-
-:endReadAdditionalConfig
-
-SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
-set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
-set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
-
-set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
-
-FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
- IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B
-)
-
-@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
-@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
-if exist %WRAPPER_JAR% (
- if "%MVNW_VERBOSE%" == "true" (
- echo Found %WRAPPER_JAR%
- )
-) else (
- if not "%MVNW_REPOURL%" == "" (
- SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- )
- if "%MVNW_VERBOSE%" == "true" (
- echo Couldn't find %WRAPPER_JAR%, downloading it ...
- echo Downloading from: %WRAPPER_URL%
- )
-
- powershell -Command "&{"^
- "$webclient = new-object System.Net.WebClient;"^
- "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
- "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
- "}"^
- "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^
- "}"
- if "%MVNW_VERBOSE%" == "true" (
- echo Finished downloading %WRAPPER_JAR%
- )
-)
-@REM End of extension
-
-@REM If specified, validate the SHA-256 sum of the Maven wrapper jar file
-SET WRAPPER_SHA_256_SUM=""
-FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
- IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B
-)
-IF NOT %WRAPPER_SHA_256_SUM%=="" (
- powershell -Command "&{"^
- "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^
- "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^
- " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^
- " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^
- " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^
- " exit 1;"^
- "}"^
- "}"
- if ERRORLEVEL 1 goto error
-)
-
-@REM Provide a "standardized" way to retrieve the CLI args that will
-@REM work with both Windows and non-Windows executions.
-set MAVEN_CMD_LINE_ARGS=%*
-
-%MAVEN_JAVA_EXE% ^
- %JVM_CONFIG_MAVEN_PROPS% ^
- %MAVEN_OPTS% ^
- %MAVEN_DEBUG_OPTS% ^
- -classpath %WRAPPER_JAR% ^
- "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^
- %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
-if ERRORLEVEL 1 goto error
-goto end
-
-:error
-set ERROR_CODE=1
-
-:end
-@endlocal & set ERROR_CODE=%ERROR_CODE%
-
-if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost
-@REM check for post script, once with legacy .bat ending and once with .cmd ending
-if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat"
-if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd"
-:skipRcPost
-
-@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
-if "%MAVEN_BATCH_PAUSE%"=="on" pause
-
-if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE%
-
-cmd /C exit /B %ERROR_CODE%
diff --git a/karavan-cloud/karavan-bashi/pom.xml b/karavan-cloud/karavan-bashi/pom.xml
deleted file mode 100644
index 670c283e..00000000
--- a/karavan-cloud/karavan-bashi/pom.xml
+++ /dev/null
@@ -1,120 +0,0 @@
-<?xml version="1.0"?>
-<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <modelVersion>4.0.0</modelVersion>
- <artifactId>karavan-bashi</artifactId>
-
- <parent>
- <groupId>org.apache.camel.karavan</groupId>
- <artifactId>karavan-cloud</artifactId>
- <version>3.21.1-SNAPSHOT</version>
- <relativePath>../pom.xml</relativePath>
- </parent>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.camel.karavan</groupId>
- <artifactId>karavan-datagrid</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-arc</artifactId>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-scheduler</artifactId>
- </dependency>
- <dependency>
- <groupId>com.github.docker-java</groupId>
- <artifactId>docker-java-core</artifactId>
- <version>${docker-java.version}</version>
- </dependency>
- <dependency>
- <groupId>com.github.docker-java</groupId>
- <artifactId>docker-java-transport-httpclient5</artifactId>
- <version>${docker-java.version}</version>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-junit5</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>io.rest-assured</groupId>
- <artifactId>rest-assured</artifactId>
- <scope>test</scope>
- </dependency>
- </dependencies>
- <build>
- <plugins>
- <plugin>
- <groupId>${quarkus.platform.group-id}</groupId>
- <artifactId>quarkus-maven-plugin</artifactId>
- <version>${quarkus.platform.version}</version>
- <extensions>true</extensions>
- <executions>
- <execution>
- <goals>
- <goal>build</goal>
- <goal>generate-code</goal>
- <goal>generate-code-tests</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>${compiler-plugin.version}</version>
- <configuration>
- <compilerArgs>
- <arg>-parameters</arg>
- </compilerArgs>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>${surefire-plugin.version}</version>
- <configuration>
- <systemPropertyVariables>
- <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
- <maven.home>${maven.home}</maven.home>
- </systemPropertyVariables>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-failsafe-plugin</artifactId>
- <version>${surefire-plugin.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>integration-test</goal>
- <goal>verify</goal>
- </goals>
- <configuration>
- <systemPropertyVariables>
- <native.image.path>${project.build.directory}/${project.build.finalName}-runner</native.image.path>
- <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
- <maven.home>${maven.home}</maven.home>
- </systemPropertyVariables>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <profiles>
- <profile>
- <id>native</id>
- <activation>
- <property>
- <name>native</name>
- </property>
- </activation>
- <properties>
- <skipITs>false</skipITs>
- <quarkus.package.type>native</quarkus.package.type>
- </properties>
- </profile>
- </profiles>
-</project>
diff --git a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.jvm b/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.jvm
deleted file mode 100644
index 304872d0..00000000
--- a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.jvm
+++ /dev/null
@@ -1,95 +0,0 @@
-####
-# This Dockerfile is used in order to build a container that runs the Quarkus application in JVM mode
-#
-# Before building the container image run:
-#
-# ./mvnw package
-#
-# Then, build the image with:
-#
-# docker build -f src/main/docker/Dockerfile.jvm -t quarkus/karavan-bashi-jvm .
-#
-# Then run the container using:
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi-jvm
-#
-# If you want to include the debug port into your docker image
-# you will have to expose the debug port (default 5005 being the default) like this : EXPOSE 8080 5005.
-# Additionally you will have to set -e JAVA_DEBUG=true and -e JAVA_DEBUG_PORT=*:5005
-# when running the container
-#
-# Then run the container using :
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi-jvm
-#
-# This image uses the `run-java.sh` script to run the application.
-# This scripts computes the command line to execute your Java application, and
-# includes memory/GC tuning.
-# You can configure the behavior using the following environment properties:
-# - JAVA_OPTS: JVM options passed to the `java` command (example: "-verbose:class")
-# - JAVA_OPTS_APPEND: User specified Java options to be appended to generated options
-# in JAVA_OPTS (example: "-Dsome.property=foo")
-# - JAVA_MAX_MEM_RATIO: Is used when no `-Xmx` option is given in JAVA_OPTS. This is
-# used to calculate a default maximal heap memory based on a containers restriction.
-# If used in a container without any memory constraints for the container then this
-# option has no effect. If there is a memory constraint then `-Xmx` is set to a ratio
-# of the container available memory as set here. The default is `50` which means 50%
-# of the available memory is used as an upper boundary. You can skip this mechanism by
-# setting this value to `0` in which case no `-Xmx` option is added.
-# - JAVA_INITIAL_MEM_RATIO: Is used when no `-Xms` option is given in JAVA_OPTS. This
-# is used to calculate a default initial heap memory based on the maximum heap memory.
-# If used in a container without any memory constraints for the container then this
-# option has no effect. If there is a memory constraint then `-Xms` is set to a ratio
-# of the `-Xmx` memory as set here. The default is `25` which means 25% of the `-Xmx`
-# is used as the initial heap size. You can skip this mechanism by setting this value
-# to `0` in which case no `-Xms` option is added (example: "25")
-# - JAVA_MAX_INITIAL_MEM: Is used when no `-Xms` option is given in JAVA_OPTS.
-# This is used to calculate the maximum value of the initial heap memory. If used in
-# a container without any memory constraints for the container then this option has
-# no effect. If there is a memory constraint then `-Xms` is limited to the value set
-# here. The default is 4096MB which means the calculated value of `-Xms` never will
-# be greater than 4096MB. The value of this variable is expressed in MB (example: "4096")
-# - JAVA_DIAGNOSTICS: Set this to get some diagnostics information to standard output
-# when things are happening. This option, if set to true, will set
-# `-XX:+UnlockDiagnosticVMOptions`. Disabled by default (example: "true").
-# - JAVA_DEBUG: If set remote debugging will be switched on. Disabled by default (example:
-# true").
-# - JAVA_DEBUG_PORT: Port used for remote debugging. Defaults to 5005 (example: "8787").
-# - CONTAINER_CORE_LIMIT: A calculated core limit as described in
-# https://www.kernel.org/doc/Documentation/scheduler/sched-bwc.txt. (example: "2")
-# - CONTAINER_MAX_MEMORY: Memory limit given to the container (example: "1024").
-# - GC_MIN_HEAP_FREE_RATIO: Minimum percentage of heap free after GC to avoid expansion.
-# (example: "20")
-# - GC_MAX_HEAP_FREE_RATIO: Maximum percentage of heap free after GC to avoid shrinking.
-# (example: "40")
-# - GC_TIME_RATIO: Specifies the ratio of the time spent outside the garbage collection.
-# (example: "4")
-# - GC_ADAPTIVE_SIZE_POLICY_WEIGHT: The weighting given to the current GC time versus
-# previous GC times. (example: "90")
-# - GC_METASPACE_SIZE: The initial metaspace size. (example: "20")
-# - GC_MAX_METASPACE_SIZE: The maximum metaspace size. (example: "100")
-# - GC_CONTAINER_OPTIONS: Specify Java GC to use. The value of this variable should
-# contain the necessary JRE command-line options to specify the required GC, which
-# will override the default of `-XX:+UseParallelGC` (example: -XX:+UseG1GC).
-# - HTTPS_PROXY: The location of the https proxy. (example: "myuser@127.0.0.1:8080")
-# - HTTP_PROXY: The location of the http proxy. (example: "myuser@127.0.0.1:8080")
-# - NO_PROXY: A comma separated lists of hosts, IP addresses or domains that can be
-# accessed directly. (example: "foo.example.com,bar.example.com")
-#
-###
-FROM registry.access.redhat.com/ubi8/openjdk-17:1.15
-
-ENV LANGUAGE='en_US:en'
-
-
-# We make four distinct layers so if there are application changes the library layers can be re-used
-COPY --chown=185 target/quarkus-app/lib/ /deployments/lib/
-COPY --chown=185 target/quarkus-app/*.jar /deployments/
-COPY --chown=185 target/quarkus-app/app/ /deployments/app/
-COPY --chown=185 target/quarkus-app/quarkus/ /deployments/quarkus/
-
-EXPOSE 8080
-USER 185
-ENV JAVA_OPTS="-Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager"
-ENV JAVA_APP_JAR="/deployments/quarkus-run.jar"
-
diff --git a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.legacy-jar b/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.legacy-jar
deleted file mode 100644
index 5ed8043f..00000000
--- a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.legacy-jar
+++ /dev/null
@@ -1,91 +0,0 @@
-####
-# This Dockerfile is used in order to build a container that runs the Quarkus application in JVM mode
-#
-# Before building the container image run:
-#
-# ./mvnw package -Dquarkus.package.type=legacy-jar
-#
-# Then, build the image with:
-#
-# docker build -f src/main/docker/Dockerfile.legacy-jar -t quarkus/karavan-bashi-legacy-jar .
-#
-# Then run the container using:
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi-legacy-jar
-#
-# If you want to include the debug port into your docker image
-# you will have to expose the debug port (default 5005 being the default) like this : EXPOSE 8080 5005.
-# Additionally you will have to set -e JAVA_DEBUG=true and -e JAVA_DEBUG_PORT=*:5005
-# when running the container
-#
-# Then run the container using :
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi-legacy-jar
-#
-# This image uses the `run-java.sh` script to run the application.
-# This scripts computes the command line to execute your Java application, and
-# includes memory/GC tuning.
-# You can configure the behavior using the following environment properties:
-# - JAVA_OPTS: JVM options passed to the `java` command (example: "-verbose:class")
-# - JAVA_OPTS_APPEND: User specified Java options to be appended to generated options
-# in JAVA_OPTS (example: "-Dsome.property=foo")
-# - JAVA_MAX_MEM_RATIO: Is used when no `-Xmx` option is given in JAVA_OPTS. This is
-# used to calculate a default maximal heap memory based on a containers restriction.
-# If used in a container without any memory constraints for the container then this
-# option has no effect. If there is a memory constraint then `-Xmx` is set to a ratio
-# of the container available memory as set here. The default is `50` which means 50%
-# of the available memory is used as an upper boundary. You can skip this mechanism by
-# setting this value to `0` in which case no `-Xmx` option is added.
-# - JAVA_INITIAL_MEM_RATIO: Is used when no `-Xms` option is given in JAVA_OPTS. This
-# is used to calculate a default initial heap memory based on the maximum heap memory.
-# If used in a container without any memory constraints for the container then this
-# option has no effect. If there is a memory constraint then `-Xms` is set to a ratio
-# of the `-Xmx` memory as set here. The default is `25` which means 25% of the `-Xmx`
-# is used as the initial heap size. You can skip this mechanism by setting this value
-# to `0` in which case no `-Xms` option is added (example: "25")
-# - JAVA_MAX_INITIAL_MEM: Is used when no `-Xms` option is given in JAVA_OPTS.
-# This is used to calculate the maximum value of the initial heap memory. If used in
-# a container without any memory constraints for the container then this option has
-# no effect. If there is a memory constraint then `-Xms` is limited to the value set
-# here. The default is 4096MB which means the calculated value of `-Xms` never will
-# be greater than 4096MB. The value of this variable is expressed in MB (example: "4096")
-# - JAVA_DIAGNOSTICS: Set this to get some diagnostics information to standard output
-# when things are happening. This option, if set to true, will set
-# `-XX:+UnlockDiagnosticVMOptions`. Disabled by default (example: "true").
-# - JAVA_DEBUG: If set remote debugging will be switched on. Disabled by default (example:
-# true").
-# - JAVA_DEBUG_PORT: Port used for remote debugging. Defaults to 5005 (example: "8787").
-# - CONTAINER_CORE_LIMIT: A calculated core limit as described in
-# https://www.kernel.org/doc/Documentation/scheduler/sched-bwc.txt. (example: "2")
-# - CONTAINER_MAX_MEMORY: Memory limit given to the container (example: "1024").
-# - GC_MIN_HEAP_FREE_RATIO: Minimum percentage of heap free after GC to avoid expansion.
-# (example: "20")
-# - GC_MAX_HEAP_FREE_RATIO: Maximum percentage of heap free after GC to avoid shrinking.
-# (example: "40")
-# - GC_TIME_RATIO: Specifies the ratio of the time spent outside the garbage collection.
-# (example: "4")
-# - GC_ADAPTIVE_SIZE_POLICY_WEIGHT: The weighting given to the current GC time versus
-# previous GC times. (example: "90")
-# - GC_METASPACE_SIZE: The initial metaspace size. (example: "20")
-# - GC_MAX_METASPACE_SIZE: The maximum metaspace size. (example: "100")
-# - GC_CONTAINER_OPTIONS: Specify Java GC to use. The value of this variable should
-# contain the necessary JRE command-line options to specify the required GC, which
-# will override the default of `-XX:+UseParallelGC` (example: -XX:+UseG1GC).
-# - HTTPS_PROXY: The location of the https proxy. (example: "myuser@127.0.0.1:8080")
-# - HTTP_PROXY: The location of the http proxy. (example: "myuser@127.0.0.1:8080")
-# - NO_PROXY: A comma separated lists of hosts, IP addresses or domains that can be
-# accessed directly. (example: "foo.example.com,bar.example.com")
-#
-###
-FROM registry.access.redhat.com/ubi8/openjdk-17:1.15
-
-ENV LANGUAGE='en_US:en'
-
-
-COPY target/lib/* /deployments/lib/
-COPY target/*-runner.jar /deployments/quarkus-run.jar
-
-EXPOSE 8080
-USER 185
-ENV JAVA_OPTS="-Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager"
-ENV JAVA_APP_JAR="/deployments/quarkus-run.jar"
diff --git a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native b/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native
deleted file mode 100644
index 45ba5a97..00000000
--- a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native
+++ /dev/null
@@ -1,27 +0,0 @@
-####
-# This Dockerfile is used in order to build a container that runs the Quarkus application in native (no JVM) mode.
-#
-# Before building the container image run:
-#
-# ./mvnw package -Pnative
-#
-# Then, build the image with:
-#
-# docker build -f src/main/docker/Dockerfile.native -t quarkus/karavan-bashi .
-#
-# Then run the container using:
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi
-#
-###
-FROM registry.access.redhat.com/ubi8/ubi-minimal:8.6
-WORKDIR /work/
-RUN chown 1001 /work \
- && chmod "g+rwX" /work \
- && chown 1001:root /work
-COPY --chown=1001:root target/*-runner /work/application
-
-EXPOSE 8080
-USER 1001
-
-CMD ["./application", "-Dquarkus.http.host=0.0.0.0"]
diff --git a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native-micro b/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native-micro
deleted file mode 100644
index 05c02902..00000000
--- a/karavan-cloud/karavan-bashi/src/main/docker/Dockerfile.native-micro
+++ /dev/null
@@ -1,30 +0,0 @@
-####
-# This Dockerfile is used in order to build a container that runs the Quarkus application in native (no JVM) mode.
-# It uses a micro base image, tuned for Quarkus native executables.
-# It reduces the size of the resulting container image.
-# Check https://quarkus.io/guides/quarkus-runtime-base-image for further information about this image.
-#
-# Before building the container image run:
-#
-# ./mvnw package -Pnative
-#
-# Then, build the image with:
-#
-# docker build -f src/main/docker/Dockerfile.native-micro -t quarkus/karavan-bashi .
-#
-# Then run the container using:
-#
-# docker run -i --rm -p 8080:8080 quarkus/karavan-bashi
-#
-###
-FROM quay.io/quarkus/quarkus-micro-image:2.0
-WORKDIR /work/
-RUN chown 1001 /work \
- && chmod "g+rwX" /work \
- && chown 1001:root /work
-COPY --chown=1001:root target/*-runner /work/application
-
-EXPOSE 8080
-USER 1001
-
-CMD ["./application", "-Dquarkus.http.host=0.0.0.0"]
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/ConductorService.java b/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/ConductorService.java
deleted file mode 100644
index 6ca21110..00000000
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/ConductorService.java
+++ /dev/null
@@ -1,168 +0,0 @@
-package org.apache.camel.karavan.bashi;
-
-import com.github.dockerjava.api.model.Container;
-import com.github.dockerjava.api.model.HealthCheck;
-import com.github.dockerjava.api.model.Statistics;
-import io.quarkus.vertx.ConsumeEvent;
-import io.vertx.core.json.JsonObject;
-import org.apache.camel.karavan.bashi.docker.DockerService;
-import org.apache.camel.karavan.datagrid.DatagridService;
-import org.apache.camel.karavan.datagrid.model.*;
-import org.eclipse.microprofile.config.inject.ConfigProperty;
-import org.jboss.logging.Logger;
-
-import javax.enterprise.context.ApplicationScoped;
-import javax.inject.Inject;
-import java.util.List;
-import java.util.Map;
-import java.util.Objects;
-
-import static org.apache.camel.karavan.bashi.Constants.*;
-
-@ApplicationScoped
-public class ConductorService {
-
- @ConfigProperty(name = "karavan.image")
- String karavanImage;
- @ConfigProperty(name = "karavan.port")
- String karavanPort;
- @ConfigProperty(name = "karavan.git-repository")
- String gitRepository;
- @ConfigProperty(name = "karavan.git-username")
- String gitUsername;
- @ConfigProperty(name = "karavan.git-password")
- String gitPassword;
- @ConfigProperty(name = "karavan.git-branch")
- String gitBranch;
- @ConfigProperty(name = "karavan.runner-image")
- String runnerImage;
-
- @ConfigProperty(name = "infinispan.image")
- String infinispanImage;
- @ConfigProperty(name = "infinispan.port")
- String infinispanPort;
- @ConfigProperty(name = "infinispan.username")
- String infinispanUsername;
- @ConfigProperty(name = "infinispan.password")
- String infinispanPassword;
-
- @ConfigProperty(name = "karavan.environment")
- String environment;
-
- @Inject
- DockerService dockerService;
-
- @Inject
- DatagridService datagridService;
-
- @Inject
- LoggerService loggerService;
-
- private static final Logger LOGGER = Logger.getLogger(ConductorService.class.getName());
-
- public static final String ADDRESS_INFINISPAN_START = "ADDRESS_INFINISPAN_START";
- public static final String ADDRESS_INFINISPAN_HEALTH = "ADDRESS_DATAGRID_HEALTH";
- public static final String ADDRESS_CONTAINER_STATS = "ADDRESS_CONTAINER_STATS";
-
- @ConsumeEvent(value = ADDRESS_INFINISPAN_START, blocking = true, ordered = true)
- void startInfinispan(String data) throws InterruptedException {
- LOGGER.info("Infinispan is starting...");
-
- HealthCheck healthCheck = new HealthCheck().withTest(List.of("CMD", "curl", "-f", "http://localhost:11222/rest/v2/cache-managers/default/health/status"))
- .withInterval(10000000000L).withTimeout(10000000000L).withStartPeriod(10000000000L).withRetries(30);
-
- dockerService.createContainer(DATAGRID_CONTAINER_NAME, infinispanImage,
- List.of("USER=" + infinispanUsername, "PASS=" + infinispanPassword),
- infinispanPort, true, healthCheck, Map.of()
- );
- dockerService.startContainer(DATAGRID_CONTAINER_NAME);
- LOGGER.info("Infinispan is started");
- }
-
- @ConsumeEvent(value = ADDRESS_INFINISPAN_HEALTH, blocking = true, ordered = true)
- void startServices(String infinispanHealth){
- if (infinispanHealth.equals("healthy")) {
- datagridService.start();
- datagridService.clearAllStatuses();
- }
- }
-
- @ConsumeEvent(value = ADDRESS_INFINISPAN_HEALTH, blocking = true, ordered = true)
- void startKaravan(String infinispanHealth) throws InterruptedException {
- if (infinispanHealth.equals("healthy")) {
- LOGGER.info("Karavan is starting...");
- dockerService.createContainer(KARAVAN_CONTAINER_NAME, karavanImage,
- List.of(
- "QUARKUS_INFINISPAN_CLIENT_HOSTS=infinispan:11222",
- "KARAVAN_GIT_REPOSITORY=" + gitRepository,
- "KARAVAN_GIT_USERNAME=" + gitUsername,
- "KARAVAN_GIT_PASSWORD=" + gitPassword,
- "KARAVAN_GIT_BRANCH=" + gitBranch
- ),
- karavanPort, true, new HealthCheck(), Map.of()
- );
- dockerService.startContainer(KARAVAN_CONTAINER_NAME);
- LOGGER.info("Karavan is started");
- }
- }
-
- @ConsumeEvent(value = ADDRESS_CONTAINER_STATS, blocking = true, ordered = true)
- public void saveStats(JsonObject data) {
- String projectId = data.getString("projectId");
- String memory = data.getString("memory");
- String cpu = data.getString("cpu");
- if (datagridService.isReady()) {
- PodStatus podStatus = datagridService.getDevModePodStatuses(projectId, environment);
- if (podStatus != null) {
- podStatus.setCpuInfo(cpu);
- podStatus.setMemoryInfo(memory);
- datagridService.savePodStatus(podStatus);
- }
- }
- }
-
- @ConsumeEvent(value = DatagridService.ADDRESS_DEVMODE_COMMAND, blocking = true, ordered = true)
- void receiveCommand(JsonObject message) throws InterruptedException {
- LOGGER.info("DevMode Command: " + message);
- DevModeCommand command = message.mapTo(DevModeCommand.class);
- datagridService.deleteDevModeCommand(command);
- switch (command.getCommandName()){
- case RUN:
- runContainer(command);
- break;
- case DELETE:
- deleteContainer(command);
- break;
- case LOG:
- loggerService.logContainer(command);
- break;
- }
- }
-
- void runContainer(DevModeCommand command) throws InterruptedException {
- if (DevModeCommandType.DEVMODE.equals(command.getType())) {
- String projectId = command.getProjectId();
- LOGGER.infof("DevMode starting for %s", projectId);
- HealthCheck healthCheck = new HealthCheck().withTest(List.of("CMD", "curl", "-f", "http://localhost:8080/q/dev/health"))
- .withInterval(10000000000L).withTimeout(10000000000L).withStartPeriod(10000000000L).withRetries(30);
- dockerService.createContainer(command.getContainerName(), runnerImage,
- List.of(), "", false, healthCheck,
- Map.of("type", "devmode", "projectId", projectId));
- dockerService.startContainer(command.getContainerName());
- LOGGER.infof("DevMode started for %s", projectId);
- } else {
-
- }
- }
-
- void deleteContainer(DevModeCommand command) {
- if (DevModeCommandType.DEVMODE.equals(command.getType())) {
- datagridService.deleteDevModeStatus(command.getProjectId());
- dockerService.stopContainer(command.getContainerName());
- dockerService.deleteContainer(command.getContainerName());
- } else {
- dockerService.stopContainer(command.getContainerName());
- dockerService.deleteContainer(command.getContainerName());
- }
- }
-}
\ No newline at end of file
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/Constants.java b/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/Constants.java
deleted file mode 100644
index 38c3a89e..00000000
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/Constants.java
+++ /dev/null
@@ -1,9 +0,0 @@
-package org.apache.camel.karavan.bashi;
-
-public class Constants {
-
- public static final String NETWORK_NAME = "karavan";
- public static final String DATAGRID_CONTAINER_NAME = "infinispan";
-
- public static final String KARAVAN_CONTAINER_NAME = "karavan";
-}
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/KaravanBashi.java b/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/KaravanBashi.java
deleted file mode 100644
index 98c3f40d..00000000
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/KaravanBashi.java
+++ /dev/null
@@ -1,35 +0,0 @@
-package org.apache.camel.karavan.bashi;
-
-import io.quarkus.runtime.ShutdownEvent;
-import io.quarkus.runtime.StartupEvent;
-import io.vertx.core.eventbus.EventBus;
-import org.apache.camel.karavan.bashi.docker.DockerService;
-import org.jboss.logging.Logger;
-
-import javax.enterprise.context.ApplicationScoped;
-import javax.enterprise.event.Observes;
-import javax.inject.Inject;
-
-@ApplicationScoped
-public class KaravanBashi {
-
- @Inject
- EventBus eventBus;
-
- @Inject
- DockerService dockerService;
-
- private static final Logger LOGGER = Logger.getLogger(KaravanBashi.class.getName());
-
- void onStart(@Observes StartupEvent ev) {
- LOGGER.info("Karavan Bashi is starting...");
- dockerService.createNetwork();
- dockerService.checkDataGridHealth();
- dockerService.startListeners();
- eventBus.publish(ConductorService.ADDRESS_INFINISPAN_START, "");
- }
-
- void onStop(@Observes ShutdownEvent ev) {
- LOGGER.info("Karavan Bashi is stopping...");
- }
-}
diff --git a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/LoggerService.java b/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/LoggerService.java
deleted file mode 100644
index 40fb7a38..00000000
--- a/karavan-cloud/karavan-bashi/src/main/java/org/apache/camel/karavan/bashi/LoggerService.java
+++ /dev/null
@@ -1,42 +0,0 @@
-package org.apache.camel.karavan.bashi;
-
-import org.apache.camel.karavan.bashi.docker.DockerService;
-import org.apache.camel.karavan.bashi.docker.LogCallback;
-import org.apache.camel.karavan.datagrid.DatagridService;
-import org.apache.camel.karavan.datagrid.model.DevModeCommand;
-import org.jboss.logging.Logger;
-
-import javax.enterprise.context.ApplicationScoped;
-import javax.inject.Inject;
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-
-@ApplicationScoped
-public class LoggerService {
-
- private static final Logger LOGGER = Logger.getLogger(LoggerService.class.getName());
-
- @Inject
- DockerService dockerService;
-
- @Inject
- DatagridService datagridService;
-
- private final Map<String, LogCallback> loggers = new ConcurrentHashMap<>();
-
- void logContainer(DevModeCommand command) {
- try {
- String containerName = command.getContainerName();
- LogCallback callback = loggers.get(containerName);
- if (callback != null) {
- callback.close();
- loggers.remove(containerName);
- } else {
- callback = dockerService.logContainer(containerName);
- loggers.put(containerName, callback);
- }
- } catch (Exception e) {
- LOGGER.error(e.getMessage());
- }
- }
-}
\ No newline at end of file
diff --git a/karavan-cloud/karavan-bashi/src/main/resources/application.properties b/karavan-cloud/karavan-bashi/src/main/resources/application.properties
deleted file mode 100644
index 534ad21d..00000000
--- a/karavan-cloud/karavan-bashi/src/main/resources/application.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Infinispan container config in Docker
-infinispan.image=quay.io/infinispan/server:14.0.6.Final
-infinispan.port=11222:11222
-infinispan.username=admin
-infinispan.password=karavan
-
-# Karavan container config in Docker
-karavan.image=marat/karavan:3.21.1-SNAPSHOT
-karavan.runner-image=ghcr.io/apache/camel-karavan-runner:3.21.0
-karavan.port=8080:8080
-karavan.environment=dev
-karavan.default-runtime=quarkus
-karavan.runtimes=quarkus,spring-boot
-karavan.container-stats-interval=5s
-
-# Git repository Configuration
-karavan.git-repository=${GIT_REPOSITORY}
-karavan.git-username=${GIT_USERNAME}
-karavan.git-password=${GIT_TOKEN}
-karavan.git-branch=main
-
-# Infinispan Client configuration
-quarkus.infinispan-client.hosts=localhost:11222
-quarkus.infinispan-client.username=admin
-quarkus.infinispan-client.password=karavan
-quarkus.infinispan-client.devservices.enabled=false
-
-quarkus.package.type=uber-jar
\ No newline at end of file
diff --git a/karavan-cloud/karavan-datagrid/.java-version b/karavan-cloud/karavan-datagrid/.java-version
deleted file mode 100644
index b4de3947..00000000
--- a/karavan-cloud/karavan-datagrid/.java-version
+++ /dev/null
@@ -1 +0,0 @@
-11
diff --git a/karavan-cloud/karavan-datagrid/.mvn/wrapper/maven-wrapper.properties b/karavan-cloud/karavan-datagrid/.mvn/wrapper/maven-wrapper.properties
deleted file mode 100644
index 70f4f50f..00000000
--- a/karavan-cloud/karavan-datagrid/.mvn/wrapper/maven-wrapper.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# 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.
-distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.8/apache-maven-3.8.8-bin.zip
-wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
diff --git a/karavan-cloud/karavan-datagrid/mvnw b/karavan-cloud/karavan-datagrid/mvnw
deleted file mode 100755
index 8d937f4c..00000000
--- a/karavan-cloud/karavan-datagrid/mvnw
+++ /dev/null
@@ -1,308 +0,0 @@
-#!/bin/sh
-# ----------------------------------------------------------------------------
-# 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.
-# ----------------------------------------------------------------------------
-
-# ----------------------------------------------------------------------------
-# Apache Maven Wrapper startup batch script, version 3.2.0
-#
-# Required ENV vars:
-# ------------------
-# JAVA_HOME - location of a JDK home dir
-#
-# Optional ENV vars
-# -----------------
-# MAVEN_OPTS - parameters passed to the Java VM when running Maven
-# e.g. to debug Maven itself, use
-# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
-# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
-# ----------------------------------------------------------------------------
-
-if [ -z "$MAVEN_SKIP_RC" ] ; then
-
- if [ -f /usr/local/etc/mavenrc ] ; then
- . /usr/local/etc/mavenrc
- fi
-
- if [ -f /etc/mavenrc ] ; then
- . /etc/mavenrc
- fi
-
- if [ -f "$HOME/.mavenrc" ] ; then
- . "$HOME/.mavenrc"
- fi
-
-fi
-
-# OS specific support. $var _must_ be set to either true or false.
-cygwin=false;
-darwin=false;
-mingw=false
-case "$(uname)" in
- CYGWIN*) cygwin=true ;;
- MINGW*) mingw=true;;
- Darwin*) darwin=true
- # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
- # See https://developer.apple.com/library/mac/qa/qa1170/_index.html
- if [ -z "$JAVA_HOME" ]; then
- if [ -x "/usr/libexec/java_home" ]; then
- JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME
- else
- JAVA_HOME="/Library/Java/Home"; export JAVA_HOME
- fi
- fi
- ;;
-esac
-
-if [ -z "$JAVA_HOME" ] ; then
- if [ -r /etc/gentoo-release ] ; then
- JAVA_HOME=$(java-config --jre-home)
- fi
-fi
-
-# For Cygwin, ensure paths are in UNIX format before anything is touched
-if $cygwin ; then
- [ -n "$JAVA_HOME" ] &&
- JAVA_HOME=$(cygpath --unix "$JAVA_HOME")
- [ -n "$CLASSPATH" ] &&
- CLASSPATH=$(cygpath --path --unix "$CLASSPATH")
-fi
-
-# For Mingw, ensure paths are in UNIX format before anything is touched
-if $mingw ; then
- [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] &&
- JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)"
-fi
-
-if [ -z "$JAVA_HOME" ]; then
- javaExecutable="$(which javac)"
- if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then
- # readlink(1) is not available as standard on Solaris 10.
- readLink=$(which readlink)
- if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then
- if $darwin ; then
- javaHome="$(dirname "\"$javaExecutable\"")"
- javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac"
- else
- javaExecutable="$(readlink -f "\"$javaExecutable\"")"
- fi
- javaHome="$(dirname "\"$javaExecutable\"")"
- javaHome=$(expr "$javaHome" : '\(.*\)/bin')
- JAVA_HOME="$javaHome"
- export JAVA_HOME
- fi
- fi
-fi
-
-if [ -z "$JAVACMD" ] ; then
- if [ -n "$JAVA_HOME" ] ; then
- if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
- # IBM's JDK on AIX uses strange locations for the executables
- JAVACMD="$JAVA_HOME/jre/sh/java"
- else
- JAVACMD="$JAVA_HOME/bin/java"
- fi
- else
- JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)"
- fi
-fi
-
-if [ ! -x "$JAVACMD" ] ; then
- echo "Error: JAVA_HOME is not defined correctly." >&2
- echo " We cannot execute $JAVACMD" >&2
- exit 1
-fi
-
-if [ -z "$JAVA_HOME" ] ; then
- echo "Warning: JAVA_HOME environment variable is not set."
-fi
-
-# traverses directory structure from process work directory to filesystem root
-# first directory with .mvn subdirectory is considered project base directory
-find_maven_basedir() {
- if [ -z "$1" ]
- then
- echo "Path not specified to find_maven_basedir"
- return 1
- fi
-
- basedir="$1"
- wdir="$1"
- while [ "$wdir" != '/' ] ; do
- if [ -d "$wdir"/.mvn ] ; then
- basedir=$wdir
- break
- fi
- # workaround for JBEAP-8937 (on Solaris 10/Sparc)
- if [ -d "${wdir}" ]; then
- wdir=$(cd "$wdir/.." || exit 1; pwd)
- fi
- # end of workaround
- done
- printf '%s' "$(cd "$basedir" || exit 1; pwd)"
-}
-
-# concatenates all lines of a file
-concat_lines() {
- if [ -f "$1" ]; then
- # Remove \r in case we run on Windows within Git Bash
- # and check out the repository with auto CRLF management
- # enabled. Otherwise, we may read lines that are delimited with
- # \r\n and produce $'-Xarg\r' rather than -Xarg due to word
- # splitting rules.
- tr -s '\r\n' ' ' < "$1"
- fi
-}
-
-log() {
- if [ "$MVNW_VERBOSE" = true ]; then
- printf '%s\n' "$1"
- fi
-}
-
-BASE_DIR=$(find_maven_basedir "$(dirname "$0")")
-if [ -z "$BASE_DIR" ]; then
- exit 1;
-fi
-
-MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR
-log "$MAVEN_PROJECTBASEDIR"
-
-##########################################################################################
-# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
-# This allows using the maven wrapper in projects that prohibit checking in binary data.
-##########################################################################################
-wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar"
-if [ -r "$wrapperJarPath" ]; then
- log "Found $wrapperJarPath"
-else
- log "Couldn't find $wrapperJarPath, downloading it ..."
-
- if [ -n "$MVNW_REPOURL" ]; then
- wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- else
- wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- fi
- while IFS="=" read -r key value; do
- # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' )
- safeValue=$(echo "$value" | tr -d '\r')
- case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;;
- esac
- done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties"
- log "Downloading from: $wrapperUrl"
-
- if $cygwin; then
- wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath")
- fi
-
- if command -v wget > /dev/null; then
- log "Found wget ... using wget"
- [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet"
- if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
- wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
- else
- wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath"
- fi
- elif command -v curl > /dev/null; then
- log "Found curl ... using curl"
- [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent"
- if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
- curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath"
- else
- curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath"
- fi
- else
- log "Falling back to using Java to download"
- javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java"
- javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class"
- # For Cygwin, switch paths to Windows format before running javac
- if $cygwin; then
- javaSource=$(cygpath --path --windows "$javaSource")
- javaClass=$(cygpath --path --windows "$javaClass")
- fi
- if [ -e "$javaSource" ]; then
- if [ ! -e "$javaClass" ]; then
- log " - Compiling MavenWrapperDownloader.java ..."
- ("$JAVA_HOME/bin/javac" "$javaSource")
- fi
- if [ -e "$javaClass" ]; then
- log " - Running MavenWrapperDownloader.java ..."
- ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath"
- fi
- fi
- fi
-fi
-##########################################################################################
-# End of extension
-##########################################################################################
-
-# If specified, validate the SHA-256 sum of the Maven wrapper jar file
-wrapperSha256Sum=""
-while IFS="=" read -r key value; do
- case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;;
- esac
-done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties"
-if [ -n "$wrapperSha256Sum" ]; then
- wrapperSha256Result=false
- if command -v sha256sum > /dev/null; then
- if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then
- wrapperSha256Result=true
- fi
- elif command -v shasum > /dev/null; then
- if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then
- wrapperSha256Result=true
- fi
- else
- echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available."
- echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties."
- exit 1
- fi
- if [ $wrapperSha256Result = false ]; then
- echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2
- echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2
- echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2
- exit 1
- fi
-fi
-
-MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS"
-
-# For Cygwin, switch paths to Windows format before running java
-if $cygwin; then
- [ -n "$JAVA_HOME" ] &&
- JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME")
- [ -n "$CLASSPATH" ] &&
- CLASSPATH=$(cygpath --path --windows "$CLASSPATH")
- [ -n "$MAVEN_PROJECTBASEDIR" ] &&
- MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR")
-fi
-
-# Provide a "standardized" way to retrieve the CLI args that will
-# work with both Windows and non-Windows executions.
-MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*"
-export MAVEN_CMD_LINE_ARGS
-
-WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
-
-# shellcheck disable=SC2086 # safe args
-exec "$JAVACMD" \
- $MAVEN_OPTS \
- $MAVEN_DEBUG_OPTS \
- -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
- "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
- ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"
diff --git a/karavan-cloud/karavan-datagrid/mvnw.cmd b/karavan-cloud/karavan-datagrid/mvnw.cmd
deleted file mode 100644
index f80fbad3..00000000
--- a/karavan-cloud/karavan-datagrid/mvnw.cmd
+++ /dev/null
@@ -1,205 +0,0 @@
-@REM ----------------------------------------------------------------------------
-@REM Licensed to the Apache Software Foundation (ASF) under one
-@REM or more contributor license agreements. See the NOTICE file
-@REM distributed with this work for additional information
-@REM regarding copyright ownership. The ASF licenses this file
-@REM to you under the Apache License, Version 2.0 (the
-@REM "License"); you may not use this file except in compliance
-@REM with the License. You may obtain a copy of the License at
-@REM
-@REM http://www.apache.org/licenses/LICENSE-2.0
-@REM
-@REM Unless required by applicable law or agreed to in writing,
-@REM software distributed under the License is distributed on an
-@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-@REM KIND, either express or implied. See the License for the
-@REM specific language governing permissions and limitations
-@REM under the License.
-@REM ----------------------------------------------------------------------------
-
-@REM ----------------------------------------------------------------------------
-@REM Apache Maven Wrapper startup batch script, version 3.2.0
-@REM
-@REM Required ENV vars:
-@REM JAVA_HOME - location of a JDK home dir
-@REM
-@REM Optional ENV vars
-@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
-@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending
-@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
-@REM e.g. to debug Maven itself, use
-@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
-@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
-@REM ----------------------------------------------------------------------------
-
-@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
-@echo off
-@REM set title of command window
-title %0
-@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
-@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
-
-@REM set %HOME% to equivalent of $HOME
-if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
-
-@REM Execute a user defined script before this one
-if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
-@REM check for pre script, once with legacy .bat ending and once with .cmd ending
-if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %*
-if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %*
-:skipRcPre
-
-@setlocal
-
-set ERROR_CODE=0
-
-@REM To isolate internal variables from possible post scripts, we use another setlocal
-@setlocal
-
-@REM ==== START VALIDATION ====
-if not "%JAVA_HOME%" == "" goto OkJHome
-
-echo.
-echo Error: JAVA_HOME not found in your environment. >&2
-echo Please set the JAVA_HOME variable in your environment to match the >&2
-echo location of your Java installation. >&2
-echo.
-goto error
-
-:OkJHome
-if exist "%JAVA_HOME%\bin\java.exe" goto init
-
-echo.
-echo Error: JAVA_HOME is set to an invalid directory. >&2
-echo JAVA_HOME = "%JAVA_HOME%" >&2
-echo Please set the JAVA_HOME variable in your environment to match the >&2
-echo location of your Java installation. >&2
-echo.
-goto error
-
-@REM ==== END VALIDATION ====
-
-:init
-
-@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
-@REM Fallback to current working directory if not found.
-
-set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
-IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
-
-set EXEC_DIR=%CD%
-set WDIR=%EXEC_DIR%
-:findBaseDir
-IF EXIST "%WDIR%"\.mvn goto baseDirFound
-cd ..
-IF "%WDIR%"=="%CD%" goto baseDirNotFound
-set WDIR=%CD%
-goto findBaseDir
-
-:baseDirFound
-set MAVEN_PROJECTBASEDIR=%WDIR%
-cd "%EXEC_DIR%"
-goto endDetectBaseDir
-
-:baseDirNotFound
-set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
-cd "%EXEC_DIR%"
-
-:endDetectBaseDir
-
-IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
-
-@setlocal EnableExtensions EnableDelayedExpansion
-for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
-@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
-
-:endReadAdditionalConfig
-
-SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
-set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
-set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
-
-set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
-
-FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
- IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B
-)
-
-@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
-@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
-if exist %WRAPPER_JAR% (
- if "%MVNW_VERBOSE%" == "true" (
- echo Found %WRAPPER_JAR%
- )
-) else (
- if not "%MVNW_REPOURL%" == "" (
- SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar"
- )
- if "%MVNW_VERBOSE%" == "true" (
- echo Couldn't find %WRAPPER_JAR%, downloading it ...
- echo Downloading from: %WRAPPER_URL%
- )
-
- powershell -Command "&{"^
- "$webclient = new-object System.Net.WebClient;"^
- "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
- "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
- "}"^
- "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^
- "}"
- if "%MVNW_VERBOSE%" == "true" (
- echo Finished downloading %WRAPPER_JAR%
- )
-)
-@REM End of extension
-
-@REM If specified, validate the SHA-256 sum of the Maven wrapper jar file
-SET WRAPPER_SHA_256_SUM=""
-FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
- IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B
-)
-IF NOT %WRAPPER_SHA_256_SUM%=="" (
- powershell -Command "&{"^
- "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^
- "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^
- " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^
- " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^
- " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^
- " exit 1;"^
- "}"^
- "}"
- if ERRORLEVEL 1 goto error
-)
-
-@REM Provide a "standardized" way to retrieve the CLI args that will
-@REM work with both Windows and non-Windows executions.
-set MAVEN_CMD_LINE_ARGS=%*
-
-%MAVEN_JAVA_EXE% ^
- %JVM_CONFIG_MAVEN_PROPS% ^
- %MAVEN_OPTS% ^
- %MAVEN_DEBUG_OPTS% ^
- -classpath %WRAPPER_JAR% ^
- "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^
- %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
-if ERRORLEVEL 1 goto error
-goto end
-
-:error
-set ERROR_CODE=1
-
-:end
-@endlocal & set ERROR_CODE=%ERROR_CODE%
-
-if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost
-@REM check for post script, once with legacy .bat ending and once with .cmd ending
-if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat"
-if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd"
-:skipRcPost
-
-@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
-if "%MAVEN_BATCH_PAUSE%"=="on" pause
-
-if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE%
-
-cmd /C exit /B %ERROR_CODE%
diff --git a/karavan-cloud/karavan-datagrid/pom.xml b/karavan-cloud/karavan-datagrid/pom.xml
deleted file mode 100644
index 4487130b..00000000
--- a/karavan-cloud/karavan-datagrid/pom.xml
+++ /dev/null
@@ -1,175 +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.
--->
-<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"
- xmlns="http://maven.apache.org/POM/4.0.0"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <modelVersion>4.0.0</modelVersion>
- <artifactId>karavan-datagrid</artifactId>
- <parent>
- <groupId>org.apache.camel.karavan</groupId>
- <artifactId>karavan-cloud</artifactId>
- <version>3.21.1-SNAPSHOT</version>
- <relativePath>../pom.xml</relativePath>
- </parent>
-
- <dependencies>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-arc</artifactId>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-jackson</artifactId>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-infinispan-client</artifactId>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-vertx</artifactId>
- </dependency>
- <dependency>
- <groupId>io.quarkus</groupId>
- <artifactId>quarkus-junit5</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>io.rest-assured</groupId>
- <artifactId>rest-assured</artifactId>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
- <build>
- <resources>
- <resource>
- <directory>src/main/resources</directory>
- <filtering>true</filtering>
- <includes>
- <include>**/**.xml</include>
- </includes>
- </resource>
- <resource>
- <directory>target/classes/proto</directory>
- <filtering>true</filtering>
- <includes>
- <include>karavan.proto</include>
- </includes>
- </resource>
- </resources>
- <plugins>
- <plugin>
- <groupId>io.smallrye</groupId>
- <artifactId>jandex-maven-plugin</artifactId>
- <version>${jandex-maven-plugin-version}</version>
- <executions>
- <execution>
- <id>make-index</id>
- <goals>
- <goal>jandex</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>${quarkus.platform.group-id}</groupId>
- <artifactId>quarkus-maven-plugin</artifactId>
- <version>${quarkus.platform.version}</version>
- <extensions>true</extensions>
- <executions>
- <execution>
- <goals>
- <goal>build</goal>
- <goal>generate-code</goal>
- <goal>generate-code-tests</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>${compiler-plugin.version}</version>
- <configuration>
- <parameters>${maven.compiler.parameters}</parameters>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>${surefire-plugin.version}</version>
- <configuration>
- <systemPropertyVariables>
- <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
- <maven.home>${maven.home}</maven.home>
- </systemPropertyVariables>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- </plugin>
- </plugins>
- </build>
- <profiles>
- <profile>
- <id>native</id>
- <activation>
- <property>
- <name>native</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <artifactId>maven-failsafe-plugin</artifactId>
- <version>${surefire-plugin.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>integration-test</goal>
- <goal>verify</goal>
- </goals>
- <configuration>
- <systemPropertyVariables>
- <native.image.path>${project.build.directory}/${project.build.finalName}-runner</native.image.path>
- <java.util.logging.manager>org.jboss.logmanager.LogManager</java.util.logging.manager>
- <maven.home>${maven.home}</maven.home>
- </systemPropertyVariables>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <properties>
- <quarkus.package.type>native</quarkus.package.type>
- </properties>
- </profile>
- </profiles>
- <repositories>
- <repository>
- <id>apache.snapshots</id>
- <name>Apache Development Snapshot Repository</name>
- <url>https://repository.apache.org/content/repositories/snapshots/</url>
- <releases>
- <enabled>false</enabled>
- </releases>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- </repository>
- </repositories>
-</project>
diff --git a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/LogLine.java b/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/LogLine.java
deleted file mode 100644
index 24f997c4..00000000
--- a/karavan-cloud/karavan-datagrid/src/main/java/org/apache/camel/karavan/datagrid/model/LogLine.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package org.apache.camel.karavan.datagrid.model;
-
-import org.infinispan.protostream.annotations.ProtoFactory;
-import org.infinispan.protostream.annotations.ProtoField;
-
-public class LogLine {
-
- public static final String CACHE = "log-lines";
- @ProtoField(number = 1)
- String line;
-
- @ProtoFactory
-
- public LogLine(String line) {
- this.line = line;
- }
-}
diff --git a/karavan-cloud/karavan-datagrid/src/main/resources/application.properties b/karavan-cloud/karavan-datagrid/src/main/resources/application.properties
deleted file mode 100644
index d0c22e27..00000000
--- a/karavan-cloud/karavan-datagrid/src/main/resources/application.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-
-# Infinispan Server address
-#quarkus.infinispan-client.hosts=infinispan:11222
-quarkus.infinispan-client.username=admin
-quarkus.infinispan-client.password=karavan
-
-quarkus.infinispan-client.devservices.enabled=true
-quarkus.infinispan-client.devservices.service-name=infinispan
-quarkus.infinispan-client.devservices.image-name=quay.io/infinispan/server:14.0.6.Final
-quarkus.infinispan-client.devservices.port=11222
-quarkus.infinispan-client.health.enabled=false
-
-# Infinispan client intelligence
-# Use BASIC as a Docker for Mac workaround
-quarkus.infinispan-client.client-intelligence=BASIC
diff --git a/karavan-cloud/karavan-datagrid/src/test/resources/application.properties b/karavan-cloud/karavan-datagrid/src/test/resources/application.properties
deleted file mode 100644
index c721bbf1..00000000
--- a/karavan-cloud/karavan-datagrid/src/test/resources/application.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-# Infinispan Server address
-#quarkus.infinispan-client.hosts=infinispan:11222
-quarkus.infinispan-client.username=admin
-quarkus.infinispan-client.password=password
-
-quarkus.infinispan-client.devservices.enabled=true
-quarkus.infinispan-client.devservices.service-name=infinispan
-quarkus.infinispan-client.devservices.image-name=quay.io/infinispan/server:14.0.6.Final
-quarkus.infinispan-client.devservices.port=11222
-quarkus.infinispan-client.health.enabled=false
-
-# Infinispan client intelligence
-# Use BASIC as a Docker for Mac workaround
-quarkus.infinispan-client.client-intelligence=BASIC
diff --git a/karavan-cloud/pom.xml b/karavan-cloud/pom.xml
index c54f9c61..a16e9e97 100644
--- a/karavan-cloud/pom.xml
+++ b/karavan-cloud/pom.xml
@@ -45,8 +45,6 @@
<modules>
<module>karavan-cli</module>
- <module>karavan-datagrid</module>
- <module>karavan-bashi</module>
<module>karavan-app</module>
<module>karavan-operator</module>
</modules>