Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 17216 invoked from network); 22 May 2006 18:33:11 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 22 May 2006 18:33:11 -0000 Received: (qmail 41696 invoked by uid 500); 22 May 2006 18:33:09 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 41667 invoked by uid 500); 22 May 2006 18:33:08 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org List-Id: Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 41656 invoked by uid 99); 22 May 2006 18:33:08 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 22 May 2006 11:33:08 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of ap-cocoon-dev@m.gmane.org designates 80.91.229.2 as permitted sender) Received: from [80.91.229.2] (HELO ciao.gmane.org) (80.91.229.2) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 22 May 2006 11:33:06 -0700 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1FiFCi-0005ql-G5 for dev@cocoon.apache.org; Mon, 22 May 2006 20:32:32 +0200 Received: from d51a4ce9d.access.telenet.be ([81.164.206.157]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 22 May 2006 20:32:32 +0200 Received: from jh by d51a4ce9d.access.telenet.be with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 22 May 2006 20:32:32 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: dev@cocoon.apache.org From: Jorg Heymans Subject: Re: [2.2] Configuration Date: Mon, 22 May 2006 20:32:39 +0200 Lines: 55 Message-ID: References: <20060522131042.2995.qmail@web26812.mail.ukl.yahoo.com> <4471F1F9.1030409@apache.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: d51a4ce9d.access.telenet.be User-Agent: Thunderbird 1.5.0.2 (Macintosh/20060308) In-Reply-To: <4471F1F9.1030409@apache.org> Sender: news X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Reinhard Poetz wrote: > > Suppose you have two environments: development (dev) and production > (prod). If you create the web application, you might need different > .xconf (database connections, root sitemap, ...) values and different > properties. ... > I propose that we have a directory "src/main/webapp-profiles" that > contains all files for different profiles: > > src/main/webapp-profiles/dev/WEB-INF/xconf/cocoon-sitemap.xconf > src/main/webapp-profiles/prod/WEB-INF/conf/cocoon-sitemap.xconf > src/main/wenbapp-profiles/dev/WEB-INF/properties/core.properties > src/main/wenbapp-profiles/prod/WEB-INF/properties/core.properties Just fyi, you can define placeholders a la ${my.db.url} in text files and have these replaced by maven during build time. So you could do src/main/filters/${env}.properties .... true **/*.xconf combined with this in settings.xml: .... prod Note that ${env} in the pom is resolved to the property in the profile. That way you wouldn't have to duplicate your configuration files. Regards Jorg