camel-quarkus-eventhubs using producerAsyncClient

2023-06-05 Thread Brian
Hi,

Does anyone have experience using the producerAsyncClient in camel
eventhubs? I've been trying to implement this producer instead of using
connectionstring directly in the camel uri.

My uri looks like this:

"azure-eventhubs:mynamespace/myeventhub?producerAsyncClient=#producerAsyncClient"

(I also tried using it without mynamespace/myeventhub with the same result)
and the code for the producer like this:



private static final String SERVICE_URI_POSTFIX = "servicebus.windows.net";

EventHubProducerAsyncClient eventHubProducerAsyncClient = new
EventHubClientBuilder()
.credential(getCredential())
.fullyQualifiedNamespace(eventhubProperties.eventhubNameSpace()
+ "." + SERVICE_URI_POSTFIX)
.eventHubName(eventhubProperties.eventhubName())
.buildAsyncProducerClient();
context.getRegistry().bind("producerAsyncClient",
eventHubProducerAsyncClient);

private ClientSecretCredential getCredential() {
return new ClientSecretCredentialBuilder()
.clientId(eventhubProperties.azureClientId())
.clientSecret(eventhubProperties.azureClientSecret())
.tenantId(eventhubProperties.azureTenantId())
.build();
}

But the problem I face is that when sending a message it returns this error:

2023-06-05 15:35:28,067 ERROR [rea.cor.pub.Operators]
(reactor-executor-4) Operator called default onErrorDropped:
reactor.core.Exceptions$ErrorCallbackNotImplemented:
com.azure.core.amqp.exception.AmqpException: errorContext[NAMESPACE:
null.servicebus.windows.net. ERROR CONTEXT: N/A]
Caused by: com.azure.core.amqp.exception.AmqpException:
errorContext[NAMESPACE: null.servicebus.windows.net. ERROR CONTEXT:
N/A]

It seems the namespace is null when sending.


Re: Guaranteed deliveries for spring-rabbitmq producer

2023-06-05 Thread Claus Ibsen
Hi

Take a look at CAMEL-19008 it seems maybe what you asked for

On Mon, Jun 5, 2023 at 11:45 AM Marco Cordiner  wrote:

> Hi All,
> I'm trying to setup a simple camel route (camel.springboot 3.20.4) that
> exposes a rest endpoint, sends a message to RabbitMQ using the
> spring-rabbitmq component and finally replies to the rest endpoint with the
> outcome of enqueue.
> The ko response is managed through an onException clause within the route.
> When everything is ok the route works fine.
> The problem arises when something goes wrong in the RabbitMQ operation;
> for example if the exchange doesn't exist.
> In this case, despite of this error is logged:
>
> Shutdown Signal: channel error; protocol method:
> #method(reply-code=404, reply-text=NOT_FOUND - no exchange
> 'exc-test' in vhost '/', class-id=60, method-id=40)
>
> no exception is thrown and the ruote terminates as if everything was ok.
> I couldn't find any parameter to instruct the spring-rabbitmq component to
> send back any exception to the calling route.
>
> Using the "old" rabbitmq component, I could achieve this result using the
> parameter "camel.component.rabbitmq.guaranteed-deliveries=true" but
> documentation recommends to use the Spring component instead.
>
> Is there an equivalent parameter for the spring-rabbitmq component?
>
> Regards.
> Marco
>
>
> Marco Cordiner
>
> Sytel Reply
> Via del Giorgione, 59
> 00147 - Roma - ITALY
> phone: +39 06 844341
> mobile: +39 335 1900199
> m.cordi...@reply.it
> www.reply.it
>


-- 
Claus Ibsen
-
@davsclaus
Camel in Action 2: https://www.manning.com/ibsen2


Re: Issue in resolving endpoint with property having period

2023-06-05 Thread ski n
Hi Sujeet,

Can you add the complete route, so it's clear where you are using it?

Regards,

Raymond

On Mon, Jun 5, 2023 at 3:50 PM Sujeet Singh 
wrote:

