Differences between revisions 4 and 5
Revision 4 as of 2006-11-29 11:17:49
Size: 2127
Editor: scott
Comment: fix migration
Revision 5 as of 2011-08-26 04:10:16
Size: 2127
Editor: localhost
Comment: converted to 1.6 markup
No differences found!

Please check the status of this specification in Launchpad before editing it. If it is Approved, contact the Assignee or another knowledgeable person before making changes.

Summary

Upstart currently has trivial support for "dependencies" which cause jobs to be held in the waiting state until the dependency is running. This specification proposes removing that feature.

Rationale

This feature was added to allow jobs to wait on other jobs before properly starting; envisioned as a way to perform more complex state-based tracking than events alone allow. In practice, this feature is not flexible enough to meet the requirements and the implementation of ComplexEventConfig removes the need for it entirely.

Scope

This scope of this specification is limited to the removal of an unused feature in upstart, it does not propose its replacement.

Design

  • The depends configuration file stanza will be removed.

  • The corresponding dependency event will be removed.

Implementation

Code

The configuration file parsing code will be modified to remove the depends stanza entirely.

Other changes are limited to init/job.h and init/job.c.

The depends member of the Job structure, and the associated JobName structure can be removed.

With no dependencies to release, the job_change_state function can be modified to remove the call to the job_release_depends function. The job_release_depends function can also be removed.

Starting a job can now happen straight away, so the dependency iteration code in job_start can be removed. This has the benefit of removing an evil stack recursion from upstart, making the code flow somewhat more logical again.

Data preservation and migration

These changes remove an undocumented feature, so should not affect any existing jobs.


CategorySpec

RemoveDepends (last edited 2011-08-26 04:10:16 by localhost)