Trying to upgrade to spring-boot-starter-camunda-sdk

I’m trying to upgrade to SDK but it keeps giving me errors.

io.camunda spring-boot-starter-camunda-sdk 8.5.9

gives “not an SSL/TLS record”

io.camunda.spring spring-boot-starter-camunda 8.5.11

works normally.

The documentation is horrible on de SDK.
Anyone know how to make it work?

Hi @mbarni,

First of all, can you attach the full log? I guess the error occurs during the startup of your spring boot application?

On first guess, it looks like an error from Netty, maybe a compatibility issue.

Best
Stefan

Hello @mbarni ,

which documentation are you refering to?

Our spring sdk has this documentation which introduces you to various configuration options:

At first glance, I would say the property zeebe.client.security.plaintext could be off.

Best regards,
Jonathan

I’m connecting to SAAS.

Why zeebe.client.security.plaintext should be off?

Hello @mbarni ,

I mean “off” in the sense of "not configured correctly.

If you want to connect to Saas and you are using the sdk, please look at the following section:

For 8.5.x: Getting started | Camunda 8 Docs

For 8.6.x: Getting started | Camunda 8 Docs

I hope this helps.

Best regards,

Jonathan

Hello.

I want to use the SDK to connect to a local Docker. “Self-Managed” confiuration does not seem to be working for me.

Hello @mbarni ,

which properties do you set and what is the log output?

Jonathan

camunda:
client:
mode: self-managed
zeebe:
enabled: true
grpc-address: http://127.0.0.1:26500
rest-address: http://127.0.0.1:8080

Error starting ApplicationContext. To display the condition evaluation report re-run your application with ‘debug’ enabled.
2025-01-16T15:18:14.130-05:00 ERROR 5640 — [ main] o.s.boot.SpringApplication : Application run failed

