跟踪 Solr 中的分段
在我的应用程序中,我将所有 docid 添加到哈希映射中。但是,当分段发生时,docid 就会发生变化...是否有可能跟踪分段?因为我有一个自己的函数,它将根据 docids 重新创建哈希图?
现在,在每次提交时,我都会重新创建我的哈希图。这样,如果我发现分段发生时。然后我可以在发生分段时重新创建哈希图..
所以请帮助我...我对此没有任何想法... 示例:
Docid SEQID
1201 4522
1202 4576
1203 4567
Docid 来自 lucene ...我的需要是当分段发生时我需要调用我的 recreatHashMap() 所以任何人都可以告诉我何时调用分段。我需要跟踪的地方。
提前致谢。
In my application i am adding all the docid in the hash map. But while segmentation happen then docid are getting change... Is there any possibility to track the segmentation ?Because i am having one own function which will recreate hash map according to docids?
now on each commit i am recreating my hash map. so that if i found when segmentation is happen . then i can recreate hash map when segmentation is happened..
So please help me... i am not getting any idea for this...
Example :
Docid SEQID
1201 4522
1202 4576
1203 4567
Docid are from lucene ... my need is when segmentation is happen then i need to call my recreatHashMap() so can anyone tell me when Segmentation is called. where i need to keep track.
Advance thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您也可以从哈希图中删除单个条目,以便再次使用更新的文档 ID 添加它们。
也许你必须使用 ConcurrentHashMap 来防止并发修改。
You can delete the single entries from the hashmap, too, to add them with the updated document ids again.
Maybe you have to use ConcurrentHashMap to prevent concurrent modification.