-
Notifications
You must be signed in to change notification settings - Fork 205
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
Persister tmp file path #5995
Persister tmp file path #5995
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## feat/refactor-persister-factory #5995 +/- ##
===================================================================
- Coverage 80.37% 80.37% -0.01%
===================================================================
Files 709 709
Lines 94013 94000 -13
===================================================================
- Hits 75566 75553 -13
Misses 13161 13161
Partials 5286 5286 ☔ View full report in Codecov by Sentry. |
storage/factory/persisterCreator.go
Outdated
@@ -49,25 +51,33 @@ func (pc *persisterCreator) Create(path string) (storage.Persister, error) { | |||
return database.NewShardedPersister(path, pc, shardIDProvider) | |||
} | |||
|
|||
func getTmpFilePath(path string, pathSeparator string) (string, error) { | |||
pathItems := strings.Split(path, pathSeparator) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of using the pathSeparator const, can we make use of the path
package? Maybe path.Split
can help?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
right, used path package, thanks
Reasoning behind the pull request
UseTmpAsFilePath
db config field for all persistersTesting procedure
Pre-requisites
Based on the Contributing Guidelines the PR author and the reviewers must check the following requirements are met:
feat
branch created?feat
branch merging, do all satellite projects have a proper tag insidego.mod
?