You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Jinyu Chen (Jira)" <ji...@apache.org> on 2026/06/16 09:17:00 UTC

[jira] [Commented] (CAMEL-23772) dataformat: endpoints ignore global camel.dataformat.* configuration in camel quarkus

    [ https://issues.apache.org/jira/browse/CAMEL-23772?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18089333#comment-18089333 ] 

Jinyu Chen commented on CAMEL-23772:
------------------------------------

Hi,

I'd appreciate any feedback on this issue and the proposed solutions. Since Camel Quarkus currently has a workaround with LifecycleStrategy, so this is a minor issue. However, I wanted to ask: Do you think either of the proposed solutions is worth implementing? or should we close this as won't-fix since the workaround exists?

Best regards,

Jinyu

> dataformat: endpoints ignore global camel.dataformat.* configuration in camel quarkus
> -------------------------------------------------------------------------------------
>
>                 Key: CAMEL-23772
>                 URL: https://issues.apache.org/jira/browse/CAMEL-23772
>             Project: Camel
>          Issue Type: Improvement
>            Reporter: Jinyu Chen
>            Priority: Minor
>
> During analysing issue [https://github.com/apache/camel-quarkus/issues/7651]
> Found Problem might caused by Camel: 
> Routes using dataformat: endpoints do not apply global camel.dataformat.* configuration from application.properties in CEQ.
> application.properties:
> _camel.dataformat.beanio.stream-name=employee-stream  camel.dataformat.beanio.mapping=employee-mapping.xml_
> This works (I think it's what CAMEL-22352 proposed to do)
>   _from("direct:test1")_
>       _.unmarshal().beanio("mapping.xml", "stream");_  // Uses global config
> This fails
>   _from("direct:test2")_
>       _.to("dataformat:beanio:unmarshal");_ Ignores global config and throw error IllegalArgumentException: Stream name not configured.
> After initial analyze, the root cause probably is DataFormatComponent.createEndpoint() calls createDataFormat() which always creates a new unconfigured instance. It never reaches the fallback resolveDataFormat() that would return the configured template.
> CAMEL-22352 fixed this for DataFormatReifier, but DataFormatComponent uses a different code path.
> Proposed Solutions:
>  * Option 1 (safer): Add copyConfigurationFromTemplate() to DataFormatComponent, similar to CAMEL-22352's fix in DataFormatReifier.configureDataFormat()
>  * Option 2 (wider impact): Add configuration copy in AbstractCamelContext.createDataFormat() to benefit all creation paths



--
This message was sent by Atlassian Jira
(v8.20.10#820010)