[ 
https://issues.apache.org/jira/browse/FLUME-2282?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13855436#comment-13855436
 ] 

Roshan Naik edited comment on FLUME-2282 at 12/23/13 6:31 AM:
--------------------------------------------------------------

Yes i was thinking the same wrt to another bug being present.. I think those 
errors came from transactions that were already in flight before the channel 
closed.  
For some reason the sink and source threads were still active. i was using avro 
sinks and spoodir soource in this case.



was (Author: roshan_naik):
Yes i was thinking the same wrt to another bug being present.. I think those 
errors came from transactions that were already in flight before the channel 
closed. My recollection is that reconfig triggers the foll order:
For some reason the sink and source threads were still active. i was using avro 
sinks and spoodir soource in this case.


> File Channel throws IllegalStateException causing some sources to not be to 
> recover from a reconfig
> ---------------------------------------------------------------------------------------------------
>
>                 Key: FLUME-2282
>                 URL: https://issues.apache.org/jira/browse/FLUME-2282
>             Project: Flume
>          Issue Type: Bug
>          Components: Configuration, File Channel
>            Reporter: Roshan Naik
>              Labels: channel
>
> when the config file is updated and the file channel is shut, the Source 
> receives a java.lang.IllegalState exception from FileChannel. Unfortunately 
> unless sources are designed to catch all exception types, they will not know 
> this is a channel exception and likely to go into fuzzy states.
> For instance the FLUME-2255 patch catches only ChannelException.
> The below stack trace can be seen in logs when this happens with FLUME-2255 
> applied:
> {code}
> 21 Dec 2013 21:15:03,030 ERROR [pool-17-thread-1] 
> (org.apache.flume.source.SpoolDirectorySource$SpoolDirectoryRunnable.run:194) 
>  - Uncaught exception in SpoolDirSource thread 
> java.lang.IllegalStateException: Channel closed [channel=channel_nontx]
>       at 
> org.apache.flume.channel.file.FileChannel.createTransaction(FileChannel.java:351)
>       at 
> org.apache.flume.channel.BasicChannelSemantics.getTransaction(BasicChannelSemantics.java:122)
>       at 
> org.apache.flume.channel.ChannelProcessor.processEventBatch(ChannelProcessor.java:181)
>       at 
> org.apache.flume.source.SpoolDirectorySource$SpoolDirectoryRunnable.run(SpoolDirectorySource.java:179)
>       at 
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
>       at 
> java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:351)
>       at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:178)
>       at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:165)
>       at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:267)
>       at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
>       at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>       at java.lang.Thread.run(Thread.java:679)
> {code}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to