[
https://issues.apache.org/jira/browse/CAMEL-21794?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17944436#comment-17944436
]
Marat Gubaidullin commented on CAMEL-21794:
-------------------------------------------
Same issue in 4.10.3
Example
{code:java}
- route:
id: route-d613
nodePrefixId: route-b37
from:
id: from-5523
uri: jms
parameters:
destinationName: xxx
connectionFactory: "#bean:eventsFactoryBean"
clientId: client2
steps:
- log:
id: log-7cca
message: ${body}
- beans:
- name: artemisConnectionFactoryBean
type:
"#class:org.apache.activemq.artemis.jms.client.ActiveMQConnectionFactory"
properties:
brokerURL: "{{env.BROKER_URL:tcp://artemis:61616}}"
user: "{{env.BROKER_USER:artemis}}"
password: "{{env.BROKER_PASSWORD:artemis}}"
- name: eventsFactoryBean
type: "#class:org.messaginghub.pooled.jms.JmsPoolConnectionFactory"
properties:
connectionFactory: "#bean:artemisConnectionFactoryBean"
maxSessionsPerConnection: 500
maxIdleSessionsPerConnection: 500
connectionIdleTimeout: 30000
{code}
> camel-jbang - Export bean with lazy-bean should not initialize the bean if
> not needed
> -------------------------------------------------------------------------------------
>
> Key: CAMEL-21794
> URL: https://issues.apache.org/jira/browse/CAMEL-21794
> Project: Camel
> Issue Type: Bug
> Components: camel-jbang
> Affects Versions: 4.8.3, 4.10.0
> Reporter: Claus Ibsen
> Assignee: Claus Ibsen
> Priority: Major
> Fix For: 4.10.1, 4.11.0
>
>
> If you export a bean with Artemis broker then it initailizes the bean and
> Artemis fails when calling setBroker as it does some validation in their
> setter :(
> {code:java}
> - route:
> id: route-92b5
> nodePrefixId: route-8c8
> from:
> id: from-2ffb
> uri: timer
> steps:
> - log:
> id: log-82a7
> message: ${body}
> - beans:
> - name: JMSArtemis
> type:
> "#class:org.apache.activemq.artemis.jms.client.ActiveMQConnectionFactory"
> properties:
> brokerURL: "{{secret:artemis/brokerURL}}"
> user: "{{secret:artemis/user}}"
> password: "{{secret:artemis/password}}" {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)