Uploaded image for project: 'Flume'
  1. Flume
  2. FLUME-2457

Lifecycle of HBase sink is broken

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.5.0
    • None
    • Sinks+Sources
    • None

    Description

      If the start() method of the HBase sink throws an exception then flume tries to call start() again without first calling stop(). This leads to an unrecoverable state where flume keeps calling start() forever and HBase Sink keeps throwing the same exception forever (see stacktrace below). This can happen, for example, if HBase is down for a long time (10 mins) during the very first call to start().

      Note that this also negatively affects a flume failover sinkgroup containing a HBase sink, because the group refuses to failover if the start() method of one of the sinks in the group throws an exception (this may be a separate bug)

      2014-09-08 11:00:17,409 ERROR org.apache.flume.lifecycle.LifecycleSupervisor: Unable to start SinkRunner: { policy:org.apache.flume.sink.DefaultSinkProcessor@481352e6 counterGroup:{ name:null counters:{} } } - Exception follows.
      java.lang.IllegalArgumentException: Please call stop before calling start on an old instance.
      	at com.google.common.base.Preconditions.checkArgument(Preconditions.java:88)
      	at org.apache.flume.sink.hbase.HBaseSink.start(HBaseSink.java:132)
      	at org.apache.flume.sink.DefaultSinkProcessor.start(DefaultSinkProcessor.java:46)
      	at org.apache.flume.SinkRunner.start(SinkRunner.java:79)
      	at org.apache.flume.lifecycle.LifecycleSupervisor$MonitorRunnable.run(LifecycleSupervisor.java:251)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      

      Attachments

        Activity

          People

            jrufus Johny Rufus
            tychol Tycho Lamerigts
            Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated: