Return-Path: X-Original-To: apmail-tomcat-dev-archive@www.apache.org Delivered-To: apmail-tomcat-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 E177D9F82 for ; Mon, 13 Feb 2012 22:01:31 +0000 (UTC) Received: (qmail 85243 invoked by uid 500); 13 Feb 2012 22:01:30 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 85184 invoked by uid 500); 13 Feb 2012 22:01:30 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 85171 invoked by uid 99); 13 Feb 2012 22:01:30 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 Feb 2012 22:01:30 +0000 X-ASF-Spam-Status: No, hits=0.7 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [76.96.59.227] (HELO qmta12.westchester.pa.mail.comcast.net) (76.96.59.227) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 Feb 2012 22:01:21 +0000 Received: from omta22.westchester.pa.mail.comcast.net ([76.96.62.73]) by qmta12.westchester.pa.mail.comcast.net with comcast id ZXHu1i0051ap0As5Ca1133; Mon, 13 Feb 2012 22:01:01 +0000 Received: from Christophers-MacBook-Pro.local ([69.143.109.145]) by omta22.westchester.pa.mail.comcast.net with comcast id Za111i00A38FjT13ia11zu; Mon, 13 Feb 2012 22:01:01 +0000 Message-ID: <4F39881C.4070606@christopherschultz.net> Date: Mon, 13 Feb 2012 17:01:00 -0500 From: Christopher Schultz User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:10.0.1) Gecko/20120208 Thunderbird/10.0.1 MIME-Version: 1.0 To: Tomcat Developers List Subject: Re: Custom rules for commons-digester References: <4F397C79.1070907@christopherschultz.net> In-Reply-To: X-Enigmail-Version: 1.3.5 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigB82E650D6CD0C51D8670058A" X-Virus-Checked: Checked by ClamAV on apache.org --------------enigB82E650D6CD0C51D8670058A Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Konstantin, On 2/13/12 4:32 PM, Konstantin Kolinko wrote: > 2012/2/14 Christopher Schultz : >> All, >> >> There are 15 or so custom rule classes in the Tomcat sources for >> handling various commons-digester events. >> >> I've only taken a brief glance at their content, but I'm wondering if = we >> can't replace these classes with an XML-based configuration that the >> Digester itself can handle for us. >> >> Such a change would eliminate those classes form our own code base as >> well as allow us to remove the package-renamed code from >> commons-digester in SVN (of course, we'd still have to re-package >> commons-digester for distribution, but at least we'd have less source = to >> deal with). >> >> Other than some logging (I can see, for instance, that >> ConnectorCreateRule emits warnings when setter methods can't be found = on >> the target class), is there a compelling reason to have source-based >> rules instead of configuration-based rules? >=20 > They are faster. Fair enough, but server.xml is processed only once on startup. Unless you're seeing an insane performance increase, I would suggest that maintainability might be more important than performance. (This also assumes that maintaining an XML-based configuration file represents less effort than maintaining the equivalent source code, but as I said previously, it would allow us to purge our copies of the Digester from our own svn repo as well, which I see as a win). -chris --------------enigB82E650D6CD0C51D8670058A Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk85iBwACgkQ9CaO5/Lv0PBXigCfScxldXdz8gL55eQD3rUbeCdu l/kAoMARCm2oaIHYsmwkdeQ8yZIbxs5Y =KtKx -----END PGP SIGNATURE----- --------------enigB82E650D6CD0C51D8670058A--