webhook url return 404

Dear Sir,

I created a new project ‘X’, and copied source code from sub project ‘connectors-e2e-test-http’ in https://github.com/camunda/connectors/archive/refs/tags/8.3.1.zip to this new project ‘X’.

In project ‘X’, I run the unit test case ‘HttpTest.java::successfulWebhookModelRun()’ and ‘HttpTest.java::successfulModelRun()’ using embedded zeebe and connectors, it succeed. The configuration is quite the same as the original ‘HttpTest.java’ in connectors-8.3.1.zip, as below:

@SpringBootTest(
classes = {TestConnectorRuntimeApplication.class},
properties = {
“spring.main.allow-bean-definition-overriding=true”,
“camunda.connector.webhook.enabled=true”,
“camunda.connector.polling.enabled=true”
},
webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@ZeebeSpringTest

Then, I copied into project ‘X’ the camunda-platform/docker-compose-core.yaml at 2ee4db991ac7b0efaaa5dc6dbf26cf79ab3508fb · camunda/camunda-platform · GitHub and ‘.env’, and use DockerComposeContainer to start TestContainers in unit test, and copied HttpTest.java to HttpTest_2.java and revised HttpTest_2.java to take use of the services started by DockerComposeContainer. The unit test result is, ‘HttpTest_2.java::successfulModelRun()’ succeed but ‘HttpTest_2.java::successfulWebhookModelRun()’ failed. The log is:

> Line 1468: 14:12:41.759 [docker-java-stream--1572059029] INFO connectors -- STDOUT: 2023-12-09T04:11:25.500Z  INFO 1 --- [pool-2-thread-7] i.c.c.r.c.outbound.ConnectorJobHandler   : Received job: 2251799813685281 for tenant: <default>

Line 1470: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: 2023-12-09T04:11:25.524Z ERROR 1 — [pool-2-thread-7] i.c.c.r.c.outbound.ConnectorJobHandler : Exception while processing job: 2251799813685281 for tenant:
Line 1471: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT:
Line 1475: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: io.camunda.connector.api.error.ConnectorException: 404
Line 1477: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: POST http://localhost:8080/inbound/test-webhook
Line 1478: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpInteractionService.executeHttpRequest(HttpInteractionService.java:77)
Line 1480: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpService.executeRequestDirectly(HttpService.java:82)
Line 1481: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpService.executeConnectorRequest(HttpService.java:52)
Line 1482: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.rest.HttpJsonFunction.execute(HttpJsonFunction.java:79)
Line 1483: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.runtime.core.outbound.ConnectorJobHandler.handle(ConnectorJobHandler.java:105)
Line 1484: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.runtime.outbound.jobhandling.SpringConnectorJobHandler.lambda$handle$0(SpringConnectorJobHandler.java:75)
Line 1486: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.micrometer.core.instrument.AbstractTimer.record(AbstractTimer.java:247)
Line 1487: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.zeebe.spring.client.actuator.MicrometerMetricsRecorder.executeWithTimer(MicrometerMetricsRecorder.java:52)
Line 1489: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.runtime.outbound.jobhandling.SpringConnectorJobHandler.handle(SpringConnectorJobHandler.java:66)
Line 1491: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.zeebe.client.impl.worker.JobRunnableFactoryImpl.executeJob(JobRunnableFactoryImpl.java:45)
Line 1493: 14:12:41.759 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.zeebe.client.impl.worker.JobRunnableFactoryImpl.lambda$create$0(JobRunnableFactoryImpl.java:40)
Line 1494: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
Line 1495: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
Line 1497: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
Line 1498: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
Line 1499: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
Line 1500: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at java.base/java.lang.Thread.run(Unknown Source)
Line 1501: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: Caused by: com.google.api.client.http.HttpResponseException: 404
Line 1502: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: POST http://localhost:8080/inbound/test-webhook
Line 1503: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at com.google.api.client.http.HttpResponseException$Builder.build(HttpResponseException.java:293)
Line 1504: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1118)
Line 1505: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpInteractionService.executeHttpRequest(HttpInteractionService.java:63)
Line 1506: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: … 16 common frames omitted
Line 1507: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT:
Line 1508: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: 2023-12-09T04:11:25.569Z INFO 1 — [pool-2-thread-9] i.c.c.r.c.outbound.ConnectorJobHandler : Received job: 2251799813685281 for tenant:
Line 1509: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: 2023-12-09T04:11:25.586Z ERROR 1 — [pool-2-thread-9] i.c.c.r.c.outbound.ConnectorJobHandler : Exception while processing job: 2251799813685281 for tenant:
Line 1510: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT:
Line 1511: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: io.camunda.connector.api.error.ConnectorException: 404
Line 1512: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: POST http://localhost:8080/inbound/test-webhook
Line 1513: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpInteractionService.executeHttpRequest(HttpInteractionService.java:77)
Line 1514: 14:12:41.760 [docker-java-stream–1572059029] INFO connectors – STDOUT: at io.camunda.connector.http.base.services.HttpService.executeRequestDirectly(HttpService.java:82)

And I breakpoint the unit test in IDEA, use browser to connect to the Operate, got a screen shot as below:

Is url ‘http://localhost:8080/inbound/test-webhook’ not right when using docker-compose? How to list all the urls listened by connector for some webhook?

Good day, @kerler!

Welcome to the community!

Could you please check whether the webhook process definition was even deployed by fetching http://<connectors-host>:<connectors-port>/inbound/test-webhook?