apache / camel-karavan

Apache Camel Karavan a Low-code Data Integration Platform
https://camel.apache.org
Apache License 2.0
436 stars 146 forks source link

Failed to commit event: Unsupported environment: XXX-ENV-NAME #1363

Closed arheom closed 1 month ago

arheom commented 1 month ago

Describe the bug

In version 4.7.1-oidc, when I make a file change inside a project and I try to commit, I get the following error: Failed to commit event: Unsupported environment: XXX-ENV-NAME at at org.apache.camel.karavan.service.ProjectService.commitAndPushProject(ProjectService.java:92) at org.apache.camel.karavan.service.ProjectService_ClientProxy.commitAndPushProject(Unknown Source) at org.apache.camel.karavan.listener.CommitListener.onCommitAndPush(CommitListener.java:53)

I assume something changed from the previous versions (upgraded from 4.6.0). Not sure if it is a bug or a breaking change, that I need to change some configuration? Thanks!

Steps to reproduce the behavior

  1. Go to a project
  2. Change a file
  3. Click on push
  4. See error

Variant

Web Application

Container Management (if applicable)

Kubernetes

Operating System (if applicable)

MacOS

Version

4.7.0

Relevant log output

No response

mgubaidullin commented 1 month ago
  1. 4.7.1-oidc have never been released.
  2. KARAVAN_ENVIRONMENT should be dev
arheom commented 1 month ago

Thanks for the response! Yes, I know, but 4.7.0 did not work well, and I tried 4.7.1 and somehow the issue I was facing got solved. I will try again 4.7.0 and post here the issue I am getting. Thanks!

arheom commented 1 month ago

with 4.7.0 I am getting the following error:

