Skip to content

Commit

Permalink
Add logs
Browse files Browse the repository at this point in the history
  • Loading branch information
pierre-yves-monnet committed Aug 19, 2024
1 parent 1d25b7f commit c4a75b3
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 20 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -344,23 +344,23 @@ mvn clean install
````
Now, create a docker image
````
docker build -t pierre-yves-monnet/processautomator:1.6.0 .
docker build -t pierre-yves-monnet/processautomator:1.7.0 .
````
Push the image to the Camunda hub (you must be login first to the docker registry)
````
docker tag pierre-yves-monnet/processautomator:1.6.0 ghcr.io/camunda-community-hub/process-execution-automator:1.6.0
docker push ghcr.io/camunda-community-hub/process-execution-automator:1.6.0
docker tag pierre-yves-monnet/processautomator:1.7.0 ghcr.io/camunda-community-hub/process-execution-automator:1.7.0
docker push ghcr.io/camunda-community-hub/process-execution-automator:1.7.0
````
Tag as the latest:
````
docker tag pierre-yves-monnet/processautomator:1.6.0 ghcr.io/camunda-community-hub/process-execution-automator:latest
docker tag pierre-yves-monnet/processautomator:1.7.0 ghcr.io/camunda-community-hub/process-execution-automator:latest
docker push ghcr.io/camunda-community-hub/process-execution-automator:latest
````
Expand Down
4 changes: 3 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@
<groupId>org.camunda.community.automator</groupId>
<artifactId>process-execution-automator</artifactId>

<version>1.6.0</version>
<version>1.7.0</version>
<!-- Change the banner.txt version -->
<!-- 1.5 Change OperateClient / TaskList Library -->
<!-- 1.6 Increase option multithreading-->
<!-- 1.7 add logs -->

<properties>
<java.version>17</java.version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,12 @@ public RegisteredTask registerServiceTask(String workerId,
}
RegisteredTask registeredTask = new RegisteredTask();

logger.info("Create worker[{}] Topic[{}] StreamEnabled[{}] LockTime[{}] WorkerExecutionThreads[{}] MaxJobsActive[{}]", // label
workerId,topic,streamEnabled,lockTime,
serverDefinition.workerExecutionThreads,
serverDefinition.workerMaxJobsActive);


JobWorkerBuilderStep1.JobWorkerBuilderStep3 step3 = zeebeClient.newWorker()
.jobType(topic)
.handler((JobHandler) jobHandler)
Expand Down Expand Up @@ -891,7 +897,9 @@ else if (BpmnEngineList.CamundaEngine.CAMUNDA_8.equals(this.typeCamundaEngine))
analysis.append("] ");
if (serverDefinition.workerMaxJobsActive == -1) {
serverDefinition.workerMaxJobsActive = serverDefinition.workerExecutionThreads;
analysis.append("No workerMaxJobsActive defined, align to the number of threads, ");
analysis.append("No workerMaxJobsActive defined, align to ExecutionThread[");
analysis.append(serverDefinition.workerExecutionThreads);
analysis.append("]");
}
if (serverDefinition.workerExecutionThreads > serverDefinition.workerMaxJobsActive) {
logger.error(
Expand Down
32 changes: 19 additions & 13 deletions src/main/resources/application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ automator:
- type: "camunda7"
name: "camunda7Emeraud"
url: "http://localhost:8080/engine-rest"
workerMaxJobsActive: 20
workerMaxJobsActive: 1

- type: "camunda8"
description: "Simple authentication"
Expand All @@ -56,8 +56,9 @@ automator:
taskListUserName: "demo"
taskListUserPassword: "demo"
taskListUrl: "http://localhost:8082"
workerExecutionThreads: 10
workerMaxJobsActive: 10
workerExecutionThreads: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1

- type: "camunda8"
name: "Camunda8Lazuli"
Expand All @@ -82,21 +83,24 @@ automator:
taskListUrl: "http://localhost:8082"
taskListKeycloakUrl: "http://localhost:18080/auth/realms/camunda-platform"

workerExecutionThreads: 10
workerMaxJobsActive: 10
workerExecutionThreads: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1

- type: "camunda8"
name: "Camunda8ZeebeOnly"
zeebeGatewayAddress: "127.0.0.1:26500"
zeebePlainText: true
workerExecutionThreads: 10
workerMaxJobsActive: 10
workerExecutionThreads: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1


- type: "camunda8saas"
name: "Camunda8Grena"
workerExecutionThreads: 10
workerMaxJobsActive: 10
workerExecutionThreads: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1

region: "jfk-1"
clusterId: "b16d70cb-b654-4d76-a3a4-d4e438e4447c"
Expand All @@ -119,7 +123,7 @@ automator:
camunda7:
name: "Camunda7Granit"
url: "http://localhost:8080/engine-rest"
workerMaxJobsActive: 20
workerMaxJobsActive: 1

camunda8:
name: "Camunda8Calcair"
Expand All @@ -131,12 +135,14 @@ automator:
taskListUserName: "demo"
taskListUserPassword: "demo"
workerExecutionThreads: 200
workerMaxJobsActive: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1

camunda8Saas:
name: "Camunda8Marbble"
workerExecutionThreads: 10
workerMaxJobsActive: 10
workerExecutionThreads: 200
# -1 means : align the jobsActive to the workerExecutionThreads
workerMaxJobsActive: -1

operateUserName: "demo"
operateUserPassword: "demo"
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/banner.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ __________ __
|____| |__| \____/ \___ >___ >____ >____ > (____ /____/ |__| \____/|__|_| (____ /__| \____/|__|
\/ \/ \/ \/ \/ \/ \/

(v1.6.0)
(v1.7.0)

0 comments on commit c4a75b3

Please sign in to comment.