lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Noble Paul നോബിള്‍ नोब्ळ् <noble.p...@corp.aol.com>
Subject Re: Response writer configs
Date Wed, 02 Dec 2009 06:36:48 GMT
I guess we should remove this commented response writers from the
example solrconfig. It adds no value.

On Wed, Dec 2, 2009 at 9:38 AM, Erik Hatcher <erik.hatcher@gmail.com> wrote:
>
> On Dec 1, 2009, at 9:04 PM, Ross wrote:
>>
>> I'm starting to play with Solr. This might be a silly question and not
>> particularly important but I'm curious.
>>
>> I setup the example site using the tutorial. It works very well. I was
>> looking around the config files and notice that in my solrconfig.xml
>> that the queryResponseWriter area is commented out but they all still
>> work. wt=php etc returns the php format. How is it working if they're
>> not defined? Are they defined elsewhere?
>
> Good question.  Solr defines (in SolrCore) a default set of response
> writers.
>
>  static{
>    HashMap<String, QueryResponseWriter> m= new HashMap<String,
> QueryResponseWriter>();
>    m.put("xml", new XMLResponseWriter());
>    m.put("standard", m.get("xml"));
>    m.put("json", new JSONResponseWriter());
>    m.put("python", new PythonResponseWriter());
>    m.put("php", new PHPResponseWriter());
>    m.put("phps", new PHPSerializedResponseWriter());
>    m.put("ruby", new RubyResponseWriter());
>    m.put("raw", new RawResponseWriter());
>    m.put("javabin", new BinaryResponseWriter());
>    DEFAULT_RESPONSE_WRITERS = Collections.unmodifiableMap(m);
>  }
>
> Note that these built in ones can be overridden, but not undefined, by
> registering a response writer with the same name as a built in one.
>
>        Erik
>
>



-- 
-----------------------------------------------------
Noble Paul | Principal Engineer| AOL | http://aol.com

Mime
View raw message