davsclaus opened a new pull request, #29726:
URL: https://github.com/apache/camel/pull/29726

   [CAMEL-26325](https://issues.apache.org/jira/browse/CAMEL-26325): `camel 
export` now adds the component of the delegate endpoint of a `webhook:` 
endpoint, e.g. camel-telegram for `webhook:telegram:bots`.
   
   ## Cause
   
   During export every endpoint is a stub, so 
`WebhookEndpoint.afterPropertiesConfigured` never runs and never creates its 
delegate endpoint. The delegate's component then never reaches the dependency 
resolver. CAMEL-25186 (`master:`) and CAMEL-26116 (`zookeeper-master:`, #28489) 
fixed the same gap.
   
   ## Fix
   
   `DownloadEndpointStrategy` (camel-kamelet-main) resolves the delegate of a 
stubbed `webhook:` endpoint during export, as it does for `master:` and 
`zookeeper-master:`. The delegate URI is taken as 
`WebhookComponent.createEndpoint` takes it: the part after `webhook:`, with its 
query.
   - The webhook options go along in the query. That is harmless, because the 
delegate is a stub as well, and `StubEndpoint` accepts any property.
   - `camel run` is not affected: there the real `WebhookEndpoint` creates its 
delegate, and the downloader fetches its component.
   
   ## Tests
   
   - `ExportTest.shouldExportWebhookDelegate` covers main, spring-boot and 
quarkus, with the route from the JIRA.
   - Without the fix it fails on the missing telegram dependency.
   - With the fix, the master, zookeeper-master and webhook delegate tests pass 
(9/9), and so does the whole `ExportTest` (164/164).
   - Camel Quarkus has no webhook extension, so the Quarkus case checks 
`camel-quarkus-telegram` only.
   
   _Claude Code on behalf of davsclaus_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to