7286: Add comments clarifying arvados_node_missing() and broken(). Also bump
[arvados.git] / services / nodemanager / arvnodeman / computenode / driver / azure.py
index ba3c9b04d8d099028612ac8d4d856fe02336be21..b1ec5e6abc95e923e1b6583d3c33e49a3247368d 100644 (file)
@@ -16,6 +16,7 @@ class ComputeNodeDriver(BaseComputeNodeDriver):
 
     DEFAULT_DRIVER = cloud_provider.get_driver(cloud_types.Provider.AZURE_ARM)
     SEARCH_CACHE = {}
+    CLOUD_ERRORS = BaseComputeNodeDriver.CLOUD_ERRORS + (BaseHTTPError,)
 
     def __init__(self, auth_kwargs, list_kwargs, create_kwargs,
                  driver_class=DEFAULT_DRIVER):
@@ -83,6 +84,8 @@ class ComputeNodeDriver(BaseComputeNodeDriver):
 
     def broken(self, cloud_node):
         """Return true if libcloud has indicated the node is in a "broken" state."""
+        # UNKNOWN means the node state is unrecognized, which in practice means some combination
+        # of failure that the Azure libcloud driver doesn't know how to interpret.
         return (cloud_node.state in (cloud_types.NodeState.ERROR, cloud_types.NodeState.UNKNOWN))
 
     @classmethod