[
https://issues.apache.org/jira/browse/CAMEL-12624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16543330#comment-16543330
]
ASF GitHub Bot commented on CAMEL-12624:
----------------------------------------
dmvolod commented on issue #2425: CAMEL-12624: ActiveMQ Artemis AMQP
integration issue with topic prefix hardcoded
URL: https://github.com/apache/camel/pull/2425#issuecomment-404864833
Thanks, @oscerd . Merged.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> ActiveMQ Artemis AMQP integration issue with topic prefix hardcode
> ------------------------------------------------------------------
>
> Key: CAMEL-12624
> URL: https://issues.apache.org/jira/browse/CAMEL-12624
> Project: Camel
> Issue Type: Bug
> Components: camel-amqp
> Affects Versions: 2.21.1
> Reporter: Matt
> Priority: Minor
>
> Currently we are running Camel AMQP component against Active MQ 5 (Amazon MQ)
> we want to move to an Artemis solution but this hasn't worked seamlessly.
> In CAMEL-9204 I believe a hardcoded topic prefix of "topic://" was introduced
> I think for a workaround of an Active MQ 5 bug.
> In Artemis this means Camel connects to a topic named
> "topic://example.topic.event" instead of "example.topic.event" and therefore
> receives no events.
> The only possible workaround is to manually create the connection factory
> which means then the topic prefix is not set.
> My believe is that the hardcoded topic prefix is a bug and should be removed
> or an option to override at the AMQP component level should be introduced.
> Bug location: AMQPComponent.java line 59
> {code}
> @Override
> protected void doStart() throws Exception {
> Set<AMQPConnectionDetails> connectionDetails =
> getCamelContext().getRegistry().findByType(AMQPConnectionDetails.class);
> if (connectionDetails.size() == 1) {
> AMQPConnectionDetails details = connectionDetails.iterator().next();
> JmsConnectionFactory connectionFactory = new
> JmsConnectionFactory(details.username(), details.password(), details.uri());
> connectionFactory.setTopicPrefix("topic://");
> setConnectionFactory(connectionFactory);
> }
> super.doStart();
> }
> {code}
> Workaround:
> {code}
> @Bean
> public ConnectionFactory amqpConnectionFactory() {
> return new JmsConnectionFactory(username, password, url);
> }
> {code}
>
>
>
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)