You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "mhd-robaii (via GitHub)" <gi...@apache.org> on 2024/03/06 14:57:21 UTC
[I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
mhd-robaii opened a new issue, #5225:
URL: https://github.com/apache/camel-k/issues/5225
### What happened?
Hi everybody.
We installed camel-k 2.2.0 in our k8s gke cluster version v1.26.10-gke.1101000, kamel operator is installed and running without errors but after the build the pod starts with an error that it cannot find the "quarkus.bootstrap.runner.QuarkusEntryPoint" library
Any ideas what might be the reason for and how to fix it?
### Steps to reproduce
1. GCP Configuration
For gke configuration we followed the guide https://camel.apache.org/camel-k/2.2.x/installation/platform/gke.html and https://camel.apache.org/camel-k/2.2.x/installation/registry/gcr.html
2. Command to install camel-k
```sh
kamel install \
--olm=false \
--registry eu.gcr.io \
--organization project-id \
--registry-insecure \
--registry-secret kaniko-secret \
--build-publish-strategy Kaniko \
--log-level=debug \
-n connectors
```
3. Route Basic.java
```java
// camel-k: language=java
import org.apache.camel.builder.RouteBuilder;
public class Basic extends RouteBuilder {
@Override
public void configure() throws Exception {
from("timer:java?period=1000")
.setHeader("example")
.constant("Java")
.setBody()
.simple("Hello World! Camel K route written in ${header.example}.")
.to("log:info");
}
}
```
4. Command to execute route
```sh
kamel run Basic.java
```
5. integration kit `kubectl get ik`
```ssh
NAME ALIAS PHASE TYPE LAYOUT IMAGE ROOT
kit-cnjdgp62o7ps73dgkn70 Ready platform fast-jar eu.gcr.io/project-id/camel-k-kit-cnjdgp62o7ps73dgkn70:373506017
```
6. Integration `kubectl get integration`
```
NAME PHASE RUNTIME PROVIDER RUNTIME VERSION KIT REPLICAS
basic Error quarkus 3.2.3 kit-cnjdgp62o7ps73dgkn70 1
```
7. pods `kubectl get pods`
```ssh
NAME READY STATUS RESTARTS AGE
basic-6565b6945f-6qc4d 0/1 CrashLoopBackOff 4 (42s ago) 2m22s
camel-k-kit-cnjdgp62o7ps73dgkn70-builder 0/1 Completed 0 3m8s
camel-k-operator-5657577787-2wnfm 1/1 Running 0 3m54s
```
8. Logs route pod `kubectl logs basic-6565b6945f-6qc4d`
```ssh
exec java -cp ./resources:/etc/camel/application.properties:/etc/camel/conf.d/_resources:/etc/camel/resources:/etc/.......
Error: Could not find or load main class io.quarkus.bootstrap.runner.QuarkusEntryPoint │
│ Caused by: java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint
```
### Relevant log output
```shell
kubectl logs basic-6565b6945f-6qc4d
exec java -cp ./resources:/etc/camel/application.properties:/etc/camel/conf.d/_resources:/etc/camel/resources:/etc/.......
Error: Could not find or load main class io.quarkus.bootstrap.runner.QuarkusEntryPoint │
│ Caused by: java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint
```
### Camel K version
v2.2.0
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "mhd-robaii (via GitHub)" <gi...@apache.org>.
mhd-robaii commented on issue #5225:
URL: https://github.com/apache/camel-k/issues/5225#issuecomment-1985577527
Fixed thanks.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "mhd-robaii (via GitHub)" <gi...@apache.org>.
mhd-robaii commented on issue #5225:
URL: https://github.com/apache/camel-k/issues/5225#issuecomment-1985280046
Thanks Sergio, I would like to try Spectrum but I'm having trouble configuring it with gcp.
I followed the steps of the guide https://camel.apache.org/camel-k/next/installation/registry/gcr.html to create a new service-account and created the new secret.
`kubectl describe IntegrationPlatform camel-k`
```yaml
Name: camel-k
Namespace: connectors
Labels: app=camel-k
Annotations: camel.apache.org/operator.id: camel-k
API Version: camel.apache.org/v1
Kind: IntegrationPlatform
Metadata:
Creation Timestamp: 2024-03-07T17:52:55Z
Generation: 1
Resource Version: 375770020
UID: d76b3b72
Spec:
Build:
Build Configuration:
Maven:
Settings:
Settings Security:
Publish Strategy: Spectrum
Registry:
Address: eu.gcr.io
Insecure: true
Organization: iot-staging-3
Secret: camel-k-builder
Kamelet:
Traits:
Status:
Build:
Publish Strategy Options:
Kaniko Persistent Volume Claim: camel-k
Base Image: eclipse-temurin:17
Build Configuration:
Order Strategy: sequential
Strategy: routine
Maven:
Cli Options:
-V
--no-transfer-progress
-Dstyle.color=never
Local Repository: /etc/maven/m2
Max Running Builds: 3
Publish Strategy: Spectrum
Registry:
Address: eu.gcr.io
Insecure: true
Organization: iot-staging-3
Secret: camel-k-builder
Runtime Version: 3.2.3
Timeout: 5m0s
Cluster: Kubernetes
Conditions:
Last Transition Time: 2024-03-07T17:52:57Z
Last Update Time: 2024-03-07T17:52:57Z
Message: integration platform created
Reason: IntegrationPlatformCreated
Status: True
Type: Created
Last Transition Time: 2024-03-07T17:52:57Z
Last Update Time: 2024-03-07T17:52:57Z
Message: registry available at eu.gcr.io
Reason: IntegrationPlatformRegistryAvailable
Status: True
Type: RegistryAvailable
Info:
Git Commit: c6a9348d8467f68800dabb7c845a411765fad8e3
Go OS: linux
Go Version: go1.21.0
Kamelet:
Repositories:
Uri: none
Observed Generation: 1
Phase: Ready
Version: 2.2.0
Events: <none>
```
with spectrum as pubblisher I can't publish images on gcp because it returns an UNAUTHORIZED error
```log
Build kit-cnkvvag1vpvc73ep7grg failed: GET https://eu.gcr.io/v2/token?scope=repository%3Aiot-staging-3%2Fcamel-k-kit-cnkvvag1vpvc73ep7grg%3Apush%2Cpull&service=eu.gcr.io: UNAUTHORIZED: You don't have the needed permissions to perform this operation, and you may have invalid credentials. To authenticate your request, follow the steps in: https://cloud.google.com/container-registry/docs/advanced-authentication"
```
kamel install command that I used:
```sh
kamel install \
--olm=false \
--registry eu.gcr.io \
--organization iot-staging-3 \
--registry-insecure \
--registry-secret camel-k-builder \
--build-publish-strategy Spectrum \
--log-level=debug \
-n connectors
```
Any idea how to configure spectrum with gcp registry?
Thanks in advance.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "mhd-robaii (via GitHub)" <gi...@apache.org>.
mhd-robaii commented on issue #5225:
URL: https://github.com/apache/camel-k/issues/5225#issuecomment-1985560710
Thanks Sergio
now it works perfectly, the problem was that I created the key as generic (same as the key for kaniko).
After I download key.json from google is to join all the lines in the json into one row. For this I replaced `cat` with `paste`
```sh
kubectl create secret docker-registry camel-k-builder \
--docker-server=https://eu.gcr.io \
--docker-username=_json_key \
--docker-password="$(paste -s gcp.json)" \
--docker-email=my@email.it
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "mhd-robaii (via GitHub)" <gi...@apache.org>.
mhd-robaii closed issue #5225: Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint
URL: https://github.com/apache/camel-k/issues/5225
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "lsergio (via GitHub)" <gi...@apache.org>.
lsergio commented on issue #5225:
URL: https://github.com/apache/camel-k/issues/5225#issuecomment-1985515742
@mhd-robaii I think your issue is related to how the secret that is reference here was created:
```
Registry:
Address: eu.gcr.io
Insecure: true
Organization: iot-staging-3
Secret: camel-k-builder
```
If you have done so using a command like this:
```
kubectl create secret generic camel-k-builder --from-file=your-key.json
```
you will get the authorization error, because that is not the format that Spectrum expects.
I had the same issue and fixed it by creating the secret like below:
```
kubectl create secret docker-registry camel-k-builder \
--docker-server=gcr.io \
--docker-username=_json_key \
--docker-password="$(cat your-key.json)" \
--docker-email=any@valid.email
```
where the secret type is docker-registry and not generic.
The username and email can be any one, they're not really used, and the server should be adjusted for your registry.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Error java.lang.ClassNotFoundException: io.quarkus.bootstrap.runner.QuarkusEntryPoint [camel-k]
Posted by "lsergio (via GitHub)" <gi...@apache.org>.
lsergio commented on issue #5225:
URL: https://github.com/apache/camel-k/issues/5225#issuecomment-1981377906
@mhd-robaii take a look at this issue I opened some time ago with the same problem: https://github.com/apache/camel-k/issues/4955
You will have to switch from Kaniko to other publish strategy
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org