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

Implement DashCounter #280

Open
chris-ha458 opened this issue Aug 30, 2023 · 1 comment
Open

Implement DashCounter #280

chris-ha458 opened this issue Aug 30, 2023 · 1 comment

Comments

@chris-ha458
Copy link

I am interested in multiset collections such as Python's Counter or Rust's Counter.

I see a few possible pathways

  1. Implement it on my own in the downstream project I will use.
  2. Implement it as totally new crate (one that would take any hashmap?)
  3. Implement it on the counter crate
  4. Implement it here.

For 1, outside of trivial usage I feel that there is value for this to exists independently in a crate form whether part of an existing one or a new one. That leads to 2. I think it is obvious that building a collection that extends hashmap while being fast AND concurrent is non trivial.
I have not yet engaged in specific discussions with the developer of the counter crate, but considering how it is a small and simple crate with 2k LoC including docs, I feel that it might be overcomplicating it.
I am still investigating performance opportunities there but it seems I might have underestimated the task.

The brings me to trying to implement it here.
From a brief reading of the code from both, I feel like there is a path to way to cleanly implement it, and I am willing to do the legwork and prepare an initial PR.

My question would be if there is interest in merging it at all?
I have a feeling that there is an unmet and uncommunicated need for this kind of collection.

Although I have limited knowledge into their operations, crates.io for instance, might be able to capitalize on this kind of collection instead of accessing DashMap's low level apis.

Anyway, I will repeat that I am willing to put in the effort necessary to develop, discuss, and debug such a feature if there is interest.

@chris-ha458
Copy link
Author

Just to avoid any confusion, I will likely not be able to singlehandedly implement the whole thing alone.
Esp considering that I am not yet versed in the rust approach to concurrent code. I will give a best effort though.

@chris-ha458 chris-ha458 mentioned this issue Aug 31, 2023
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

No branches or pull requests

1 participant