class documentation

class OsQuery(QueryBase):

View In Hierarchy

Undocumented

Method DeclareLocks Declare locks for this query.
Method ExpandNames Expand names for this query.
Instance Variable do_locking Undocumented
Instance Variable wanted Undocumented
Static Method _DiagnoseByOS Remaps a per-node return list into a per-os per-node dictionary
Method _GetQueryData Computes the list of nodes and their attributes.

Inherited from QueryBase:

Method __init__ Initializes this class.
Method NewStyleQuery Collect data and execute query.
Method OldStyleQuery Collect data and execute query.
Constant FIELDS Undocumented
Constant SORT_FIELD Undocumented
Instance Variable names Undocumented
Instance Variable query Undocumented
Instance Variable requested_data Undocumented
Instance Variable sort_by_name Undocumented
Instance Variable use_locking Undocumented
Method _GetNames Helper function to determine names asked for in the query.
def DeclareLocks(self, lu, level):

Declare locks for this query.

See LogicalUnit.DeclareLocks.

def ExpandNames(self, lu):

Expand names for this query.

See LogicalUnit.ExpandNames.

do_locking =
wanted =

Undocumented

@staticmethod
def _DiagnoseByOS(rlist):

Remaps a per-node return list into a per-os per-node dictionary

Parameters
rlista map with node names as keys and OS objects as values
Returns
dict

a dictionary with osnames as keys and as value another map, with node UUIDs as keys and tuples of (path, status, diagnose, variants, parameters, api_versions) as values, eg:

  {"debian-etch": {"node1-uuid": [(/usr/lib/..., True, "", [], []),
                                  (/srv/..., False, "invalid api")],
                   "node2-uuid": [(/srv/..., True, "", [], [])]}
  }
def _GetQueryData(self, lu):

Computes the list of nodes and their attributes.