From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeff Garzik Subject: Re: [PATCH 0/6 v2] logging refactoring Date: Tue, 15 Dec 2009 17:38:18 -0500 Message-ID: <4B280FDA.9010705@garzik.org> References: <1260317516-30991-1-git-send-email-cmccabe@alumni.cmu.edu> <436f52800912132323paf46ea2j6392ce81e13a7981@mail.gmail.com> <4B26A1C0.2080401@garzik.org> <436f52800912141818s1dea5f9bg2d156597210c7bb8@mail.gmail.com> <20091215111904.05b1b260@redhat.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=FtpEXXoIHlgd8swDmk8CqdSbaYvKr3SgwWfC/yPsW4w=; b=oSdhbypQnD780Nap9ya4QjKUqIt3ny0xRn2hWEwjb2DsDfEuX/vQkwfKmDx71kXrVF 9l3j4oNwfLfaQmwS06FMyv0HL5/fQIII60B5eqqDzTqV5CX8dOCbTR9SmkMVkZrAavba 1LeWDJQc8rFMbdZH2pCNOf5CiTFi45sAvhQzs= In-Reply-To: <20091215111904.05b1b260@redhat.com> Sender: hail-devel-owner@vger.kernel.org List-ID: Content-Type: text/plain; charset="us-ascii"; format="flowed" To: Pete Zaitcev Cc: Colin McCabe , Project Hail List On 12/15/2009 01:19 PM, Pete Zaitcev wrote: > On Mon, 14 Dec 2009 18:18:47 -0800 > Colin McCabe wrote: > >> Also my new patch creates a hail_log.h. It didn't really seem right to >> force everyone who wanted to use HAIL_LOG to include cldc.h. >> >> I'll convert over the rest of chunkd and tabled to the new macros if >> this patch series gets accepted (but not in this patch series!) > > You know what else would be nice? I find it irritating to include > everywhere due to 1:1 mapping of LOG_XXX values. > I'm inclined to think that a switch(){} in applog() would be an > acceptable price for getting rid of it. > > In fact, does anyone even understand why we continue to split > LOG_WARNING and LOG_ERR? We really have three log levels: > - debug > - info (which is actually an error) > - error (not really all that different from info actually) > Might as well create HAIL_DEBUG, HAIL_INFO, and HAIL_ERR (to be > used before exit(1), with values of 0,1,2 and remap to syslog > values where it goes to syslog. It would be nice to disconnect from syslog, yes. But the 'warning' log level has value. Jeff