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

Add cache to store UID to UserID mapping in EOS #1340

Merged
merged 4 commits into from
Dec 2, 2020

Conversation

ishank011
Copy link
Contributor

No description provided.

IljaN
IljaN previously approved these changes Nov 27, 2020
Copy link
Member

@IljaN IljaN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alternatively a sync map could be used: other than that LGTM 👍

https://golang.org/pkg/sync/#Map

@ishank011
Copy link
Contributor Author

ishank011 commented Nov 27, 2020

@IljaN I remembered a discussion about locked maps being more performant than sync #909 (comment), but reading the description for this

The Map type is optimized for two common use cases: (1) when the entry for a given key is only ever written once but read many times, as in caches that only grow, or (2) when multiple goroutines read, write, and overwrite entries for disjoint sets of keys.

I think that would be a better option. I'll update that. Thanks!

@labkode labkode merged commit 0ff299d into cs3org:master Dec 2, 2020
@ishank011 ishank011 deleted the eos-cache branch December 2, 2020 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants