You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Hans Orbaan (JIRA)" <ji...@apache.org> on 2016/03/24 09:59:25 UTC

[jira] [Updated] (CAMEL-9752) Quartz2 Scheduled route too many workers

     [ https://issues.apache.org/jira/browse/CAMEL-9752?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hans Orbaan updated CAMEL-9752:
-------------------------------
    Attachment: stacktrace.txt

> Quartz2 Scheduled route too many workers
> ----------------------------------------
>
>                 Key: CAMEL-9752
>                 URL: https://issues.apache.org/jira/browse/CAMEL-9752
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core, camel-quartz2
>    Affects Versions: 2.16.2
>         Environment: ALL
>            Reporter: Hans Orbaan
>            Priority: Critical
>             Fix For: 2.16.3, 2.17.0
>
>         Attachments: stacktrace.txt
>
>
> When any file:// or ftp:// consumer has a quartz2 schedule it can start throwing exceptions because too many worker-threads are busy at the same time (FileNotFoundException).
> Both workers can find the same files during filling the maxMessagesPerPoll, or during processing of those files. This happens when the route can not process all files before the next trigger happens.
> example (every minute):
> from(file:///mnt/sl-nl/bij/outbox/?sortBy=ignoreCase:file:name&filter=#fileFilter&recursive=false&move=processed&moveFailed=failed&scheduler.cron=0+0/1+0-23+?+*+1,2,3,4,5,6,7&scheduler=quartz2&scheduler.triggerId=nl_bij-export-to-archive-276)
> Attached you can find a stacktrace that would happen very often if worker1 processes and moves files that worker2 would also like to start processing.
> This does not happen when using scheduler=spring or when using delay=1m.
> The only way I have found to make sure a file or ftp component does not use multiple threads while consuming very large batches is to annotate the QuartzScheduledPollConsumerJob class with @DisallowConcurrentExecution.
> I am not familiar enough with the Camelcode to say what side effects it has and if this would prevent any quartz job in camel to now be single threaded, even if the user does not want it to be.
> But to me it looks like an oversight when moving from quartz to quartz2. A file or ftp consumer should be single threaded while retrieving.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)