I am trying to use Camunda 8 self -managed. I have a spring boot application set up with Zeebe client

I am trying to use Camunda 8 self -managed. I have a spring boot application set up with Zeebe client.
I get the error displayed below while starting the application.

Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.
2023-10-19 10:14:35.793 ERROR 7164 — [ main] o.s.boot.SpringApplication : Application run failed

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘processApplication’: Unsatisfied dependency expressed through field ‘client’; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘zeebeClientLifecycle’ defined in io.camunda.zeebe.spring.client.ZeebeClientSpringConfiguration: Post-processing of merged bean definition failed; nested exception is java.lang.IllegalStateException: Failed to introspect Class [io.camunda.zeebe.spring.client.lifecycle.ZeebeClientLifecycle] from ClassLoader [jdk.internal.loader.ClassLoaders$AppClassLoader@5c29bfd]
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:713) ~[spring-beans-5.3.30.jar:5.3.30]
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:693) ~[spring-beans-5.3.30.jar:5.3.30]
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119) ~[spring-beans-5.3.30.jar:5.3.30]

My Pom File ----

<?xml version="1.0" encoding="UTF-8"?>


4.0.0

<name>camunda-platform-get-started-spring</name>
<description>Camunda Platform Get Started Spring Boot Example </description>
<groupId>io.camunda.get-started</groupId>
<artifactId>camunda-platform-get-started-spring</artifactId>
<version>1.0.0-SNAPSHOT</version>

<parent>
	<groupId>org.springframework.boot</groupId>
	<artifactId>spring-boot-starter-parent</artifactId>
	<version>2.7.16</version>
	<relativePath/> <!-- lookup parent from repository -->
</parent>

<properties>
	<java.version>11</java.version>
	<spring-zeebe.version>8.1.17</spring-zeebe.version>
	<zeebe.version>8.0.5</zeebe.version>
</properties>

<dependencies>
	<dependency>
		<groupId>org.springframework.boot</groupId>
		<artifactId>spring-boot-starter</artifactId>
	</dependency>

	<dependency>
		<groupId>io.camunda</groupId>
		<artifactId>zeebe-client-java</artifactId>
		<version>${zeebe.version}</version>
	</dependency>

	<dependency>
		<groupId>io.camunda</groupId>
		<artifactId>spring-zeebe-starter</artifactId>
		<version>${spring-zeebe.version}</version>
	</dependency>

</dependencies>

<build>
	<plugins>
		<plugin>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-maven-plugin</artifactId>
		</plugin>
	</plugins>
</build>

i follow all the solution from forum but did not get any luck

Hi @Supriya ,

I think that this might be because of the versions’ incompatibility. Kindly check this, for the inter compatible versions of spring boot, zeebe and camunda versions, and try.

Also, spring-zeebe-starter dependency is now marked as legacy. Instead you should use, spring-boot-starter-camunda , and you can remove the dependency of zeebe-client-java and spring-boot-startersince they come as compile dependencies in spring-boot-starter-camunda (i.e., You can cleanup all the 3 dependencies with only one dependency spring-boot-starter-camunda). Also this helps in manual version incompatibilities.

Hope this helps you move forward.