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

Comparing the memory footprint of pelikan and redis #127

Closed
skimhugo opened this issue May 11, 2024 · 2 comments
Closed

Comparing the memory footprint of pelikan and redis #127

skimhugo opened this issue May 11, 2024 · 2 comments

Comments

@skimhugo
Copy link

The question is pelikan seems preallocate a large chunk of memory, how can I make a better comparison?

I saw the crate segcache‘s code logic, to use segcache also need preallocate memory.

I'm confused, how do I compare pelikan with other hash-map solution.

@thinkingfish
Copy link
Member

thinkingfish commented May 11, 2024

In segcache, the number of segments not in use is tracked by metrics: SEGMENT_FREE, which started out as the total number of segments pre-allocated. It's decremented here. If you use segment_size from the builder (defaults are here) and this metric, you can calculate how much memory is preallocated by not in use.

@skimhugo
Copy link
Author

Thanks, I will try.

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

2 participants