-
Notifications
You must be signed in to change notification settings - Fork 639
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
remove facetconfig locks #410
Conversation
failed because of environment problems Error: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. |
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 for the PR.
However as is, many of the methods are no longer atomic and may cause concurrency issues. Please change the declaration of fieldTypes
from:
private readonly IDictionary<string, DimConfig> fieldTypes = new ConcurrentDictionary<string, DimConfig>();
to:
private readonly ConcurrentDictionary<string, DimConfig> fieldTypes = new ConcurrentDictionary<string, DimConfig>();
to expose the methods that make ConcurrentDictionary
atomic and see the other comments about the changes to each of the methods.
I got it wrong. Upon closer inspection of the
So in other words, this PR is not the equivalent functionality of the locks that exist now, as this method does not make the entire block atomic like the lock does. I am curious, what issues are you actually seeing with these locks? |
nothing special, just performance penalty on GetTopChildrens method by the way, I would keep this in this implementation, its just changing the property configuration, hierarchical / multi dimension etc.. |
any updates with this? |
Given the fact that these locks exist in Lucene and this is not a reasonable locking alternative, we should keep them in place here. I would suggest holding off on this until we investigate #417 further, as it is still up in the air whether we should just use Your last commit, 0f18945 does contain some useful removal of casts except for 1 call to I removed more than 1000 casts last night and have passing tests, but I would like to run some benchmarks to see how removing them compares with the casts in place before submitting the PR. Benchmarking the |
cool, the expensive parts are the casts, if you have this on separate PR, this one can be closed. |
closed in #423 |
No description provided.