Help for use REGX subscribe to multiple topics.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Help for use REGX subscribe to multiple topics.

Samir Anand
Hi,

I am using camel-kafka version 2.23.1 for one of our requirement. But our team is facing one issue.
I am trying to use the regular expression to subscribe to multiple topics. I am appending param (topicIsPattern=true) to endpoint uri, as per doc.
But somehow that is not working. If I use regx in topic selection it is not able to consume.

Note: Comma separated topic selection is working fine.

Please let me know if anything is missing, or if any other thing is required to make this work.

Thanks & Regards,
Samir

::DISCLAIMER::
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. E-mail transmission is not guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or may contain viruses in transmission. The e mail and its contents (with or without referred errors) shall therefore not attach any liability on the originator or HCL or its affiliates. Views or opinions, if any, presented in this email are solely those of the author and may not necessarily reflect the views or opinions of HCL or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of this message without the prior written consent of authorized representative of HCL is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately. Before opening any email and/or attachments, please check them for viruses and other defects.
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Reply | Threaded
Open this post in threaded view
|

Re: Help for use REGX subscribe to multiple topics.

Jan Bednář
Hi Samir,
You can find example in this unit test
https://github.com/apache/camel/blob/camel-2.23.x/components/camel-kafka/src/test/java/org/apache/camel/component/kafka/KafkaConsumerTopicIsPatternTest.java

Dne 7.8.2019 v 15:21 Samir Anand napsal(a):

> Hi,
>
> I am using camel-kafka version 2.23.1 for one of our requirement. But our team is facing one issue.
> I am trying to use the regular expression to subscribe to multiple topics. I am appending param (topicIsPattern=true) to endpoint uri, as per doc.
> But somehow that is not working. If I use regx in topic selection it is not able to consume.
>
> Note: Comma separated topic selection is working fine.
>
> Please let me know if anything is missing, or if any other thing is required to make this work.
>
> Thanks & Regards,
> Samir
>
> ::DISCLAIMER::
> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
> The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. E-mail transmission is not guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or may contain viruses in transmission. The e mail and its contents (with or without referred errors) shall therefore not attach any liability on the originator or HCL or its affiliates. Views or opinions, if any, presented in this email are solely those of the author and may not necessarily reflect the views or opinions of HCL or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of this message without the prior written consent of authorized representative of HCL is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately. Before opening any email and/or attachments, please check them for viruses and other defects.
> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>