2024-08-19 08:23:09,004 ERROR [io.qua.sch.com.run.StatusEmitterInvoker] (executor-thread-1) Error occurred while executing task for trigger IntervalTrigger [id=1_org.apache.camel.karavan.scheduler.DockerStatusScheduler#collectContainersStatistics, interval=5000]: java.util.concurrent.CompletionException: java.lang.RuntimeException: java.io.IOException: com.sun.jna.LastErrorException: [2] No such file or directory at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:332) at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:347) at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:874) at java.base/java.util.concurrent.CompletableFuture.uniWhenCompleteStage(CompletableFuture.java:887) at java.base/java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:2325) at java.base/java.util.concurrent.CompletableFuture$MinimalStage.whenComplete(CompletableFuture.java:2902) at io.quarkus.scheduler.common.runtime.DefaultInvoker.invoke(DefaultInvoker.java:24) at io.quarkus.scheduler.common.runtime.StatusEmitterInvoker.invoke(StatusEmitterInvoker.java:35) at io.quarkus.scheduler.common.runtime.SkipConcurrentExecutionInvoker.invoke(SkipConcurrentExecutionInvoker.java:37) at io.quarkus.scheduler.runtime.SimpleScheduler$ScheduledTask.doInvoke(SimpleScheduler.java:463) at io.quarkus.scheduler.runtime.SimpleScheduler$ScheduledTask$2.call(SimpleScheduler.java:445) at io.quarkus.scheduler.runtime.SimpleScheduler$ScheduledTask$2.call(SimpleScheduler.java:442) at io.vertx.core.impl.ContextImpl.lambda$executeBlocking$0(ContextImpl.java:178) at io.vertx.core.impl.ContextInternal.dispatch(ContextInternal.java:279) at io.vertx.core.impl.ContextImpl.lambda$internalExecuteBlocking$2(ContextImpl.java:210) at io.quarkus.vertx.core.runtime.VertxCoreRecorder$14.runWith(VertxCoreRecorder.java:604) at org.jboss.threads.EnhancedQueueExecutor$Task.doRunWith(EnhancedQueueExecutor.java:2516) at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2495) at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1521) at org.jboss.threads.DelegatingRunnable.run(DelegatingRunnable.java:11) at org.jboss.threads.ThreadLocalResettingRunnable.run(ThreadLocalResettingRunnable.java:11) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.base/java.lang.Thread.run(Thread.java:840) Caused by: java.lang.RuntimeException: java.io.IOException: com.sun.jna.LastErrorException: [2] No such file or directory at com.github.dockerjava.zerodep.ApacheDockerHttpClientImpl.execute(ApacheDockerHttpClientImpl.java:210) at com.github.dockerjava.zerodep.ZerodepDockerHttpClient.execute(ZerodepDockerHttpClient.java:8) at com.github.dockerjava.core.DefaultInvocationBuilder.execute(DefaultInvocationBuilder.java:228) at com.github.dockerjava.core.DefaultInvocationBuilder.get(DefaultInvocationBuilder.java:202) at com.github.dockerjava.core.DefaultInvocationBuilder.get(DefaultInvocationBuilder.java:74) at com.github.dockerjava.core.exec.ListContainersCmdExec.execute(ListContainersCmdExec.java:44) at com.github.dockerjava.core.exec.ListContainersCmdExec.execute(ListContainersCmdExec.java:15) at com.github.dockerjava.core.exec.AbstrSyncDockerCmdExec.exec(AbstrSyncDockerCmdExec.java:21) at com.github.dockerjava.core.command.AbstrDockerCmd.exec(AbstrDockerCmd.java:33) at org.apache.camel.karavan.docker.DockerService.getAllContainers(DockerService.java:126) at org.apache.camel.karavan.docker.DockerService_ClientProxy.getAllContainers(Unknown Source) at org.apache.camel.karavan.scheduler.DockerStatusScheduler.getContainersStatuses(DockerStatusScheduler.java:69) at org.apache.camel.karavan.scheduler.DockerStatusScheduler.collectContainersStatistics(DockerStatusScheduler.java:50) at org.apache.camel.karavan.scheduler.DockerStatusScheduler_ClientProxy.collectContainersStatistics(Unknown Source) at org.apache.camel.karavan.scheduler.DockerStatusScheduler_ScheduledInvoker_collectContainersStatistics_45dba817ce9f43d8fb12c02718dcda84f82406cb.invokeBean(Unknown Source) ... 17 more Caused by: java.io.IOException: com.sun.jna.LastErrorException: [2] No such file or directory at com.github.dockerjava.transport.DomainSocket.(DomainSocket.java:63) at com.github.dockerjava.transport.LinuxDomainSocket.(LinuxDomainSocket.java:41) at com.github.dockerjava.transport.DomainSocket.get(DomainSocket.java:140) at com.github.dockerjava.transport.UnixSocket.get(UnixSocket.java:29) at com.github.dockerjava.zerodep.ApacheDockerHttpClientImpl$2.createSocket(ApacheDockerHttpClientImpl.java:154) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:125) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:409) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:164) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:174) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ConnectExec.execute(ConnectExec.java:135) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement$1.proceed(ExecChainElement.java:57) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ProtocolExec.execute(ProtocolExec.java:172) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement$1.proceed(ExecChainElement.java:57) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.HttpRequestRetryExec.execute(HttpRequestRetryExec.java:93) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement$1.proceed(ExecChainElement.java:57) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ContentCompressionExec.execute(ContentCompressionExec.java:128) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement$1.proceed(ExecChainElement.java:57) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.RedirectExec.execute(RedirectExec.java:116) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.InternalHttpClient.doExecute(InternalHttpClient.java:178) at com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.impl.classic.CloseableHttpClient.execute(CloseableHttpClient.java:67) at com.github.dockerjava.zerodep.ApacheDockerHttpClientImpl.execute(ApacheDockerHttpClientImpl.java:206) ... 31 more Caused by: com.sun.jna.LastErrorException: [2] No such file or directory at com.github.dockerjava.transport.LinuxDomainSocket.connect(Native Method) at com.github.dockerjava.transport.LinuxDomainSocket.connect(LinuxDomainSocket.java:49) at com.github.dockerjava.transport.DomainSocket.open(DomainSocket.java:69) at com.github.dockerjava.transport.DomainSocket.(DomainSocket.java:59) ... 56 more

Any idea if this is something related to change in config?

mgubaidullin commented 1 month ago

Do you have this with 4.7.0 I am getting the following error:.... when commit?

arheom commented 1 month ago

Nope, this is when the karavan pod is starting. Every some seconds I get this exception in the logs since starting and nothing loads in the UI. I assume the git connection does not work, so it cannot read anything.

mgubaidullin commented 1 month ago

Do you have the following environment variables set?

- name: "KARAVAN_CONTAINER_STATUS_INTERVAL"
          value: "disabled"
        - name: "KARAVAN_CONTAINER_STATISTICS_INTERVAL"
          value: "disabled"