Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DAOS-6605 control: validate auto-generated config file #4676

Merged
merged 9 commits into from Feb 19, 2021
9 changes: 3 additions & 6 deletions src/control/lib/control/auto.go
Expand Up @@ -89,12 +89,9 @@ func ConfigGenerate(ctx context.Context, req ConfigGenerateReq) (*ConfigGenerate
return nil, err
}

// TODO: change Validate() to take io.Writer
// if err := cfg.Validate(&req.buf); err != nil {
// return &ConfigGenerateResp{
// Err: errors.Wrap(err, "validation failed on auto generated config"),
// }, nil
// }
if err := cfg.Validate(req.Log); err != nil {
return nil, errors.Wrap(err, "validation failed on auto generated config")
}

return &ConfigGenerateResp{ConfigOut: cfg}, nil
}
Expand Down