Hi Raymond,

I think I had the same problem with the FTP-Producer and I resolved it using an 
onCompletionExceptionHandler.

which I configured for the endpoint.

onCompletionExceptionHandler=#myAdapterExceptionHandler


Best regards,

Daniel Novak

________________________________
Von: Claus Ibsen <claus.ib...@gmail.com>
Gesendet: Mittwoch, 16. Oktober 2019 19:16:33
An: users@camel.apache.org
Betreff: Re: BridgeErrorHandler on JMS Endpoint does not work as expected

Hi

Okay so that is not a responsibility of the consumer / bridge error
handler if the error happens outside, eg in this case in the producer
(to).
So in that case you can use Camel's regular error handler which ought
to catch the write permission error and route it elsewhere.

However if you say the permission error didn't result in an exception
then let us know and see if we can reproduce it and get it fixed.

Also mind try with latest release as bug get fixes in both Camel and
3rd party libraries over time.

On Wed, Oct 16, 2019 at 4:55 PM ski n <raymondmees...@gmail.com> wrote:
>
> OK, I read it and understand it a little more. Still it's not exactly what
> I expected. An example I need to send a file with FTP component:
>
> Source (SFTP Server) --> Camel --> Destination (FTPS Server)
>
> As long as the file is at the source (and Camel is polling for whatever
> reason) I don't need a message on the deadletterchannel. The message isn't
> in the exchange yet (it's still accesible at the source), so I don't see
> it's already a responsibility of Camel.
>
> However I had a case where Camel didn't have the complete permission to
> write to the FTPS server. So it was allowed to create a file, but it wasn't
> allowed to write the content (an error). So the Camel exchange wasn't
> completed. I thought when adding bridgeerrorhandler=true that in such a
> case the error was sent to the deadletterchannel (Now the message was
> lost).
>
> Regards,
>
> Raymond
>
>
> Op wo 16 okt. 2019 om 16:26 schreef <daniel.no...@dz-privatbank.com>:
>
> > No. I think it's
> >
> > 11.4.8 Bridging the consumer with Camel’s error handler
> >
> >
> > But unfortunately it doesn't help me with my case.
> >
> >
> > regards
> >
> > Daniel
> >
> > ________________________________
> > Von: ski n <raymondmees...@gmail.com>
> > Gesendet: Mittwoch, 16. Oktober 2019 16:16:52
> > An: users@camel.apache.org
> > Betreff: Re: BridgeErrorHandler on JMS Endpoint does not work as expected
> >
> > Of course, I had CiA2 already opened.
> >
> > Do you mean 11.5 (Example that bridges the consumer with Camel’s error
> > handler). There the bridgeerrorhandler is explained, but I'm not sure about
> > the reasons.
> >
> > Op wo 16 okt. 2019 om 15:55 schreef Claus Ibsen <claus.ib...@gmail.com>:
> >
> > > Hi
> > >
> > > If you have a copy of the CiA2 book then read the error handler
> > > chapter which details about the bridge error handler and the reasons.
> > >
> > > On Wed, Oct 16, 2019 at 3:51 PM ski n <raymondmees...@gmail.com> wrote:
> > > >
> > > > Just note that SJMS component (=JMS 1.1) and SJMS2 component (=JMS
> > 2.0).
> > > >
> > > > I also wonder why the default for the bridgeErrorHandler option is
> > false?
> > > >
> > > > How can it set to true for all components globally? Or does it needs to
> > > be
> > > > set for each component like in this question:
> > > >
> > > >
> > >
> > https://stackoverflow.com/questions/38194380/apache-camel-how-to-set-global-component-options
> > > >
> > > >             HttpComponent http = context.getComponent("http4",
> > > > HttpComponent.class);
> > > >             http.setConnectionTimeToLive(5000);
> > > >
> > > > Regards,
> > > >
> > > > Raymond
> > > >
> > > >
> > > > Op wo 16 okt. 2019 om 13:47 schreef <daniel.no...@dz-privatbank.com>:
> > > >
> > > > > Hi guys,
> > > > >
> > > > >
> > > > > thanks for the answers. In the meantime I tried with Camel 2.24.2 and
> > > the
> > > > > JMS-Component but the problem is still the same.
> > > > >
> > > > > Next I will with the sjms2 component.
> > > > >
> > > > >
> > > > > I think that in the JMS-Component the EndpointMessageListener could
> > do
> > > > > more with the exception as just setting it into the exchange and
> > throw
> > > it
> > > > > to the MessageListenerContainer.
> > > > >
> > > > >
> > > > > But now I will try with the new component and inform you with the
> > > results.
> > > > >
> > > > >
> > > > > Thx and regards
> > > > > Daniel Novak
> > > > >
> > > > > ________________________________
> > > > > Von: ski n <raymondmees...@gmail.com>
> > > > > Gesendet: Mittwoch, 16. Oktober 2019 13:04:46
> > > > > An: users@camel.apache.org
> > > > > Betreff: Re: BridgeErrorHandler on JMS Endpoint does not work as
> > > expected
> > > > >
> > > > > @Daniel instead of camel-jms you can also try camel-sjms (The Simple
> > > (or
> > > > > Springless) JMS component). In my experience this component works
> > > better.
> > > > >
> > > > > Op wo 16 okt. 2019 om 12:56 schreef Claus Ibsen <
> > claus.ib...@gmail.com
> > > >:
> > > > >
> > > > > > Hi
> > > > > >
> > > > > > The bridge cannot do 100% of all errors as its how the underlying
> > > > > > library is designed. camel-jms uses spring jms and it has some
> > > > > > "limitations" on how it works and handle errors, where it does
> > > > > > re-connection and whatnot with the connection pool.
> > > > > >
> > > > > > On Wed, Oct 16, 2019 at 10:21 AM <daniel.no...@dz-privatbank.com>
> > > wrote:
> > > > > > >
> > > > > > > Hi guys,
> > > > > > >
> > > > > > >
> > > > > > > I tried to use the bridgeErrorHandler flag on my JMS Endpoint but
> > > sadly
> > > > > > it does not work.
> > > > > > >
> > > > > > > Because there is a lot of code which I have to share with you to
> > > make
> > > > > > you understand my problem I created a stackoverflow question as it
> > > is way
> > > > > > easier to read and to respond on comments there.
> > > > > > >
> > > > > > >
> > > > > > > If some of you have time to take a look that would be really
> > really
> > > > > > great.
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > >
> > https://stackoverflow.com/questions/58407987/apache-camel-jms-component-bridgeerrorhandler-does-not-work-as-documented
> > > > > > >
> > > > > > >
> > > > > > > Thanks in advance
> > > > > > > Daniel Novak
> > > > > > >
> > > > > > >
> > > **********************************************************************
> > > > > > > This message and any attachment are confidential and may be
> > > privileged
> > > > > > or otherwise protected from disclosure. If you are not the intended
> > > > > > recipient, please call or e-mail the sender and delete the message
> > > and
> > > > > any
> > > > > > attachment from your system. If you are not the intended recipient,
> > > you
> > > > > > must not copy this message or attachment or disclose the contents
> > to
> > > any
> > > > > > other person. E-mail transmission cannot be guaranteed to be secure
> > > or
> > > > > > error-free as information could be intercepted, corrupted, lost,
> > > > > destroyed,
> > > > > > arrive later or incomplete, or contain viruses. DZ PRIVATBANK
> > > therefore
> > > > > > does not accept liability for any errors or omissions in the
> > > contents of
> > > > > > this message which arises as a result of e-mail transmission. If
> > > > > > verification is required please request a hard-copy version. This
> > > message
> > > > > > is provided for informational purposes only and should not be
> > > construed
> > > > > as
> > > > > > a solicitation or offer to buy or sell any securities or related
> > > > > financial
> > > > > > instruments. DZ PRIVATBANK does not warrant that incoming e-mails
> > > will be
> > > > > > processed within a certain period of time. For security reasons, DZ
> > > > > > PRIVATBANK does not accept any instructions that must be in writing
> > > > > > (financial transactions, changes of address, etc.) sent by e-mail.
> > > If a
> > > > > > message is urgent, please contact us by telephone.
> > > > > > >
> > > **********************************************************************
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Claus Ibsen
> > > > > > -----------------
> > > > > > http://davsclaus.com @davsclaus
> > > > > > Camel in Action 2: https://www.manning.com/ibsen2
> > > > > >
> > > > >
> > >
> > >
> > >
> > > --
> > > Claus Ibsen
> > > -----------------
> > > http://davsclaus.com @davsclaus
> > > Camel in Action 2: https://www.manning.com/ibsen2
> > >
> >



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

Reply via email to