You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "davsclaus (via GitHub)" <gi...@apache.org> on 2026/07/15 10:18:33 UTC
[PR] CAMEL-24066: Fix SpringScheduledPollConsumerScheduler ignoring startScheduler=false [camel]
davsclaus opened a new pull request, #24712:
URL: https://github.com/apache/camel/pull/24712
## Summary
- Fix `SpringScheduledPollConsumerScheduler` violating the `ScheduledPollConsumerScheduler` SPI contract by scheduling the cron task in `doStart()` instead of `startScheduler()`
- Move `taskScheduler.schedule(runnable, trigger)` from `doStart()` to `startScheduler()` with an idempotent guard, aligning with `DefaultScheduledPollConsumerScheduler`
- Fix `isSchedulerStarted()` to check actual scheduling state (`future != null && !future.isCancelled()`) instead of executor liveness
## What was wrong
The Spring scheduler implementation scheduled the cron trigger unconditionally inside `doStart()`, which is called via `ServiceHelper.startService(scheduler)` **before** the `isStartScheduler()` gate in `ScheduledPollConsumer.doStart()`. This meant `startScheduler=false` was silently ignored — the cron started firing as soon as the route started.
This affected file, FTP, SFTP, SMB consumers and `GenericFilePollingConsumer` (`pollEnrich()`) when combined with `scheduler=spring`, as they set `startScheduler=false` internally.
## Test plan
- [x] New test verifies `startScheduler=false` prevents polling with `scheduler=spring`
- [x] Existing `FileConsumerSpringSchedulerTest` still passes (normal scheduling works)
Follow-up: [CAMEL-24079](https://issues.apache.org/jira/browse/CAMEL-24079) — Quartz scheduler has the same structural pattern.
_Claude Code on behalf of davsclaus_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-24066: Fix SpringScheduledPollConsumerScheduler ignoring startScheduler=false [camel]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #24712:
URL: https://github.com/apache/camel/pull/24712#issuecomment-4980468132
<!-- ci-tested-modules -->
:test_tube: **CI tested the following changed modules:**
- `components/camel-spring-parent/camel-spring-xml`
- `components/camel-spring-parent/camel-spring`
> :information_source: Dependent modules were not tested because the total number of affected modules exceeded the threshold (50). Use the `test-dependents` label to force testing all dependents.
---
<details><summary>:microscope: Scalpel shadow comparison — Scalpel: 233 tested, 29 compile-only — current: 233 all tested</summary>
[Maveniverse Scalpel](https://github.com/maveniverse/scalpel) detected **262 affected modules** (current approach: 233).
<details><summary>:warning: Modules only in Scalpel (29)</summary>
- `apache-camel`
- `camel-allcomponents`
- `camel-catalog`
- `camel-catalog-console`
- `camel-catalog-lucene`
- `camel-catalog-maven`
- `camel-catalog-suggest`
- `camel-componentdsl`
- `camel-csimple-maven-plugin`
- `camel-endpointdsl`
- `camel-endpointdsl-support`
- `camel-itest`
- `camel-jbang-core`
- `camel-jbang-it`
- `camel-jbang-main`
- `camel-jbang-plugin-edit`
- `camel-jbang-plugin-generate`
- `camel-jbang-plugin-kubernetes`
- `camel-jbang-plugin-test`
- `camel-kamelet-main`
- `camel-launcher`
- `camel-report-maven-plugin`
- `camel-route-parser`
- `camel-yaml-dsl`
- `camel-yaml-dsl-deserializers`
- `camel-yaml-dsl-maven-plugin`
- `coverage`
- `docs`
- `dummy-component`
</details>
**Skip-tests mode would test 233 modules** (2 direct + 231 downstream), **skip tests for 29** (generated code, meta-modules)
<details><summary>Modules Scalpel would test (233)</summary>
- `camel-a2a`
- `camel-activemq`
- `camel-activemq6`
- `camel-amqp`
- `camel-as2`
- `camel-asn1`
- `camel-atmosphere-websocket`
- `camel-avro`
- `camel-avro-rpc`
- `camel-aws-bedrock`
- `camel-aws-cloudtrail`
- `camel-aws-parameter-store`
- `camel-aws-secrets-manager`
- `camel-aws-security-hub`
- `camel-aws2-athena`
- `camel-aws2-comprehend`
- `camel-aws2-cw`
- `camel-aws2-ddb`
- `camel-aws2-ec2`
- `camel-aws2-ecs`
- `camel-aws2-eks`
- `camel-aws2-eventbridge`
- `camel-aws2-iam`
- `camel-aws2-kinesis`
- `camel-aws2-kms`
- `camel-aws2-lambda`
- `camel-aws2-mq`
- `camel-aws2-msk`
- `camel-aws2-polly`
- `camel-aws2-redshift`
- `camel-aws2-rekognition`
- `camel-aws2-s3`
- `camel-aws2-s3-vectors`
- `camel-aws2-ses`
- `camel-aws2-sns`
- `camel-aws2-sqs`
- `camel-aws2-step-functions`
- `camel-aws2-sts`
- `camel-aws2-textract`
- `camel-aws2-timestream`
- `camel-aws2-translate`
- `camel-azure-files`
- `camel-barcode`
- `camel-base64`
- `camel-beanio`
- `camel-bindy`
- `camel-caffeine`
- `camel-cbor`
- `camel-clickup`
- `camel-cm-sms`
- `camel-consul`
- `camel-crypto`
- `camel-crypto-pgp`
- `camel-csimple-joor`
- `camel-csv`
- `camel-cxf-rest`
- `camel-cxf-soap`
- `camel-cxf-spring-common`
- `camel-cxf-spring-rest`
- `camel-cxf-spring-soap`
- `camel-cxf-spring-transport`
- `camel-cxf-transport`
- `camel-datasonnet`
- `camel-dhis2`
- `camel-dns`
- `camel-dynamic-router`
- `camel-ehcache`
- `camel-exec`
- `camel-fastjson`
- `camel-fhir`
- `camel-file-watch`
- `camel-flatpack`
- `camel-fory`
- `camel-freemarker`
- `camel-ftp`
- `camel-google-sheets`
- `camel-google-vertexai`
- `camel-graphql`
- `camel-grok`
- `camel-groovy`
- `camel-gson`
- `camel-hazelcast`
- `camel-hl7`
- `camel-http`
- `camel-huaweicloud-frs`
- `camel-huaweicloud-imagerecognition`
- `camel-huaweicloud-smn`
- `camel-infinispan`
- `camel-infinispan-embedded`
- `camel-ironmq`
- `camel-iso8583`
- `camel-jackson`
- `camel-jackson-avro`
- `camel-jackson-protobuf`
- `camel-jackson3`
- `camel-jackson3-avro`
- `camel-jackson3-protobuf`
- `camel-jackson3xml`
- `camel-jacksonxml`
- `camel-jasypt`
- `camel-java-joor-dsl`
- `camel-jaxb`
- `camel-jbang-mcp`
- `camel-jbang-plugin-mcp`
- `camel-jbang-plugin-route-parser`
- `camel-jbang-plugin-tui`
- `camel-jbang-plugin-validate`
- `camel-jcache`
- `camel-jdbc`
- `camel-jetty`
- `camel-jetty-common`
- `camel-jms`
- `camel-jooq`
- `camel-jpa`
- `camel-jq`
- `camel-jsch`
- `camel-jsonapi`
- `camel-jsonb`
- `camel-jsonpath`
- `camel-jta`
- `camel-kafka`
- `camel-kamelet`
- `camel-keycloak`
- `camel-knative-http`
- `camel-kubernetes`
- `camel-langchain4j-agent`
- `camel-langchain4j-chat`
- `camel-langchain4j-embeddings`
- `camel-langchain4j-embeddingstore`
- `camel-langchain4j-tools`
- `camel-launcher-container`
- `camel-leveldb`
- `camel-lra`
- `camel-lzf`
- `camel-mail`
- `camel-mail-microsoft-oauth`
- `camel-maven-plugin`
- `camel-mdc`
- `camel-metrics`
- `camel-micrometer`
- `camel-micrometer-observability`
- `camel-micrometer-prometheus`
- `camel-microprofile-fault-tolerance`
- `camel-mina`
- `camel-minio`
- `camel-mongodb`
- `camel-mongodb-gridfs`
- `camel-neo4j`
- `camel-netty`
- `camel-netty-http`
- `camel-oaipmh`
- `camel-oauth`
- `camel-observability-services`
- `camel-observation`
- `camel-once`
- `camel-openai`
- `camel-openapi-java`
- `camel-openapi-validator`
- `camel-opentelemetry`
- `camel-opentelemetry-metrics`
- `camel-opentelemetry2`
- `camel-optaplanner`
- `camel-platform-http`
- `camel-platform-http-jolokia`
- `camel-platform-http-main`
- `camel-platform-http-vertx`
- `camel-pqc`
- `camel-protobuf`
- `camel-qdrant`
- `camel-quartz`
- `camel-quickfix`
- `camel-resilience4j`
- `camel-resilience4j-micrometer`
- `camel-rest-openapi`
- `camel-restdsl-openapi-plugin`
- `camel-salesforce`
- `camel-salesforce-codegen`
- `camel-salesforce-maven-plugin`
- `camel-sap-netweaver`
- `camel-saxon`
- `camel-servlet`
- `camel-slack`
- `camel-smpp`
- `camel-snakeyaml`
- `camel-soap`
- `camel-spring`
- `camel-spring-ai-chat`
- `camel-spring-ai-tools`
- `camel-spring-batch`
- `camel-spring-cloud-config`
- `camel-spring-jdbc`
- `camel-spring-ldap`
- `camel-spring-main`
- `camel-spring-rabbitmq`
- `camel-spring-redis`
- `camel-spring-security`
- `camel-spring-ws`
- `camel-spring-xml`
- `camel-sql`
- `camel-stax`
- `camel-swift`
- `camel-syslog`
- `camel-tarfile`
- `camel-telegram`
- `camel-telemetry`
- `camel-telemetry-dev`
- `camel-test-main-junit5`
- `camel-test-main-junit6`
- `camel-test-spring-junit5`
- `camel-test-spring-junit6`
- `camel-thrift`
- `camel-thymeleaf`
- `camel-tika`
- `camel-tracing`
- `camel-undertow`
- `camel-undertow-spring-security`
- `camel-univocity-parsers`
- `camel-velocity`
- `camel-vertx-http`
- `camel-webhook`
- `camel-whatsapp`
- `camel-xj`
- `camel-xml-io-dsl`
- `camel-xml-jaxb-dsl`
- `camel-xml-jaxb-dsl-test-definition`
- `camel-xml-jaxb-dsl-test-spring`
- `camel-xmlsecurity`
- `camel-xslt-saxon`
- `camel-yaml-dsl-validator`
- `camel-yaml-dsl-validator-maven-plugin`
- `camel-zipfile`
- `camel-zookeeper`
- `camel-zookeeper-master`
</details>
<details><summary>Modules with tests skipped (29)</summary>
- `apache-camel`
- `camel-allcomponents`
- `camel-catalog`
- `camel-catalog-console`
- `camel-catalog-lucene`
- `camel-catalog-maven`
- `camel-catalog-suggest`
- `camel-componentdsl`
- `camel-csimple-maven-plugin`
- `camel-endpointdsl`
- `camel-endpointdsl-support`
- `camel-itest`
- `camel-jbang-core`
- `camel-jbang-it`
- `camel-jbang-main`
- `camel-jbang-plugin-edit`
- `camel-jbang-plugin-generate`
- `camel-jbang-plugin-kubernetes`
- `camel-jbang-plugin-test`
- `camel-kamelet-main`
- `camel-launcher`
- `camel-report-maven-plugin`
- `camel-route-parser`
- `camel-yaml-dsl`
- `camel-yaml-dsl-deserializers`
- `camel-yaml-dsl-maven-plugin`
- `coverage`
- `docs`
- `dummy-component`
</details>
> :information_source: Shadow mode — Scalpel observes but does not affect test execution. [Learn more](https://github.com/maveniverse/scalpel)
</details>
<details><summary>Build reactor — dependencies compiled but only changed modules were tested (261 modules)</summary>
- Camel :: AI :: A2A
- Camel :: AI :: LangChain4j :: Agent
- Camel :: AI :: LangChain4j :: Chat
- Camel :: AI :: LangChain4j :: Embedding
- Camel :: AI :: LangChain4j :: EmbeddingStore
- Camel :: AI :: LangChain4j :: Tools
- Camel :: AI :: Neo4j
- Camel :: AI :: OpenAI
- Camel :: AI :: Qdrant
- Camel :: AMQP
- Camel :: AS2 :: Component
- Camel :: ASN.1
- Camel :: AWS CloudTrail
- Camel :: AWS Redshift Data
- Camel :: AWS Rekognition
- Camel :: AWS Security Hub
- Camel :: AWS Step Functions
- Camel :: AWS Timestream
- Camel :: AWS2 Athena
- Camel :: AWS2 Bedrock
- Camel :: AWS2 CW
- Camel :: AWS2 Comprehend
- Camel :: AWS2 DDB
- Camel :: AWS2 EC2
- Camel :: AWS2 ECS
- Camel :: AWS2 EKS
- Camel :: AWS2 Eventbridge
- Camel :: AWS2 IAM
- Camel :: AWS2 KMS
- Camel :: AWS2 Kinesis
- Camel :: AWS2 Lambda
- Camel :: AWS2 MQ
- Camel :: AWS2 MSK
- Camel :: AWS2 Parameter Store
- Camel :: AWS2 Polly
- Camel :: AWS2 S3
- Camel :: AWS2 S3 Vectors
- Camel :: AWS2 SES
- Camel :: AWS2 SNS
- Camel :: AWS2 SQS
- Camel :: AWS2 STS
- Camel :: AWS2 Secrets Manager
- Camel :: AWS2 Textract
- Camel :: AWS2 Translate
- Camel :: ActiveMQ 5.x
- Camel :: ActiveMQ 6.x
- Camel :: All Components Sync point
- Camel :: Assembly
- Camel :: Atmosphere WebSocket Servlet
- Camel :: Avro
- Camel :: Avro RPC
- Camel :: Azure :: Files
- Camel :: Barcode
- Camel :: Base64
- Camel :: BeanIO
- Camel :: Bindy
- Camel :: CBOR
- Camel :: CM SMS
- Camel :: CSV
- Camel :: CXF :: Common :: Spring
- Camel :: CXF :: REST
- Camel :: CXF :: REST :: Spring
- Camel :: CXF :: SOAP
- Camel :: CXF :: SOAP :: Spring
- Camel :: CXF :: Transport
- Camel :: CXF :: Transport :: Spring
- Camel :: Caffeine
- Camel :: Catalog :: CSimple Maven Plugin (deprecated)
- Camel :: Catalog :: Camel Catalog
- Camel :: Catalog :: Camel Report Maven Plugin
- Camel :: Catalog :: Camel Route Parser
- Camel :: Catalog :: Console
- Camel :: Catalog :: Dummy Component
- Camel :: Catalog :: Lucene (deprecated)
- Camel :: Catalog :: Maven
- Camel :: Catalog :: Suggest
- Camel :: ClickUp
- Camel :: Common Telemetry
- Camel :: Common Tracing (deprecated)
- Camel :: Component DSL
- Camel :: Consul
- Camel :: Coverage
- Camel :: Crypto
- Camel :: Crypto PGP
- Camel :: DHIS2
- Camel :: DNS
- Camel :: DataSonnet
- Camel :: Docs
- Camel :: Dynamic Router
- Camel :: Ehcache
- Camel :: Endpoint DSL
- Camel :: Endpoint DSL :: Support
- Camel :: Exec
- Camel :: FHIR
- Camel :: FTP
- Camel :: Fastjson
- Camel :: File Watch
- Camel :: FlatPack
- Camel :: Fory
- Camel :: Freemarker
- Camel :: Google :: Sheets
- Camel :: Google :: Vertex AI
- Camel :: GraphQL
- Camel :: Grok
- Camel :: Groovy
- Camel :: Gson
- Camel :: HL7
- Camel :: HTTP
- Camel :: HazelCast
- Camel :: Huawei Cloud :: FaceRecognition
- Camel :: Huawei Cloud :: ImageRecognition
- Camel :: Huawei Cloud :: SimpleNotification
- Camel :: ISO-8583
- Camel :: Infinispan :: Embedded
- Camel :: Infinispan :: Remote
- Camel :: Integration Tests
- Camel :: IronMQ
- Camel :: JAXB
- Camel :: JBang :: Core
- Camel :: JBang :: Integration tests
- Camel :: JBang :: MCP
- Camel :: JBang :: Main
- Camel :: JBang :: Plugin :: Edit
- Camel :: JBang :: Plugin :: Generate
- Camel :: JBang :: Plugin :: Kubernetes
- Camel :: JBang :: Plugin :: MCP
- Camel :: JBang :: Plugin :: Route Parser
- Camel :: JBang :: Plugin :: TUI
- Camel :: JBang :: Plugin :: Testing
- Camel :: JBang :: Plugin :: Validate
- Camel :: JCache
- Camel :: JDBC
- Camel :: JMS
- Camel :: JOOQ
- Camel :: JPA
- Camel :: JQ
- Camel :: JSON-B
- Camel :: JSon Path
- Camel :: JSonApi
- Camel :: JTA
- Camel :: Jackson
- Camel :: Jackson 3
- Camel :: Jackson 3 Avro
- Camel :: Jackson 3 Protobuf
- Camel :: Jackson 3 XML
- Camel :: Jackson Avro
- Camel :: Jackson Protobuf
- Camel :: Jackson XML
- Camel :: Jasypt
- Camel :: Java DSL with jOOR
- Camel :: Jetty
- Camel :: Jetty :: Common
- Camel :: Jsch
- Camel :: Kafka
- Camel :: Kamelet
- Camel :: Kamelet Main
- Camel :: Keycloak
- Camel :: Knative HTTP
- Camel :: Kubernetes
- Camel :: LZF
- Camel :: Launcher
- Camel :: Launcher :: Container
- Camel :: LevelDB (deprecated)
- Camel :: Long-Running-Action
- Camel :: MDC
- Camel :: MINA
- Camel :: Mail
- Camel :: Mail :: Microsoft OAuth
- Camel :: Maven Plugins :: Camel Maven Plugin
- Camel :: Maven Plugins :: OpenApi REST DSL Generator
- Camel :: Metrics
- Camel :: MicroProfile :: Fault Tolerance
- Camel :: Micrometer
- Camel :: Micrometer :: Observability 2
- Camel :: Micrometer :: Observation (deprecated)
- Camel :: Micrometer :: Prometheus
- Camel :: MinIO
- Camel :: MongoDB
- Camel :: MongoDB GridFS
- Camel :: Netty
- Camel :: Netty HTTP
- Camel :: OAIPMH
- Camel :: OAuth
- Camel :: Observability Services
- Camel :: Once
- Camel :: OpenAPI :: Validator
- Camel :: OpenApi Java
- Camel :: OpenTelemetry (deprecated)
- Camel :: Opentelemetry 2
- Camel :: Opentelemetry Metrics
- Camel :: OptaPlanner
- Camel :: PQC
- Camel :: Platform HTTP
- Camel :: Platform HTTP :: Jolokia
- Camel :: Platform HTTP :: Main
- Camel :: Platform HTTP :: Vert.x
- Camel :: Protobuf
- Camel :: Quartz
- Camel :: QuickFIX/J
- Camel :: REST OpenApi
- Camel :: Resilience4j
- Camel :: Resilience4j :: Micrometer
- Camel :: SAP NetWeaver
- Camel :: SMPP
- Camel :: SOAP
- Camel :: SQL
- Camel :: SWIFT
- Camel :: Salesforce
- Camel :: Salesforce :: CodeGen
- Camel :: Salesforce :: Maven Plugin
- Camel :: Saxon
- Camel :: Servlet
- Camel :: Slack
- Camel :: SnakeYAML
- Camel :: Spring
- Camel :: Spring AI :: Chat
- Camel :: Spring AI :: Tools
- Camel :: Spring Batch
- Camel :: Spring Cloud Config
- Camel :: Spring JDBC
- Camel :: Spring LDAP
- Camel :: Spring Main
- Camel :: Spring RabbitMQ
- Camel :: Spring Redis
- Camel :: Spring Security
- Camel :: Spring Web Services
- Camel :: Spring XML
- Camel :: StAX
- Camel :: Syslog
- Camel :: Tar File
- Camel :: Telegram
- Camel :: Telemetry :: Dev
- Camel :: Test :: Main :: JUnit5
- Camel :: Test :: Main :: JUnit6
- Camel :: Test :: Spring :: JUnit5
- Camel :: Thrift
- Camel :: Thymeleaf
- Camel :: Tika
- Camel :: Undertow
- Camel :: Undertow Spring Security
- Camel :: UniVocity Parsers
- Camel :: Velocity
- Camel :: Vert.x :: HTTP
- Camel :: Webhook
- Camel :: Whatsapp
- Camel :: XJ
- Camel :: XML DSL Jaxb :: Test :: Definition
- Camel :: XML DSL Jaxb :: Test :: Spring
- Camel :: XML DSL with camel-xml-io
- Camel :: XML DSL with camel-xml-jaxb
- Camel :: XML Security
- Camel :: XSLT Saxon
- Camel :: YAML DSL
- Camel :: YAML DSL :: Deserializers
- Camel :: YAML DSL :: Maven Plugins
- Camel :: YAML DSL :: Validator
- Camel :: YAML DSL :: Validator Maven Plugin
- Camel :: Zip File
- Camel :: Zookeeper
- Camel :: Zookeeper Master
- Camel :: csimple jOOR (deprecated)
</details>
---
:gear: [View full build and test results](https://github.com/apache/camel/actions/runs/29407666074)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-24066: Fix SpringScheduledPollConsumerScheduler ignoring startScheduler=false [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus merged PR #24712:
URL: https://github.com/apache/camel/pull/24712
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-24066: Fix SpringScheduledPollConsumerScheduler ignoring startScheduler=false [camel]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #24712:
URL: https://github.com/apache/camel/pull/24712#issuecomment-4979677542
:star2: Thank you for your contribution to the Apache Camel project! :star2:
:robot: CI automation will test this PR automatically.
:camel: Apache Camel Committers, please review the following items:
* First-time contributors **require MANUAL approval** for the GitHub Actions to run
* You can use the command `/component-test (camel-)component-name1 (camel-)component-name2..` to request a test from the test bot although they are normally detected and executed by CI.
* You can label PRs using `skip-tests` and `test-dependents` to fine-tune the checks executed by this PR.
* Build and test logs are available in the summary page. **Only** [Apache Camel committers](https://camel.apache.org/community/team/#committers) have access to the summary.
:warning: Be careful when sharing logs. Review their contents before sharing them publicly.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org