[英]Issue with Hash Map Space and Performance
I have to store more than 100 millions of key-values in my HashMultiMap (key can have multiple values). 我必须在我的HashMultiMap中存储超过1亿个键值(键可以具有多个值)。 Can anybody help me which one is faster for both storing and searching: 任何人都可以帮助我在存储和搜索方面更快的一个:
1) Berkeley DB 1) 伯克利DB
2) Tokyo Cabinet 2) 东京内阁
5) Or anyothers 5)或其他
Another point, is performance of those approximately identical to in-memory hash map ? 还有一点,那些性能与内存中的哈希映射大致相同吗? A little bit guidance will be more helpful. 一点指导会更有帮助。 Thanks. 谢谢。
NB: information about any one of these is also helpful. 注意:关于任何一个的信息也是有帮助的。
I'd recommend Redis . 我建议Redis 。 It's more of a data structure store than the others (eg it supports maps and sets) and requires very little effort to get started with. 它比其他结构更像是一种数据结构存储(例如,它支持地图和集合),并且只需很少的精力就可以开始使用。 It's incredibly simple to use and has a great Java API . 它使用起来非常简单,并且具有出色的Java API 。
I'd start by looking at the functions here that allow you to associate a key with a group of values. 我将从这里的功能开始,这些功能使您可以将键与一组值相关联。
I would have a look at leveldb , because it claims to be faster than Kyoto Cabinet . 我会看一下leveldb ,因为它声称比京都内阁要快 。 Other interesting libraries are Kyoto Cabinet , and JDBM3 . 其他有趣的库是Kyoto Cabinet和JDBM3 。
Those are low level libraries (without support for relational queries or SQL). 这些是低级库(不支持关系查询或SQL)。 Some offer transactional support, but I'm not sure if you need it. 有些提供事务支持,但是我不确定您是否需要它。 Still, in-memory hash maps are faster. 不过,内存中的哈希映射更快。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.