Code review comment for lp:~xnox/ubuntu/utopic/sysvinit/upstart-task

Revision history for this message
Steve Langasek (vorlon) wrote :

On Fri, May 30, 2014 at 08:19:15AM -0000, Martin Pitt wrote:
> The way I understand it the really clean way to implement this would be to
> tell apart the case "this task job never ran" from "it ran at least once,
> but is stopped". This could either be by a different status message (like
> "stop/waiting" vs. "finished/waiting", or similar), or creating a stamp
> file in /run for every ran task. Both of which would be upstart changes.

> This also introduces the assumption that upstart's tasks will always run
> before startpar so that the init.d dependencies will always be satisfied
> for tasks. That's not quite correct and sounds like introducing race
> conditions.

In practice, *everything* in /etc/rcS.d is supposed to be redundant with
upstart jobs in the upstart case, and the impact of a race condition - as
opposed to hang - should be nil.

If we have task jobs that map to scripts in /etc/rc2.d, I think we should
take a close look at this. However, for the "unofficial upstart jobs" case,
I don't think we should put the effort into ensuring there are no race
conditions when the user has both created an upstart task job that conflicts
with an init script *and* has another init script depending on that first
task. Clearly we would want to address this if we were sticking with
upstart longer-term, but I don't think it's relevant on a transitional
basis.

« Back to merge proposal