对于 hibernate-search 3.4.0,MassIndexer 后的文件计数非常大
我使用 MassIndexer 进行索引。从 3.2.1 迁移到 Hibernate-search 3.4 后。最终的文件数量非常巨大(扩展名为 .cfs)。之前还好。同时迁移到 lucene-core 3.1.0
请有人能解释一下为什么会发生这种情况吗?
MassIndexer massIndexe = fullTextSession.createIndexer(SearchLuceneDocument.class);
massIndexe.purgeAllOnStart(true) // true by default, highly recommended
.optimizeAfterPurge(true) // true is default, saves some disk space
.optimizeOnFinish(true) // true by default
.batchSizeToLoadObjects(100)
.threadsForSubsequentFetching(15)
.threadsToLoadObjects(10)
.threadsForIndexWriter(4)
.cacheMode(CacheMode.IGNORE) // defaults to CacheMode.IGNORE
.startAndWait();
坦克前进!
阿尔乔姆
I use MassIndexer to index. After migrate to Hibernate-search 3.4 from 3.2.1.Final count of files is really really huge (with .cfs extension). Before it was OK. And the same time migrate onto lucene-core 3.1.0
Please, could somebody explain why it happened?
MassIndexer massIndexe = fullTextSession.createIndexer(SearchLuceneDocument.class);
massIndexe.purgeAllOnStart(true) // true by default, highly recommended
.optimizeAfterPurge(true) // true is default, saves some disk space
.optimizeOnFinish(true) // true by default
.batchSizeToLoadObjects(100)
.threadsForSubsequentFetching(15)
.threadsToLoadObjects(10)
.threadsForIndexWriter(4)
.cacheMode(CacheMode.IGNORE) // defaults to CacheMode.IGNORE
.startAndWait();
Tanks to advance!
Artem
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你在什么文件系统上?众所周知,某些 NFS 会泄漏文件描述符;事实上,这就是为什么我们提出不同的集群替代方案的原因 - 它们都不涉及 NFS。
我不知道我们在质量索引器期间没有关闭文件的错误,但如果您可以贡献一个测试来突出显示该错误,我很乐意研究它;将其发布在 JIRA 或 hibernate 论坛的搜索部分。
谢谢
what filesystem are you on? It's known that some NFS leak file descriptors; in fact that's why we propose different alternatives for clustering - none of them involves NFS.
I'm not aware of bugs of us not closing the files during massindexer, but if you could contribute a test highlighting the error I'd be glad to look into it; post it on JIRA or on the hibernate forums, in the Search sections.
thanks