Hi all,
i have a simple route that is uploading to ftp,
and sometimes i have the following error while trying to upload file to ftp,
the strange thing is that it does not fail always, approximately 1 of 5
trial fails.
Any help will be appreciated.
Route:
Hi,
How it is meaningful to put that Thread.sleep(reconnectDelay) to
CustomPollStrategy instead of the one in SftpOperations class ?
public class CustomPollStrategy extends
RemoteFilePollingConsumerPollStrategy {
@Override
public synchronized boolean rollback(Consumer consumer,
Hi,
This is what i was looking for, Thanks Claus!
backoff saved my life.
--
View this message in context:
http://camel.465427.n5.nabble.com/FTP-Reconnect-attempt-problem-tp5765466p5765523.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Hi,
I have a route as below. My problem is about reconnect attempts.
I am waiting 1 min for the next poll from ftp with the parameter
consumer.delay=6 that is ok, but if the connection fails, expecting 2
min wait before next connection attempt but
below code is still using 1 min delay for the
I think i found the problem,
The code cannot reach to the sleep(reconnectDelay) because
getMaximumReconnectAttempts() is zero.
I need maximumReconnectAttempts=0 to work with customPollStrategy to caught
exceptions,
but need to set reconnectDelay either.
Any ideas will be appreciated.
//From
Hi Claus,
I can handle the exception with the help of custom poll strategy for the ftp
consumer(from), thanks for the suggestion.
But i noticed that if i use custom pollStrategy i can delay reconnect
attempt with the delay=xxx attribute instead of reconnectDelay=xxx
attribute.
is this normal?
Hi Morgan,
Thanks for the quick reply.
I looked at the page you suggested and also tried with handler,
But the strange thing is:
I have another route in which i connect to ftp too. But that route works as
i expected and retryWhile predicate is checked.
Predicate is considered:
Hi,
I have an FTP route for consuming files and working fine. When the FTP fails
to connect I want to catch the exception, try for some more and later give
up retrying connection attempt.
Here is my routes, when i debug, process in onException is working and
printing in process, but predicate in
Yes, GenericFileOperationFailedException is thrown. Trying with
Exception.class did not change the situation.
onException(Exception.class)
.handled(true)
.retryWhile(new Predicate() {
@Override
public boolean matches(Exchange exchange) {