Chapter 2, Understanding Solr, of this book explains the solrconfig.xml
file in detail. We will look at the sample configuration in this section for log management. In the Solr configuration, interesting part will be the introduction of facets. For log management, you may consider the following facets to make overall browsing interesting:
Facet |
Description |
---|---|
Timeline based |
With this facet, users will be able to effectively filter their search based on the time. For example, options such as past 1 hour, past 1 week, and so on. |
Levels of log |
Levels of log provide you with the severity: for example, SEVERE, ERROR, INFO, and so on. |
Host |
Since this system provides a common search for multiple machines, this facet can provide filtering criteria if an administrator is looking for something specific |
User |
If an administrator knows about the user, extracting user information from log can add better filtering through the user facet |
Application |
Similar to host, administrators can filter the logs based on an application using this facet |
Severity |
Severity can be another filtering criteria; most severe errors can be filtered with this facet |
In addition to this, you will also use features of highlighting logs, spelling correction, suggestions (MoreLikeThis
), and so on. The following screenshot shows a sample facet sidebar of Apache Solr to give us a better understanding over how it may look:
The following sample configuration for Solr shows different facets and other information when you access/browse:
Similarly, the following configuration shows a timeline-based facet, and features such as highlighting and spell check: