Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

powerman: when status and status_all are defined, use status_all only on full pluglist #156

Merged
merged 5 commits into from
Mar 3, 2024

Commits on Mar 2, 2024

  1. t/simulators: add missing "goto" in vpcd simulator

    Problem: The "temp" command was missing a "goto ok" statement after
    completing the temperature request.  It lead to unexpected output.
    
    Add the missing "goto ok".
    chu11 committed Mar 2, 2024
    Configuration menu
    Copy the full SHA
    db02fcc View commit details
    Browse the repository at this point in the history

Commits on Mar 3, 2024

  1. etc/devices: remove untested status scripts

    Problem: Current powerman implementation will always
    call the "all" status script instead of a "singleton"
    status scripts for power status, beacon status, and temperature
    status.  In the future this behavior will change.
    
    Some devices specify both "all" and "singleton" status scripts.
    This means the "singleton" status scripts are never used
    and are untested, but with future changes they will begin to be
    used.
    
    Solution: Remove the singleton status scripts in appro-gb2.dev,
    appro-greenblade.dev, and swpdu.dev.  This will preserve
    current behavior of those device files.
    chu11 committed Mar 3, 2024
    Configuration menu
    Copy the full SHA
    0c1a1d7 View commit details
    Browse the repository at this point in the history
  2. powerman: do not always call "all" query script

    Problem: When selecting a script to use for an action, the "all"
    version of a script is always used if the action is a query action
    (e.g. power status query, beacon query, etc.).
    
    This can be problematic in situations where blades/nodes/etc. are
    not fully populated, such as in a chassis.  We do not want to query
    "all" things in that case.
    
    Solution: Only call the all query script if all plugs are requested
    OR the singlet version of the script is not defined."?  For device files
    where unpopulated plugs may exist, it can define an all script and singlet
    script for each scenario.
    chu11 committed Mar 3, 2024
    Configuration menu
    Copy the full SHA
    4e7ea64 View commit details
    Browse the repository at this point in the history
  3. t: test which status script is used

    Problem: There are no tests to see which status script (status vs status_all)
    is chosen when both are specified in a device file.
    
    Add coverage in t0004-status-query.t, t0007-temperature.t, and t0008-beacon.t.
    chu11 committed Mar 3, 2024
    Configuration menu
    Copy the full SHA
    9992f96 View commit details
    Browse the repository at this point in the history
  4. man: add info on status scripts in powerman.dev(5)

    Problem: Recent updates altered when an "all" vs "singleton"
    status script is called.  However this change is not documented.
    
    Add information on why a user might want to specify both an
    "all" and "singleton" status script for power status, beacon status,
    and temperature status.
    chu11 committed Mar 3, 2024
    Configuration menu
    Copy the full SHA
    ac7726c View commit details
    Browse the repository at this point in the history