lucene 如何在倒排索引中使用跳过列表? [英] how lucene use skip list in inverted index?
问题描述
在一些博客和 lucene 网站中,我知道 lucene 在倒排索引中使用数据结构跳过列表".但我对此有些疑惑.
In some blogs and lucene website,I know lucene use data structure "skip list" in inverted index. But I have some puzzle about it.
如果我错了,请纠正我.
Please correct me if I am wrong.
推荐答案
Lucene 以几种不同的方式使用内存,即使在创建 IndexReader 用于搜索和排序等操作(字段缓存):
Lucene uses memory in a couple different ways, even though the index is persisted on a disk when the IndexReader is created for searching and for operations like sorting (field cache):
http://blog.mikemccandless.com/2010/07/lucenes-ram-usage-for-searching.html
基本上,这些二进制文件会被复制到 RAM 中,以加快扫描速度并减少 I/O.您在上面的链接中得到了提示,如何使用某些参数进行搜索可以强制 Lucene 在搜索中跳过术语"因此,可以在哪里使用该数据结构.
Basically those binary files get copied into RAM for much faster scanning and reducing I/O. You get a hint in the above link how searching with some parameters can force Lucene to "skip terms in searching" Hence, where that data structure can be used.
Lucene 是开源的,因此您可以自己查看在 Java 或 Lucene.NET 中用于 C# 实现的代码.
Lucene is open source, so you can see the code for yourself what is being used in Java or Lucene.NET for the C# implementation.
这篇关于lucene 如何在倒排索引中使用跳过列表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!