• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java IndexReaderWarmer类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.apache.lucene.index.IndexWriter.IndexReaderWarmer的典型用法代码示例。如果您正苦于以下问题:Java IndexReaderWarmer类的具体用法?Java IndexReaderWarmer怎么用?Java IndexReaderWarmer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IndexReaderWarmer类属于org.apache.lucene.index.IndexWriter包,在下文中一共展示了IndexReaderWarmer类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: getMergedSegmentWarmer

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
/** Returns the current merged segment warmer. See {@link IndexReaderWarmer}. */
public IndexReaderWarmer getMergedSegmentWarmer() {
  return mergedSegmentWarmer;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:LiveIndexWriterConfig.java


示例2: getMergedSegmentWarmer

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
@Override
public IndexReaderWarmer getMergedSegmentWarmer() {
  return super.getMergedSegmentWarmer();
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:IndexWriterConfig.java


示例3: setMergedSegmentWarmer

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
@Override
public IndexWriterConfig setMergedSegmentWarmer(IndexReaderWarmer mergeSegmentWarmer) {
  return (IndexWriterConfig) super.setMergedSegmentWarmer(mergeSegmentWarmer);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:5,代码来源:IndexWriterConfig.java


示例4: toIndexWriterConfig

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
public IndexWriterConfig toIndexWriterConfig(IndexSchema schema) {
  // so that we can update the analyzer on core reload, we pass null
  // for the default analyzer, and explicitly pass an analyzer on 
  // appropriate calls to IndexWriter
  
  IndexWriterConfig iwc = new IndexWriterConfig(luceneVersion, null);
  if (maxBufferedDocs != -1)
    iwc.setMaxBufferedDocs(maxBufferedDocs);

  if (ramBufferSizeMB != -1)
    iwc.setRAMBufferSizeMB(ramBufferSizeMB);

  if (termIndexInterval != -1)
    iwc.setTermIndexInterval(termIndexInterval);

  if (writeLockTimeout != -1)
    iwc.setWriteLockTimeout(writeLockTimeout);

  iwc.setSimilarity(schema.getSimilarity());
  iwc.setMergePolicy(buildMergePolicy(schema));
  iwc.setMergeScheduler(buildMergeScheduler(schema));
  iwc.setInfoStream(infoStream);

  // do this after buildMergePolicy since the backcompat logic 
  // there may modify the effective useCompoundFile
  iwc.setUseCompoundFile(getUseCompoundFile());

  if (maxIndexingThreads != -1) {
    iwc.setMaxThreadStates(maxIndexingThreads);
  }
  
  if (mergedSegmentWarmerInfo != null) {
    // TODO: add infostream -> normal logging system (there is an issue somewhere)
    IndexReaderWarmer warmer = schema.getResourceLoader().newInstance(mergedSegmentWarmerInfo.className, 
                                                                      IndexReaderWarmer.class,
                                                                      null,
                                                                      new Class[] { InfoStream.class },
                                                                      new Object[] { iwc.getInfoStream() });
    iwc.setMergedSegmentWarmer(warmer);
  }

  iwc.setCheckIntegrityAtMerge(checkIntegrityAtMerge);

  return iwc;
}
 
开发者ID:europeana,项目名称:search,代码行数:46,代码来源:SolrIndexConfig.java


示例5: toIndexWriterConfig

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
public IndexWriterConfig toIndexWriterConfig(IndexSchema schema) {
  // so that we can update the analyzer on core reload, we pass null
  // for the default analyzer, and explicitly pass an analyzer on 
  // appropriate calls to IndexWriter
  
  IndexWriterConfig iwc = new IndexWriterConfig(luceneVersion, null);
  if (maxBufferedDocs != -1)
    iwc.setMaxBufferedDocs(maxBufferedDocs);

  if (ramBufferSizeMB != -1)
    iwc.setRAMBufferSizeMB(ramBufferSizeMB);

  if (termIndexInterval != -1)
    iwc.setTermIndexInterval(termIndexInterval);

  if (writeLockTimeout != -1)
    iwc.setWriteLockTimeout(writeLockTimeout);

  iwc.setSimilarity(schema.getSimilarity());
  iwc.setMergePolicy(buildMergePolicy(schema));
  iwc.setMergeScheduler(buildMergeScheduler(schema));
  iwc.setInfoStream(infoStream);

  // do this after buildMergePolicy since the backcompat logic 
  // there may modify the effective useCompoundFile
  iwc.setUseCompoundFile(getUseCompoundFile());

  if (maxIndexingThreads != -1) {
    iwc.setMaxThreadStates(maxIndexingThreads);
  }
  
  if (mergedSegmentWarmerInfo != null) {
    // TODO: add infostream -> normal logging system (there is an issue somewhere)
    IndexReaderWarmer warmer = schema.getResourceLoader().newInstance(mergedSegmentWarmerInfo.className, 
                                                                      IndexReaderWarmer.class,
                                                                      null,
                                                                      new Class[] { InfoStream.class },
                                                                      new Object[] { iwc.getInfoStream() });
    iwc.setMergedSegmentWarmer(warmer);
  }

  return iwc;
}
 
开发者ID:yintaoxue,项目名称:read-open-source-code,代码行数:44,代码来源:SolrIndexConfig.java


示例6: setMergedSegmentWarmer

import org.apache.lucene.index.IndexWriter.IndexReaderWarmer; //导入依赖的package包/类
/**
 * Set the merged segment warmer. See {@link IndexReaderWarmer}.
 * 
 * <p>
 * Takes effect on the next merge.
 */
public LiveIndexWriterConfig setMergedSegmentWarmer(IndexReaderWarmer mergeSegmentWarmer) {
  this.mergedSegmentWarmer = mergeSegmentWarmer;
  return this;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:11,代码来源:LiveIndexWriterConfig.java



注:本文中的org.apache.lucene.index.IndexWriter.IndexReaderWarmer类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java Document类代码示例发布时间:2022-05-23
下一篇:
Java VertexPredicateFilter类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap