使用哪一个handler:

1. 可以通过在url中追加有名字的handler(以 ' / ' 开头命名)的名称来指定使用哪一个handler. 如:

<requestHandler name="/foo" class="my.package.CustomRequestHandler" />
http://localhost:8983/solr/foo?...

2. 旧的 handleSelect=true 方式(现已不推荐使用 qt指定handler, 现在select已经被显示命名为一个handler,而不是requestDispatcher:  <requestHandler name="/select" class="solr.SearchHandler"> -v4.7.0 )

The <requestDispatcher> element has a handleSelect attribute which defaults to false as of Solr 3.6. Before then(v3.6) it was true.

When it is true, there is an additional dispatch rule that comes into place if the request uses "/select" but there is no request handler by that name. Instead of it being an error, Solr uses the "qt" parameter to lookup the handler by name. If there is no 'qt' parameter then the default handler is chosen.

http://localhost:8983/solr/select?qt=mysearch&...
'qt' can be used to choose a request handler in other cases aside from a new HTTP request. Two others are for the warming queries and also for the ping query, both configured in solrconfig.xml. For these other cases, there is no restrictions on a leading '/'. And in these cases, when 'qt' is not specified, the default handler is chosen.

The default handler is normally the handler named "/select". However another specific handler can be anointed as such with a default="true" attribute on it, if desired. "standard" was the old default name and will still work but it's legacy/deprecated. If there is no default handler, then most/all cases in which a default one is chosen will instead trigger an error.

<!-- Request Dispatcher

This section contains instructions for how the SolrDispatchFilter
should behave when processing requests for this SolrCore.

handleSelect is a legacy option that affects the behavior of requests
such as /select?qt=XXX

handleSelect="true" will cause the SolrDispatchFilter to process
the request and dispatch the query to a handler specified by the
"qt" param, assuming "/select" isn't already registered.

handleSelect="false" will cause the SolrDispatchFilter to
ignore "/select" requests, resulting in a 404 unless a handler
is explicitly registered with the name "/select"

handleSelect="true" is not recommended for new users, but is the default
for backwards compatibility
-->
<requestDispatcher handleSelect="false" >

http://wiki.apache.org/solr/SolrRequestHandler

http://blog.csdn.net/jaynol/article/details/24959373?hp.com

http://www.bkjia.com/yjs/765287.html

solr requestHandler的更多相关文章

  1. Solr: a custom Search RequestHandler

    As you know, I've been playing with Solr lately, trying to see how feasible it would be to customize ...

  2. solr服务中集成IKAnalyzer中文分词器、集成dataimportHandler插件

    昨天已经在Tomcat容器中成功的部署了solr全文检索引擎系统的服务:今天来分享一下solr服务在海量数据的网站中是如何实现数据的检索. 在solr服务中集成IKAnalyzer中文分词器的步骤: ...

  3. sorl6.0+jetty+mysql搭建solr服务

    1.下载solr 官网:http://lucene.apache.org/solr/ 2.目录结构如下 3.启动solr(默认使用jetty部署) 在path路径下将 bin文件夹对应的目录加入,然后 ...

  4. 大数据系列-CDH环境中SOLR入数据

    1       创建集合 SSH远程连接到安装了SOLR的CDH节点. 运行solrctl  instancedir  --generate  /solr/test/GX_SH_TL_TGRYXX_2 ...

  5. Solr与MySQL查询性能对比

    本文简单对比下Solr与MySQL的查询性能速度. 测试数据量:10407608     Num Docs: 10407608 这里对MySQL的查询时间都包含了从MySQL Server获取数据的时 ...

  6. 使用Solr索引MySQL数据

    环境搭建 1.到apache下载solr,地址:http://mirrors.hust.edu.cn/apache/lucene/solr/ 2.解压到某个目录 3.cd into D:\Solr\s ...

  7. solr教程

    转载请注明出处:http://www.cnblogs.com/zhuxiaojie/p/5764680.html 本教程基于solr5.5 前言 至于为什么要用solr5.5,因为最新的6.10,没有 ...

  8. Solr实现Low Level查询解析(QParser)

    Solr实现Low Level查询解析(QParser) Solr基于Lucene提供了方便的查询解析和搜索服务器的功能,可以以插件的方式集成,非常容易的扩展我们自己需要的查询解析方式.其中,Solr ...

  9. Linux下安装使用Solr

    Linux下安装使用Solr 1.首先下载Solr.mmseg4j分词包.tomcat并解压,这用google.百度都可以搜索得到下载地址. 2.因为要使用到中文分词,所以要设置编码,进入tomcat ...

随机推荐

  1. 在Android Studio中创建(或添加)第一个Hello World应用程序

    下面我们将使用Android Studio创建第一个简单的Hello World应用程序. 1.打开Android Studio,加载画面如下图所示:   2.选择”Start a new Andro ...

  2. 关闭电脑自带键盘(copy)

    用管理员身份运行cmd: 禁用笔记本键盘 sc config i8042prt start= disabled 启用笔记本键盘 sc config i8042prt start= auto

  3. Dispose的调用顺序

    非托管资源的释放顺序. 这是应该先释放 reader  再释放 stream. 或者直接使用using,防止出错 .

  4. Mybatis学习系列(七)缓存机制

    Mybatis缓存介绍 MyBatis提供一级缓存和二级缓存机制. 一级缓存是Sqlsession级别的缓存,Sqlsession类的实例对象中有一个hashmap用于缓存数据.不同的Sqlsessi ...

  5. online community

    online community spectrum https://spectrum.chat/xgqfrms https://community.xgqfrms.xyz/ https://spect ...

  6. [Leetcode] 20. Valid Parentheses(Stack)

    括号匹配问题,使用栈的特点,匹配则出栈,否则入栈,最后栈为空则全部匹配.代码如下: class Solution { public: bool isValid(string s) { stack< ...

  7. JDBC连接数据库的过程

    以连接MySQL为例: (1)加载MySQL数据库连接的驱动程序.到MySQL官网下载该驱动程序jar包,然后把包复制到WEB-INF/lib目录下,则JDBC会调用Class.forName()方法 ...

  8. [洛谷P1640][SCOI2010]连续攻击游戏

    题目大意:有很多的装备,每种装备都有2个属性,这些属性的值用[1,10000]之间的数表示.每种装备最多只能使用一次,且只能使用其中一种属性.装备所使用的属性值必须从1开始连续.问最多能攻击多少次? ...

  9. Document base D:\devTools\apache-tomcat-6.0.51\webapps\AppService does not exist or is not a readable directory

    tomcat通过eclipse发布项目到webapp后  手动删除在webapp目录下的文件,启动tomcat时,会报出异常找不到那个删除的项目. 解决方法是(1)重新发布项目到webapp (2)在 ...

  10. Extend the size of ext3 partition online in VM

    1. Increase disk space in vCenter 2. scan disk on the Linux VM # fdisk -lu > /tmp/fdisk. # > / ...