> Hi,
>
> I am trying to migrate from Camel 2.x to
> Camel 3.2.0. I have followed all the
> guidelines but getting the below error
> during startup.
>
> Caused by org.apache.camel.ResolveEndpointFailedException: Failed to
> resolve endpoint: timer://notification?fixedRate=true=5000 due to:
> Error binding property (period = 5000) with name: period on bean:
> timer://notification?fixedRate=true=5000 with  value: 5000
>
> If I remove period from above endpoint it starts working. Same thing
> happens for time, maxAge etc.
>
> Any help would be appreciated.
>
> Thanks & Regards,
> Sujeet
>


Issue in resolving endpoint with property having period

2023-06-05 Thread Sujeet Singh
Hi,

I am trying to migrate from Camel 2.x to
Camel 3.2.0. I have followed all the
guidelines but getting the below error
during startup.

Caused by org.apache.camel.ResolveEndpointFailedException: Failed to
resolve endpoint: timer://notification?fixedRate=true=5000 due to:
Error binding property (period = 5000) with name: period on bean:
timer://notification?fixedRate=true=5000 with  value: 5000

If I remove period from above endpoint it starts working. Same thing
happens for time, maxAge etc.

Any help would be appreciated.

Thanks & Regards,
Sujeet


Guaranteed deliveries for spring-rabbitmq producer

2023-06-05 Thread Marco Cordiner
Hi All,
I'm trying to setup a simple camel route (camel.springboot 3.20.4) that exposes 
a rest endpoint, sends a message to RabbitMQ using the spring-rabbitmq 
component and finally replies to the rest endpoint with the outcome of enqueue.
The ko response is managed through an onException clause within the route.
When everything is ok the route works fine.
The problem arises when something goes wrong in the RabbitMQ operation; for 
example if the exchange doesn't exist. 
In this case, despite of this error is logged:

Shutdown Signal: channel error; protocol method: 
#method(reply-code=404, reply-text=NOT_FOUND - no exchange 
'exc-test' in vhost '/', class-id=60, method-id=40)

no exception is thrown and the ruote terminates as if everything was ok.
I couldn't find any parameter to instruct the spring-rabbitmq component to send 
back any exception to the calling route.

Using the "old" rabbitmq component, I could achieve this result using the 
parameter "camel.component.rabbitmq.guaranteed-deliveries=true" but 
documentation recommends to use the Spring component instead.

Is there an equivalent parameter for the spring-rabbitmq component?

Regards.
Marco


Marco Cordiner 

Sytel Reply
Via del Giorgione, 59
00147 - Roma - ITALY 
phone: +39 06 844341
mobile: +39 335 1900199
m.cordi...@reply.it
www.reply.it


[RESULT][VOTE] Release Apache Camel Kamelets 3.20.5

2023-06-05 Thread Andrea Cosentino
Hello all,

The vote passed with the following result:

4 +1 binding votes: Andrea Cosentino, Claus Ibsen, Pasquale Congiusti and
Zineb Bendhiba

1 +1 non-binding vote: Gaelle Fournier

I'll go ahead with the process.

Thanks all.


Re: [VOTE] Release Apache Camel Kamelets 3.20.5

2023-06-05 Thread Andrea Cosentino
Thanks all,

The vote passes.

Il giorno mar 30 mag 2023 alle ore 13:03 zineb bendhiba <
bendhiba.zi...@gmail.com> ha scritto:

> +1 (binding)
>
> Thanks
>
> Zineb Bendhiba
>
> >
> > Le 29 mai 2023 à 18:45, Andrea Cosentino  a écrit :
> >
> > Hello all:
> >
> > This is a vote for releasing camel-kamelets 3.20.5
> >
> > Kamelets release files:
> > https://dist.apache.org/repos/dist/dev/camel/camel-kamelets/3.20.5
> > Kamelets staging repository:
> > https://repository.apache.org/content/repositories/orgapachecamel-1567
> > Kamelets Tag:
> > https://github.com/apache/camel/releases/tag/camel-3.20.5
> >
> > Please cast your vote.
> >
> > [ ] +1 Release camel-kamelets 3.20.5
> > [ ] -1 Veto the release (provide specific comments)
> >
> > The vote is open for at least 72 hours.
> >
> > Here's my +1.
> >
> > Thanks,
> > Andrea Cosentino
>