druid icon indicating copy to clipboard operation
druid copied to clipboard

Different points of method "isReady" in HadoopIndexTask

Open zhangxinyu1 opened this issue 9 years ago • 2 comments

Current code of method "isReady" in HaddopIndexTask use JodaUtils.umbrellaInterval to produce a wider interval to lock task.

That means if there is a task with interval["2015-09-10/2015-09-11","2015-09-14/2015-09-15"] running, the interval of task lock will be ["2015-09-10/2015-09-15"].

Then, if a new task with interval["2015-09-12/2015-09-13"] is submitted, it will be in waiting list instead of running directly.

Why not let the new task with interval["2015-09-12/2015-09-13"] running directly by set the lock interval["2015-09-10/2015-09-11","2015-09-14/2015-09-15"].

zhangxinyu1 avatar Aug 24 '17 03:08 zhangxinyu1

Hi @zhangxinyu1, this is because we assume that intervals for batch indexing are usually contiguous and there is no hole in the whole interval. But, you're correct. It is possible and should be able to be run if intervals are not overlapped. This issue will be fixed in #4479.

jihoonson avatar Aug 25 '17 01:08 jihoonson

@jihoonson oh I see. Thank you.

zhangxinyu1 avatar Aug 25 '17 02:08 zhangxinyu1