Revision 6819dc49 lib/config.py
b/lib/config.py | ||
---|---|---|
1056 | 1056 |
""" |
1057 | 1057 |
return self._UnlockedGetNodeList() |
1058 | 1058 |
|
1059 |
@locking.ssynchronized(_config_lock, shared=1) |
|
1060 |
def GetOnlineNodeList(self): |
|
1059 |
def _UnlockedGetOnlineNodeList(self): |
|
1061 | 1060 |
"""Return the list of nodes which are online. |
1062 | 1061 |
|
1063 | 1062 |
""" |
... | ... | |
1066 | 1065 |
return [node.name for node in all_nodes if not node.offline] |
1067 | 1066 |
|
1068 | 1067 |
@locking.ssynchronized(_config_lock, shared=1) |
1068 |
def GetOnlineNodeList(self): |
|
1069 |
"""Return the list of nodes which are online. |
|
1070 |
|
|
1071 |
""" |
|
1072 |
return self._UnlockedGetOnlineNodeList() |
|
1073 |
|
|
1074 |
@locking.ssynchronized(_config_lock, shared=1) |
|
1069 | 1075 |
def GetAllNodesInfo(self): |
1070 | 1076 |
"""Get the configuration of all nodes. |
1071 | 1077 |
|
... | ... | |
1293 | 1299 |
if self._last_cluster_serial < self._config_data.cluster.serial_no: |
1294 | 1300 |
if not self._offline: |
1295 | 1301 |
result = rpc.RpcRunner.call_write_ssconf_files( |
1296 |
self._UnlockedGetNodeList(), |
|
1302 |
self._UnlockedGetOnlineNodeList(),
|
|
1297 | 1303 |
self._UnlockedGetSsconfValues()) |
1298 | 1304 |
|
1299 | 1305 |
for nname, nresu in result.items(): |
Also available in: Unified diff