[sheepdog] [PATCH 3/4] sheep: add support for manual recovery

Liu Yuan namei.unix at gmail.com
Tue Sep 11 11:07:51 CEST 2012


On 09/11/2012 04:25 PM, MORITA Kazutaka wrote:
> +	if (sys->disable_recovery && rw->nr_scheduled_prio_oids <= rw->done) {

I guess we'd better add a inline helper here to be more
self-explanatory, because rw->nr_scheduled_prio_oids <= rw->done is key
to the lazy recovery logic.

how about

/* Document how lazy recovery work a bit */
bool has_objects_scheduled(struct recovery_work *rw)
...

if (sys->disable_recovery && has_objects_scheduled(rw))
...

Thanks,
Yuan



More information about the sheepdog mailing list