-
Notifications
You must be signed in to change notification settings - Fork 180
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
store: Add Memcached Index Cache mixin #106
Conversation
DCO missing, otherwise looks really awesome! |
6dad360
to
7b4eee9
Compare
67c23c9
to
aebb282
Compare
Signed-off-by: Kemal Akkoyun <[email protected]>
Signed-off-by: Kemal Akkoyun <[email protected]>
Signed-off-by: Kemal Akkoyun <[email protected]>
fdbeeb8
to
a9407c7
Compare
Signed-off-by: Kemal Akkoyun <[email protected]>
config+:: { | ||
memcached+: { | ||
addresses: error 'must provide memcached addresses', | ||
timeout: '0s', |
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.
@pracucci @pstibrany I'm trying to come up with sane default for memcached, could point me to the right direction? What works for you best?
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 really depends on the scale you wanna address. I still think the defaults I've set into Thanos are OK for a small/medium scale:
https://github.com/thanos-io/thanos/blob/1a2edf19475b854181e5abaa4b6f1c9caf2a1547/pkg/cacheutil/memcached_client.go#L35-L44
If you wanna be a bit more aggressive you may consider:
timeout: '2s',
maxIdleConnections: 1000,
maxAsyncConcurrency: 100,
maxAsyncBufferSize: 100000,
maxGetMultiConcurrency: 900,
maxGetMultiBatchSize: 1000,
I've also seen you set dnsProviderUpdateInterval: '3s'
. I'm not sure there's a real value of being that aggressive here. The default 10s could be enough (but maybe you find a good reason to lower it).
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.
Thanks a lot for the response, this was really helpful.
Signed-off-by: Kemal Akkoyun <[email protected]>
This is in decent shape to merge, could you have another look @metalmatze? |
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.
Nice, some suggestions only.
Signed-off-by: Kemal Akkoyun <[email protected]>
Signed-off-by: Kemal Akkoyun <[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.
nice!
This PR adds
withMemcachedIndexCache
to Thanos Store to usememcached
as index cache.Enables posting compression.
Changes
withMemcachedIndexCache
mixin.--experimental.enable-index-cache-postings-compression
--index-cache.config=${CONFIG}'
Verification
make generate