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

Events currently have both arguments and environment, where arguments are used for matching in job definitions and environment is available to the job processes itself. This specification proposes removing arguments in favour of matching on environment instead.

Rationale

Arguments to events used to be passed to the job processes as positional arguments, but JobEventExpressions removed this since there is no logical way to do this given the more complex event matching it allows; States reduces their usefulness even further. Since only environment is passed to job processes now, information would need to be needlessly duplicated in both.

Scope

This scope of this specification is limited to the removal of arguments from the event, and redefining how events are matched based on environment.

Design

Implementation

Code

Code changes are primarily limited to init/event.c and init/event.h.

The args member will be removed from the Event structure and code that uses it removed.

The args member of the EventOperator structure will be changed to env and code that uses it changed to match.

event_operator_match will be modified to match against the env table by position and name as described.

job_emit_event will be modified to produce the new event format.

parse_on_operand will be modified to ensure that positional arguments do not follow name-based ones.

Data preservation and migration

These changes are largely backwards compatible with the previous behaviour.

Unresolved issues


RemoveEventArguments (last edited 2011-08-26 04:10:18 by localhost)