org.springframework.context.ApplicationContextException: Failed to start bean ‘zeebeLifecycleEventProducer’
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:288) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:472) ~[spring-context-6.1.15.jar:6.1.15]
at java.base/java.lang.Iterable.forEach(Iterable.java:75) ~[na:na]
at org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:257) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:202) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:990) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:628) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:754) ~[spring-boot-3.3.6.jar:3.3.6]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:456) ~[spring-boot-3.3.6.jar:3.3.6]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:335) ~[spring-boot-3.3.6.jar:3.3.6]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1363) ~[spring-boot-3.3.6.jar:3.3.6]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1352) ~[spring-boot-3.3.6.jar:3.3.6]
at io.camunda.getstarted.genericWorker.Main.main(Main.java:17) ~[classes/:na]
Caused by: io.camunda.zeebe.client.api.command.ClientStatusException: Network closed for unknown reason
at io.camunda.zeebe.client.impl.ZeebeClientFutureImpl.transformExecutionException(ZeebeClientFutureImpl.java:116) ~[zeebe-client-java-8.6.7.jar:8.6.7]
at io.camunda.zeebe.client.impl.ZeebeClientFutureImpl.join(ZeebeClientFutureImpl.java:54) ~[zeebe-client-java-8.6.7.jar:8.6.7]
at io.camunda.zeebe.spring.client.annotation.processor.ZeebeDeploymentAnnotationProcessor.lambda$start$6(ZeebeDeploymentAnnotationProcessor.java:86) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at java.base/java.util.ArrayList.forEach(ArrayList.java:1596) ~[na:na]
at io.camunda.zeebe.spring.client.annotation.processor.ZeebeDeploymentAnnotationProcessor.start(ZeebeDeploymentAnnotationProcessor.java:63) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at io.camunda.zeebe.spring.client.annotation.processor.ZeebeAnnotationProcessorRegistry.lambda$startAll$0(ZeebeAnnotationProcessorRegistry.java:54) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at java.base/java.util.ArrayList.forEach(ArrayList.java:1596) ~[na:na]
at io.camunda.zeebe.spring.client.annotation.processor.ZeebeAnnotationProcessorRegistry.startAll(ZeebeAnnotationProcessorRegistry.java:54) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at io.camunda.zeebe.spring.client.event.ZeebeClientEventListener.handleStart(ZeebeClientEventListener.java:32) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) ~[na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:580) ~[na:na]
at org.springframework.context.event.ApplicationListenerMethodAdapter.doInvoke(ApplicationListenerMethodAdapter.java:365) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.event.ApplicationListenerMethodAdapter.processEvent(ApplicationListenerMethodAdapter.java:237) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.event.ApplicationListenerMethodAdapter.onApplicationEvent(ApplicationListenerMethodAdapter.java:168) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:185) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:178) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:156) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:452) ~[spring-context-6.1.15.jar:6.1.15]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:385) ~[spring-context-6.1.15.jar:6.1.15]
at io.camunda.zeebe.spring.client.event.ZeebeLifecycleEventProducer.start(ZeebeLifecycleEventProducer.java:38) ~[spring-boot-starter-camunda-sdk-8.6.7.jar:8.6.7]
at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:285) ~[spring-context-6.1.15.jar:6.1.15]
… 12 common frames omitted
Caused by: java.util.concurrent.ExecutionException: io.grpc.StatusRuntimeException: UNAVAILABLE: Network closed for unknown reason
at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396) ~[na:na]
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2073) ~[na:na]
at io.camunda.zeebe.client.impl.ZeebeClientFutureImpl.join(ZeebeClientFutureImpl.java:52) ~[zeebe-client-java-8.6.7.jar:8.6.7]
… 31 common frames omitted
Caused by: io.grpc.StatusRuntimeException: UNAVAILABLE: Network closed for unknown reason
at io.grpc.Status.asRuntimeException(Status.java:532) ~[grpc-api-1.68.1.jar:1.68.1]
at io.grpc.stub.ClientCalls$StreamObserverToCallListenerAdapter.onClose(ClientCalls.java:481) ~[grpc-stub-1.68.1.jar:1.68.1]
at io.grpc.internal.DelayedClientCall$DelayedListener$3.run(DelayedClientCall.java:489) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.DelayedClientCall$DelayedListener.delayOrExecute(DelayedClientCall.java:453) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.DelayedClientCall$DelayedListener.onClose(DelayedClientCall.java:486) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.ClientCallImpl.closeObserver(ClientCallImpl.java:564) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.ClientCallImpl.access$100(ClientCallImpl.java:72) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInternal(ClientCallImpl.java:729) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInContext(ClientCallImpl.java:710) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.ContextRunnable.run(ContextRunnable.java:37) ~[grpc-core-1.68.1.jar:1.68.1]
at io.grpc.internal.SerializingExecutor.run(SerializingExecutor.java:133) ~[grpc-core-1.68.1.jar:1.68.1]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[na:na]
at java.base/java.lang.Thread.run(Thread.java:1583) ~[na:na]

Disconnected from the target VM, address: ‘127.0.0.1:62990’, transport: ‘socket’

Process finished with exit code 1

I’m pretty sure no one tests this things. It’s baffling how we Camunda 8 developers struggle.

Hello @mbarni ,

in fact, this is my daily business working with the software and I can confirm that this configuration works for me.

I am using http://localhost:8080 as rest address but this should not make any difference…

Are you able to call the rest api from any other client like postman?

Best regards,

Jonathan

Using only:

camunda:
  client:
    mode: self-managed

And removing the following part makes it work:

zeebe:
  enabled: true
  grpc-address: http://127.0.0.1:26500
  rest-address: http://127.0.0.1:8080

I have zero changes to the ports. I’m running Docker in Windows. Using this “default” addresses in the YML does not work. Removing them makes the connection work.

Hi @mbarni ,

very interesting. In fact, your client is now client the properties from this file on startup:

I am happy for you :slight_smile:

Best regards,
Jonathan

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.