Merge pull request #8315 from yeya24/create-dir

Create output directory before backfilling
This commit is contained in:
Björn Rabenstein 2020-12-28 14:36:00 +01:00 committed by GitHub
commit ffb3ef6765
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -621,5 +621,9 @@ func backfillOpenMetrics(path string, outputDir string) (err error) {
return err
}
defer inputFile.Close()
if err := os.MkdirAll(outputDir, 0777); err != nil {
return errors.Wrap(err, "create output dir")
}
return backfill(5000, inputFile.Bytes(), outputDir)
}