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

Simplify wildcard file import implementation #163

Merged
merged 1 commit into from Sep 17, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
15 changes: 4 additions & 11 deletions pkg/config/config.go
Expand Up @@ -386,17 +386,10 @@ func (f *File) expandFiles(dir string) (err error, files []*File) {
failedDataPath = &tmp
logger.Infof("Failed data path: %v", *failedDataPath)
}
eachConf := &File{
Path: &fileNames[i],
FailDataPath: failedDataPath,
BatchSize: f.BatchSize,
Limit: f.Limit,
InOrder: f.InOrder,
Type: f.Type,
CSV: f.CSV,
Schema: f.Schema,
}
files = append(files, eachConf)
eachConf := *f
eachConf.Path = &fileNames[i]
eachConf.FailDataPath = failedDataPath
files = append(files, &eachConf)
logger.Infof("find file: %v", *eachConf.Path)
}
}
Expand Down