csi: log fallthrough on invalid node IDs for client RPC (#7918)

When a CSI client RPC is given a specific node for a controller but
the lookup fails (because the node is gone or is an older version), we
fallthrough to select a node from all those available. This adds
logging to this case to aid in diagnostics.
This commit is contained in:
Tim Gross
2020-05-11 12:26:10 -04:00
committed by GitHub
parent bda9e8408a
commit 338fd20bd2

View File

@@ -134,6 +134,9 @@ func (a *ClientCSI) nodeForController(pluginID, nodeID string) (string, error) {
_, err = getNodeForRpc(snap, nodeID)
if err == nil {
return nodeID, nil
} else {
// we'll fall-through and select a node at random
a.logger.Trace("%s could not be used for client RPC: %v", nodeID, err)
}
}