-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[jaeger-v2] Add Validation And Comments to Badger Storage Config #5927
[jaeger-v2] Add Validation And Comments to Badger Storage Config #5927
Conversation
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
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.
couple of questions for reviewers
plugin/storage/badger/options.go
Outdated
Ephemeral bool `mapstructure:"ephemeral"` | ||
SyncWrites bool `mapstructure:"consistency"` | ||
MaintenanceInterval time.Duration `mapstructure:"maintenance_interval"` | ||
namespace string |
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.
do we want to make this field configurable?
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.
it's not needed, see #5929
plugin/storage/badger/options.go
Outdated
// KeyDirectory is the directory in which the keys are stored. Ephemeral must be | ||
// set to false for this configuration to take effect. | ||
KeyDirectory string `mapstructure:"directory_key"` | ||
// ValueDirectory is the directory in which the values should be stored. Ephemeral must be | ||
// set to false for this configuration to take effect. | ||
ValueDirectory string `mapstructure:"directory_value"` |
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.
do we want to group these?
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.
we could, e.g.
directories:
keys: ...
values: ...
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5927 +/- ##
=======================================
Coverage 96.81% 96.81%
=======================================
Files 344 344
Lines 16530 16537 +7
=======================================
+ Hits 16003 16010 +7
Misses 340 340
Partials 187 187
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
plugin/storage/badger/options.go
Outdated
// SpanStore holds the amount of time that the span store data is stored. | ||
// Once this duration has passed for a given key, span store data will | ||
// no longer be accessible. | ||
SpanStore time.Duration `mapstructure:"span_store"` |
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.
SpanStore time.Duration `mapstructure:"span_store"` | |
Spans time.Duration `mapstructure:"spans"` |
Signed-off-by: Mahad Zaryab <[email protected]>
please resolve conflicts |
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
done! |
Signed-off-by: Mahad Zaryab <[email protected]>
One more thing we can do is combine Options and NamespaceConfig into a single struct Config. |
@yurishkuro do we just want to get rid of |
Yes, the separate Options struct now serves no purpose. |
Opened PR at #5937 |
Which problem is this PR solving?
Description of the changes
Validate
method forNamespaceConfiguration
struct for the badger storageHow was this change tested?
Checklist
jaeger
:make lint test
jaeger-ui
:yarn lint
andyarn test