In the previous chapter, we saw the various analyzers, tokenizers, and filters provided by Solr that help us select the most important data from a given document. In this chapter, we'll see how Solr provides us a way to index this data so that we can run queries on top of it. We'll cover the following topics in this chapter:
Defining field types in Solr
Creating a custom
musicCatalogue
exampleFacet searching
The Solr indexing process can mainly be broken down into two major parts:
Converting the document from its native format to XML or JSON, both of which are supported by Solr
Adding documents into Solr datastore using API or HTTP POST
To better understand the preceding two parts, we'll create an example of a music catalogue that contains metadata related to songs. The music catalogue will contain metadata related to a song that can later be used to retrieve important information regarding the song.
We'll also see how Solr provides various ways of feeding this information...