You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@solr.apache.org by ge...@apache.org on 2023/07/06 15:05:22 UTC

[solr] branch main updated: SOLR-16582 : Docs for SolrCore 'marker' log filtering (#1735)

This is an automated email from the ASF dual-hosted git repository.

gerlowskija pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/main by this push:
     new b90cf5dbe24 SOLR-16582 : Docs for SolrCore 'marker' log filtering (#1735)
b90cf5dbe24 is described below

commit b90cf5dbe24b0dd1853541666e965c112bd5dffb
Author: patsonluk <pa...@users.noreply.github.com>
AuthorDate: Thu Jul 6 08:05:16 2023 -0700

    SOLR-16582 : Docs for SolrCore 'marker' log filtering (#1735)
---
 .../deployment-guide/pages/configuring-logging.adoc      | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/solr/solr-ref-guide/modules/deployment-guide/pages/configuring-logging.adoc b/solr/solr-ref-guide/modules/deployment-guide/pages/configuring-logging.adoc
index 0dca9a4fa9d..706ca0d9de9 100644
--- a/solr/solr-ref-guide/modules/deployment-guide/pages/configuring-logging.adoc
+++ b/solr/solr-ref-guide/modules/deployment-guide/pages/configuring-logging.adoc
@@ -172,6 +172,22 @@ The log file under which you can find all these queries is called `solr_slow_req
 In addition to the logging options described above, it's possible to log only a selected list of request parameters (such as those sent with queries) with an additional request parameter called `logParamsList`.
 See the section on xref:query-guide:common-query-parameters.adoc#logparamslist-parameter[logParamsList Parameter] for more information.
 
+== Selective Logging on SolrCore
+
+Solr logs all core requests at INFO level using the o.a.s.c.SolrCore.Request. This can be disabled entirely by changing the level of these loggers to WARN or ERROR, or more selectively by using the `MarkerFilter` on request paths in `log4j2.xml`.
+
+For example:
+
+[source,xml]
+----
+<Logger name="org.apache.solr.core.SolrCore.Request" level="info">
+  <Filters>
+    <MarkerFilter marker="/get" onMatch="DENY" onMismatch="NEUTRAL"/>
+    <MarkerFilter marker="/replication" onMatch="DENY" onMismatch="NEUTRAL"/>
+  </Filters>
+</Logger>
+----
+
 == Request Logging
 
 Every incoming HTTP(s) request is by default logged in the standard https://en.wikipedia.org/wiki/Common_Log_Format[`NCSA format`]