lucene segment会包含所有的索引文件,如tim tip等,可以认为是mini的独立索引
A Lucene index segment can be viewed as a "mini" index or a shard. Each segment is a collection of all needed files for an index, including .tim and .tip. If you list your Lucene index directory, you'll see files belonging to the same segment have the same names with all different types. In fact, if you force a merge, you'll get an index of one single segment.
Each segment contains an index of a subset of your document collection. Lucene usually creates a new segment when new documents are added to a working index, to avoid (or rather delay and batch later) reindexing cost.
When a search is executed, Lucene will fan that query over all segments, and all the index wide statistics required for relevance ranking (such as idf) are combined, so from the client's perspective, the ranking is the same as searching from an index of one segment. Note that the other famous stat, tf, is per-document, so it is already available at the segment reader layer.
Now things get more interesting when you have Lucene indexes across machines (as the case in Solr Cloud, which is one of the distributed search service built on Lucene). Due to performance and complexity, Solr Cloud don't aggregate global stats across clusters (yet), so each machine would use their own stats on the index it holds (which could be consisted of multiple segments :).
摘自:https://www.quora.com/Are-the-individual-tim-and-tip-files-term-dictionaries-of-a-Lucene-index-segment-updated-when-a-new-segment-is-added-to-Lucene
lucene segment会包含所有的索引文件,如tim tip等,可以认为是mini的独立索引的更多相关文章
- Solr4.8.0源码分析(9)之Lucene的索引文件(2)
Solr4.8.0源码分析(9)之Lucene的索引文件(2) 一. Segments_N文件 一个索引对应一个目录,索引文件都存放在目录里面.Solr的索引文件存放在Solr/Home下的core/ ...
- Solr4.8.0源码分析(8)之Lucene的索引文件(1)
Solr4.8.0源码分析(8)之Lucene的索引文件(1) 题记:最近有幸看到觉先大神的Lucene的博客,感觉自己之前学习的以及工作的太为肤浅,所以决定先跟随觉先大神的博客学习下Lucene的原 ...
- Solr4.8.0源码分析(12)之Lucene的索引文件(5)
Solr4.8.0源码分析(12)之Lucene的索引文件(5) 1. 存储域数据文件(.fdt和.fdx) Solr4.8.0里面使用的fdt和fdx的格式是lucene4.1的.为了提升压缩比,S ...
- Solr4.8.0源码分析(11)之Lucene的索引文件(4)
Solr4.8.0源码分析(11)之Lucene的索引文件(4) 1. .dvd和.dvm文件 .dvm是存放了DocValue域的元数据,比如DocValue偏移量. .dvd则存放了DocValu ...
- Solr4.8.0源码分析(10)之Lucene的索引文件(3)
Solr4.8.0源码分析(10)之Lucene的索引文件(3) 1. .si文件 .si文件存储了段的元数据,主要涉及SegmentInfoFormat.java和Segmentinfo.java这 ...
- Lucene索引文件组成
Lucene的索引里面存了些什么,如何存放的,也即Lucene的索引文件格式,是读懂Lucene源代码的一把钥匙. 当我们真正进入到Lucene源代码之中的时候,我们会发现: Lucene的索引过程, ...
- Lucene索引文件学习
最近在做搜索,抽空看一下lucene,资料挺多的,不过大部分都是3.x了--在对着官方文档大概看一下. 优化后的lucene索引文件(4.9.0) 一.段文件 1.段文件:segments_5p和s ...
- lucene大索引文件分布式存储方案
这几天实现了个Lucene分布式检索的模块,采用的分布式方案是将数据分块,分别生成N个索引文件,放到N个节点上运行.检索时,对每一个节点发出查询请求,将N个节点返回的结果归并,然后生成一个新的结果.如 ...
- sphinx索引文件进一步说明——最好是结合lucene一起看,直觉告诉我二者本质无异
摘自:http://blog.csdn.net/cangyingzhijia/article/details/8592441 Sphinx使用的文件包括 "sph", " ...
随机推荐
- 把以100000+4位随机码的登录账号(比如1000001234),赋予制单页面的权限,怎么写sql啊
insert into sys_user_role (user_id,role_id,office_id) select id,'000101100000000004UP',company_id f ...
- HDU-1061-Rightmost Digit,快速幂水过!~~
Rightmost Digit Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) ...
- kubernetes集群新增node
kubernetes集群要新增node,首先要配置ssh免密登陆 root@ht:/etc/ansible# ssh-copy-id 172.18.196.6 /usr/bin/ssh-copy-id ...
- POJ 1159 字符串匹配问题
题目大意: 问至少添加几个字符才能保证这个字符串是个回文串 一开始想也想不到字符串匹配上,因为是找回文串,我们可以把已给字符串逆向得到一个新的字符串,然后比较两者得到最大匹配长度,最后总长度减去最大匹 ...
- 生物遗传学 整理人PYJ (恋_紫花地丁)
生物遗传学整理人PYJ (恋_紫花地丁) 高中生物唯一需要数学知识的就是遗传学的概率计算了.这里对简单的遗传学规律做一些总结. 目录: 1. 孟德尔第一定律(分离定律): 2. 孟 ...
- Lucene的例子
lucene爬数据库中的数据无非也是查询数据.所有我们用lucene搜索数据主要有下面几个步骤:(代码紧供参考) 一 , 从数据库中查数据 ====爬数据 ------------- ...
- windows 下安装Apache httpd 只需三步
1.下载 Apache 官网地址:http://httpd.apache.org/docs/current/platform/windows.html#down 找到这个, 看到这几个选项: Apac ...
- LightOJ1094 - Farthest Nodes in a Tree(树的直径)
http://lightoj.com/volume_showproblem.php?problem=1094 Given a tree (a connected graph with no cycle ...
- 2018 11.1 PION 模拟赛
期望:250 100+100+50 实际:210 80+100+30 期望:100 实际:80 最后:两个点T了.可能是求逆元的方法太慢了,也可能是闲的又加了一个快速乘的原因. #inclu ...
- mysql查询今天,昨天,近7天,近30天,本月,上一月数据的SQL
原文:http://www.open-open.com/code/view/1423207309170 select * from ad_proTrack_t where to_days(crt_ti ...