Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B1FF611667 for ; Sun, 12 May 2013 21:33:13 +0000 (UTC) Received: (qmail 92972 invoked by uid 500); 12 May 2013 21:33:09 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 92857 invoked by uid 500); 12 May 2013 21:33:09 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 92847 invoked by uid 99); 12 May 2013 21:33:09 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 May 2013 21:33:09 +0000 X-ASF-Spam-Status: No, hits=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE X-Spam-Check-By: apache.org Received-SPF: error (athena.apache.org: local policy) Received: from [84.2.227.137] (HELO mail00k.mail.t-online.hu) (84.2.227.137) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 May 2013 21:33:03 +0000 Received: from [192.168.2.198] (563BC9DA.dsl.pool.telekom.hu [86.59.201.218]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail00k.mail.t-online.hu (Postfix) with ESMTPSA id 3b7yzl64L4zLS0Q for ; Sun, 12 May 2013 23:32:19 +0200 (CEST) Message-ID: <51900A62.8050801@istvandevai.com> Date: Sun, 12 May 2013 23:32:18 +0200 From: Istvan Devai User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Why is context.xml no longer copied to Catalina/localhost/myapp.xml? References: <51868449.8040408@apache.org> <5187EE80.3020802@apache.org> <558F9847-19B5-4399-99EB-C589EFD59C01@360works.com> <518819F4.8070200@apache.org> In-Reply-To: <518819F4.8070200@apache.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org On 05/06/2013 11:00 PM, Mark Thomas wrote: > On 06/05/2013 21:35, Jesse Barnum wrote: >> On May 6, 2013, at 1:55 PM, Mark Thomas wrote: >> >>> Right now, probably not. >>> >>> There are a couple of issues in this area (the thread I referenced, >>> unpacking WARs outside the appBase into the appBase, lack of clarity on >>> exactly what the expected behaviour in any given scenario) that I am >>> actively working on. My rough plan is: >>> - document what I think should happen (as simply as possible - this is >>> proving to be the hard part as there are so many variables) >>> - present this to the community for discussion / feedback >>> - implement it for 8.0.x >>> - probably back-port it to 7.0.x >>> >>> For you particular scenario I am considering allowing per Context >>> override of copyXML that would enable your app to work as you want in a >>> default Tomcat 7 install. Every new option, however adds to the overall >>> complexity so I am still working through this. >>> >>> Watch this space. >>> >>> Mark >> >> Make sense - thanks Mark. >> >> I am sure that this would be out of scope, but if we pictured an ideal scenario, it seems like there would be one configuration file that is tightly managed by the developer, which is replaced when the app is redeployed, and a different configuration file that is intended for end user customization, which is stored separately. > The way to do that is to keep copyXML=false, parameterise [1] the > META-INF/context.xml and then specify the necessary parameter values in > catalina.properties. > > That way the developer is free to manage META-INF/context.xml but any > updates won't change the parameterised values. > > If the app doesn't fail to start if the parameters are set, it should be > easy to add a ServletContextListener to make sure that it does. > > Mark > > [1] http://tomcat.apache.org/tomcat-7.0-doc/config/index.html (2nd para) > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org Hi Thomas, What if the customisation of context.xml is more than replacing a few simple variables? (for example: adding a valve) My exact problem is described in the thread titled "proper context usage" from a few days before, but it essentially comes down to this: I'd like to have a way to customize my app's context.xml in a way that it is retained while deploying-undeploying with the manager. See the mentioned thread for all ways I've tried to achieve this, without any success. Best regards, Istvan --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org