Skip to content

Commit

Permalink
why would the executor by default only have 1 thread?
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanlukas committed Feb 6, 2024
1 parent e7493ee commit f7c9bf2
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import io.camunda.zeebe.spring.client.metrics.MetricsRecorder;
import io.camunda.zeebe.spring.client.properties.PropertyBasedZeebeWorkerValueCustomizer;
import io.camunda.zeebe.spring.client.properties.ZeebeClientConfigurationProperties;
import java.util.concurrent.Executors;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
Expand All @@ -37,7 +38,9 @@ public ZeebeClientAllAutoConfiguration(
@Bean
@ConditionalOnMissingBean
public ZeebeClientExecutorService zeebeClientExecutorService() {
return ZeebeClientExecutorService.createDefault();
return new ZeebeClientExecutorService(
Executors.newScheduledThreadPool(
configurationProperties.getNumJobWorkerExecutionThreads()));
}

@Bean
Expand Down

0 comments on commit f7c9bf2

Please sign in to comment.