getInstPrimaryNode :: ConfigData -> String -> ErrorResult Node
getInstPrimaryNode cfg name =
  getInstanceByName cfg name
  >>= withMissingParam "Instance without primary node" return . instPrimaryNode
  >>= getNode cfg
getInstPrimaryNode :: ConfigData -> String -> ErrorResult Node
getInstPrimaryNode cfg name =
  getInstanceByName cfg name
  >>= withMissingParam "Instance without primary node" return . instPrimaryNode
  >>= getNode cfg
getInstPrimaryNode cfg name =
  getInstanceByName cfg name
  >>= withMissingParam "Instance without primary node" return . instPrimaryNode
  >>= getNode cfg