Velocity

Solr supports a velocity response writer, which is used in Velocity UI to demonstrate some core search features: faceting, highlighting, autocomplete, and geospatial searching. velocity response writer is an optional plugin available in the contrib/velocity directory.

To use velocity response writer, we must include its .jar file and all dependencies in the lib folder, and configure in solrconfig.xml as follows:

<queryResponseWriter name="velocity" class="solr.VelocityResponseWriter">
<str name="template.base.dir">${velocity.template.base.dir:}</str>
<!--
<str name="init.properties.file">velocity-init.properties</str>
<bool name="params.resource.loader.enabled">true</bool>
<bool name="solr.resource.loader.enabled">false</bool>
<lst name="tools">
<str name="mytool">com.example.MyCustomTool</str>
</lst>
-->
</queryResponseWriter>

Here, we have not configured the initialization and request parameters but as per our needs, we can configure them.

We have almost finished looking at search configuration components such as relevance, various query parsers, and response writers. Now let's take a deep dive and and explore various search result operations: faceting, clustering, highlighting, and so on.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.141.199.122