camunda / camunda-platform-tutorials

Step-by-step tutorials to guide Camunda Platform 8 users to certain use cases end-to-end
14 stars 22 forks source link

Unable to complete Call Microservice tutorial sample #65

Open aabuabdou opened 4 months ago

aabuabdou commented 4 months ago

Hello,

I have followed the tutorial step by step and when I was running the "Call Microservice" process from the web modeler and also the io.camunda.getstarted.tutorial.Worker spring application on JAVA 17, I get the following exception:

2024-05-21T07:04:36.530+03:00 WARN 36952 --- [pool-3-thread-1] io.camunda.zeebe.client.job.worker : Worker worker#orchestrateSomething failed to handle job with key 2251799814493507 of type orchestrate-something, sending fail command to broker

java.lang.NullPointerException: Cannot load from object array because "parameterNames" is null at io.camunda.zeebe.spring.client.bean.MethodInfo.getParameters(MethodInfo.java:72) ~[spring-client-zeebe-8.4.0.jar:8.4.0] at io.camunda.zeebe.spring.client.jobhandling.JobHandlerInvokingSpringBeans.handle(JobHandlerInvokingSpringBeans.java:48) ~[spring-client-zeebe-8.4.0.jar:8.4.0] at io.camunda.zeebe.client.impl.worker.JobRunnableFactoryImpl.executeJob(JobRunnableFactoryImpl.java:45) ~[zeebe-client-java-8.4.0.jar:8.4.0] at io.camunda.zeebe.client.impl.worker.JobRunnableFactoryImpl.lambda$create$0(JobRunnableFactoryImpl.java:40) ~[zeebe-client-java-8.4.0.jar:8.4.0] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[na:na] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[na:na] at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) ~[na:na] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[na:na] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[na:na] at java.base/java.lang.Thread.run(Thread.java:833) ~[na:na]

Anything I am missing here?

crobbins215 commented 4 months ago

Thanks for flagging @aabuabdou, I'm looking into this.

crobbins215 commented 3 months ago

@aabuabdou

It‘s will be about the compiler, spring zeebe provides you with a section about it: https://github.com/camunda-community-hub/spring-zeebe Your compiler needs the arg -parameters enabled

There are snippets on how to configure the compiler: Maven

<build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <compilerArgs>
            <arg>-parameters</arg>
          </compilerArgs>
        </configuration>
      </plugin>
    </plugins>
  </build>

Gradle:

tasks.withType(JavaCompile) {
    options.compilerArgs << '-parameters'
}

In IntelliJ: Settings > Build, Execution, Deployment > Compiler > Java Compiler

crobbins215 commented 3 months ago

@aabuabdou we have made a change to include this, can you pull the latest and try again?