Ticket #1001: Default WANT_SUSPEND policy goes UNDEFINED, startd EXCEPTs

Activation timer showed up in 1998 (git show 3cef52db). The conditional setting of ATTR_JOB_START has been around since at least 2003 (see V6_5-branch).

See: https://bugzilla.redhat.com/show_bug.cgi?id=540545

[Append remarks]


2009-Nov-25 17:17:30 by tannenba:
So... bold proposal: all startd policy expressions must meta-equals True to be triggered. In other words, if any of the policy expressions evaluate to UNDEFINED it is the same as evaluating to False. Thoughts?

2009-Nov-30 08:55:38 by tstclair:
The code actually did the "right" thing, but it was rather difficult to diagnose. I believe this points to a more fundamental issue, leaving breadcrumbs in error handling. The original error was EXCEPT( "Can't find WANT_SUSPEND in internal ClassAd" ), which gives a starting point, but developers have to whip out their sloothing hats and determine a direction.

It may be beneficial to examine the EXCEPT sites and leave breadcrumbs (e.g. - "Hint: Check that your expression does not have an UNDEFINED variable.")

maybe an EXCEPT_TYPE(T, "Message") T appends debugging info based on type. Check a, then b, then c, if all else fails nuke this code.

To be honest, I would use exceptions, or a tribool... but hey, that's me. ;-)

2009-Nov-30 09:36:52 by matt:
I would be for pulling the policy expressions into a central place where we can document and enforce consistency.
[Append remarks]


Type: defect           Last Change: 2009-Dec-18 15:02
Status: resolved          Created: 2009-Nov-25 11:50
Fixed Version: v070402           Broken Version: v070000 
Priority:          Subsystem: Daemons 
Assigned To: matt           Derived From:  
Creator: matt  Rust:  
Customer Group: other  Visibility: public 
Notify: matt@cs.wisc.edu,zmiller@cs.wisc.edu,tannenba@cs.wisc.edu  Due Date:  

Related Check-ins:

2010-Nov-29 15:35   Check-in [25797]: more correctly document WANT_SUSPEND behavior -- changed in 7.4.2 (gittrac #1001) (By Karen Miller )
2010-Nov-29 15:05   Check-in [25795]: Revert "Documented meaning of UNDEFINED WANT_SUSPEND. #1001" This reverts commit ba7dae13e5d9103838cd5bcf5753410c03f83fda. (By Karen Miller )
2010-Nov-29 12:26   Check-in [25794]: Documented meaning of UNDEFINED WANT_SUSPEND. #1001 (By Dan Bradley )
2009-Dec-18 14:55   Check-in [16728]: WANT_SUSPEND that is UNDEFINED, either by being absent or evaluating to UNDEFINED, now means FALSE. It used to mean EXCEPT! (#1001) (By Matthew Farrellee )
2009-Dec-18 14:50   Check-in [16727]: Protect ActivationTimer from going to UNDEFINED (#1001) (By Matthew Farrellee )