Return-Path: X-Original-To: apmail-lucene-dev-archive@www.apache.org Delivered-To: apmail-lucene-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4B498D340 for ; Tue, 30 Oct 2012 22:17:40 +0000 (UTC) Received: (qmail 81213 invoked by uid 500); 30 Oct 2012 22:17:39 -0000 Delivered-To: apmail-lucene-dev-archive@lucene.apache.org Received: (qmail 81167 invoked by uid 500); 30 Oct 2012 22:17:39 -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 81157 invoked by uid 99); 30 Oct 2012 22:17:39 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 Oct 2012 22:17:39 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [209.85.160.48] (HELO mail-pb0-f48.google.com) (209.85.160.48) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 Oct 2012 22:17:30 +0000 Received: by mail-pb0-f48.google.com with SMTP id wy7so518123pbc.35 for ; Tue, 30 Oct 2012 15:17:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=date:from:to:subject:in-reply-to:message-id:references:user-agent :mime-version:content-type:x-gm-message-state; bh=O938IvtEqabQRexTT1fIHLDUGjANFd4e4Qd6LTdryWc=; b=Ndxf+9zsRwh9VzGrCEG8zZJvE+tzE42ZPI09qUKDz0Jd5tOxhEztl4BlmTvjRR8xGG pbrEtovOCscDvopJ+KnJOdLvA2lDxJVj5UgvnYJulUHmTJlsB6CKNmQnJvqPr0tPaLDB ALmX95+bYOy1uNY5dBDAoyWoaGtI4SBGR8/kn+0XPTY6ZQuTm/Oox6vxNm0qjUqvcR1L HareR+Y50PFa6soOfZSzg1BdSw5uqzDfx2/xjUWWmVV3KzOOFrZP4pQN2YM1MaaWSGY0 Gn8g4mktBpbYZokND7AtrvAqqI8Qvq3Z9FLKcgDh/60yDwmA3JzXX2DN3lVd47FltU1V UWAQ== Received: by 10.68.217.104 with SMTP id ox8mr106119373pbc.35.1351635430123; Tue, 30 Oct 2012 15:17:10 -0700 (PDT) Received: from frisbee.local (250.185-62-69.ftth.swbr.surewest.net. [69.62.185.250]) by mx.google.com with ESMTPS id mn5sm1157467pbc.12.2012.10.30.15.17.07 (version=SSLv3 cipher=OTHER); Tue, 30 Oct 2012 15:17:08 -0700 (PDT) Date: Tue, 30 Oct 2012 15:17:08 -0700 (PDT) From: Chris Hostetter To: "dev@lucene.apache.org" Subject: RE: Service Unavailable exceptions not logged In-Reply-To: <8F0D0142CA7ECC4287A9EC1BD8CB880C182D6076BD@USLVDCMBVP01.ingramcontent.com> Message-ID: References: <8F0D0142CA7ECC4287A9EC1BD8CB880C182D607509@USLVDCMBVP01.ingramcontent.com> <8F0D0142CA7ECC4287A9EC1BD8CB880C182D6076BD@USLVDCMBVP01.ingramcontent.com> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Gm-Message-State: ALoCoQnWATpRGE5M66bH81BChQ8cqNfUshbnxkM73DmhfkZemmwG9Ggg/jP3Sabhc7YNN0gnbOCy X-Virus-Checked: Checked by ClamAV on apache.org : Possibly better is introduce yet one more overloaded constructor with a : boolean that suppresses logging and change PRH to use it. The crux of the problem historically, and how we got into the weird situation with the Ping handler is that we wnat to return to the *client* the 503, so we threw an exception that would propogate up and result in SolrDispatchFilter returning the 503 -- but in the meantime we had to jump through a bunch of hoops to deal with the logging because for *solr* it's not really an error and we shouldn't freak out about logging. (ie: we want the client to know there is an 503 error, but on the server we don't relaly care. and the hoops we've jumped through for logging are now hurting us in a differnet situation where the 503 really is a serious problem. We have a similar situation in the ShowFileHandler where we want the *client* to ge a 404 error, so we throw a SolrException witha 404 error, but as a result Solr logs loud and ugly that a 404 error happened. I *think* the cleanest way to deal with this now, would be to change PingRequestHandler and ShowFileRequestHandler so that instead of *throwing* a SolrException, their handleRequest methods just construct a new SolrException with the appropraite status code, put that exception in the SolrQueryResponse, and then return. I _think_ that would ypass the loud conspicous logging that currently happens when exceptions are thrown (and would let us remove the "ignore SERVICE_UNAVAILABLE exceptions" kludge that is huring us in SolrCloud so those exceptions would be logged loud and conspicuously) This type of solution is something that we *might* have been able to do along time ago except that it would have been complicated because of the different code paths arround writting successful output using hte response writers vs delegating error responses to the servlet container -- but now it doesn't matter, we use the response writters either way, so i *think* itwould be relatively striaght forward (although there may be some vestigal "oh no, we found an exception, we must log it" logic in the request dispatcher that might need to be tweaked to only do that if the exception is *thrown* and not just an object in the response) -Hoss --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org