The percentile aggregation function was just added to the new Solr Facet Module. This allows one to calculate one or more percentiles for each facet bucket (i.e. each group of documents produced by faceting), and even sort facet buckets by any given percentile. The percentile aggregation even works with distributed […]

Percentiles for Solr Faceting

Getting Started with Solr: a Simple Solr Tutorial Note: this tutorial is for Solr 4 1. Download Solr Download Apache Solr 4. You only need to download the single .ZIP or .TGZ file and extract it anywhere you like – no installation is required!! 2. Start the Server $ cd […]

Getting Started with Solr

Although query parameters are often an easy method to create a Solr requests by hand, they have a number of drawbacks: Inherently un-structured, requiring unsightly parameters like f.facet_name.facet.range.start=5 Inherently un-typed… everything is a string. More difficult to decipher large requests. Harder to programmatically create a request. Impossible to validate. Because […]

Solr JSON Request API

Introduction Facet Types Testing Using Curl Terms Facet Query Facet Range Facet Related page: Facet Functions Related page: Sub-Facets Introduction Solr 5.1 has a completely re-written faceted search module with a structured JSON API to control the faceting commands. The structured nature of nested sub-facets are more naturally expressed in […]


Noggit is the world’s fastest streaming JSON parser for Java. Noggit is the streaming JSON parser used in Solr. It lives here on github. JSON features and extensions Noggit supports a number of extensions to the JSON grammar. All of these extensions are optional and may be disabled. Comments Unquoted […]

Noggit, the JSON Streaming Parser

Lucene/Solr trunk (the future 6.0 release) is now on Java8, while version 5.x is still on Java7. Linux and Windows allows one to install a JDK any place in the filesystem, and I use the convention of installing in /opt/jdk7 and /opt/jdk8. Things are a little more difficult on Mac […]

Switching between Java7 and Java8 in Lucene/Solr

Traditional faceted search (also called guided navigation) involves counting search results that belong to categories (also called facet constraints). The new facet functions in Solr extends normal faceting by allowing additional aggregations on document fields themselves. Combined with the new Sub-facet feature, this provides powerful new realtime analytics capabilities. Also […]

Solr Facet Functions and Analytics

Subfacets (also called Nested Facets) is a more generalized form of Solr’s current pivot faceting that allows adding additional facets for every bucket produced by a parent facet. Subfacet advantages over pivot faceting: Subfacets work with facet functions (statistics), enabling powerful real-time analytics Can add a subfacet to any facet […]

Solr Subfacets

Solr 4.10 and Heliosearch .07 have added a terms query (or terms filter) to more efficiently match many terms in a single field. A large number of terms are often useful for things like access control lists or security filters. Previously, the only way to do this was a large […]

Solr Terms Query for matching many terms

Native code faceting for Solr has just been added to Heliosearch, and benchmarks show an impressive 2x performance increase! This is faceting code written in C++ and statically compiled for maximum performance, and loaded into the JVM via JNI (Java Native Interface). nCache, Heliosearch’s off-heap version of the Lucene/Solr FieldCache, […]

Native Code Faceting