From dev-return-321605-archive-asf-public=cust-asf.ponee.io@lucene.apache.org Wed May 9 06:42:06 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 50F8D180649 for ; Wed, 9 May 2018 06:42:06 +0200 (CEST) Received: (qmail 24432 invoked by uid 500); 9 May 2018 04:42:03 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 24421 invoked by uid 99); 9 May 2018 04:42:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 May 2018 04:42:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 22362180794 for ; Wed, 9 May 2018 04:42:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -110.311 X-Spam-Level: X-Spam-Status: No, score=-110.311 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01, USER_IN_DEF_SPF_WL=-7.5, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id Iyzqn_vLZoer for ; Wed, 9 May 2018 04:42:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 7B1755FBF6 for ; Wed, 9 May 2018 04:42:01 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id B2EC1E010F for ; Wed, 9 May 2018 04:42:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 41AB821298 for ; Wed, 9 May 2018 04:42:00 +0000 (UTC) Date: Wed, 9 May 2018 04:42:00 +0000 (UTC) From: "Varun Thacker (JIRA)" To: dev@lucene.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (SOLR-11453) Create separate logger for slow requests MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/SOLR-11453?page=3Dcom.atlassian= .jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1646= 8319#comment-16468319 ]=20 Varun Thacker commented on SOLR-11453: -------------------------------------- {quote}I have plans to try and create a log4j config that uses a sysprop to= decide whether to log slow requests to a separate file, but it's not somet= hing that I expect to come together quickly. {quote} Checkout StartupLoggingUtils#muteConsole on how we disable console logs whe= n not running in foreground mode.=C2=A0 We could use a similar trick. =C2=A0 Do we really want to add a sysprop? My thoughts are to enable it by default= and then if a user doesn't want it he can change the log4j2.xml himself.= =C2=A0=C2=A0 > Create separate logger for slow requests > ---------------------------------------- > > Key: SOLR-11453 > URL: https://issues.apache.org/jira/browse/SOLR-11453 > Project: Solr > Issue Type: Improvement > Components: logging > Affects Versions: 7.0.1 > Reporter: Shawn Heisey > Assignee: Shawn Heisey > Priority: Minor > Attachments: SOLR-11453.patch, SOLR-11453.patch, SOLR-11453.patch= , SOLR-11453.patch, slowlog-informational.patch, slowlog-informational.patc= h > > > There is some desire on the mailing list to create a separate logfile for= slow queries. Currently it is not possible to do this cleanly, because th= e WARN level used by slow query logging within the SolrCore class is also u= sed for other events that SolrCore can log. Those messages would be out of= place in a slow query log. They should typically stay in main solr logfil= e. > I propose creating a custom logger for slow queries, similar to what has = been set up for request logging. In the SolrCore class, which is org.apach= e.solr.core.SolrCore, there is a special logger at org.apache.solr.core.Sol= rCore.Request. This is not a real class, just a logger which makes it poss= ible to handle those log messages differently than the rest of Solr's loggi= ng. I propose setting up another custom logger within SolrCore which could= be org.apache.solr.core.SolrCore.SlowRequest. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org