Return-Path: X-Original-To: apmail-karaf-dev-archive@minotaur.apache.org Delivered-To: apmail-karaf-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C43B8103EC for ; Fri, 12 Apr 2013 07:30:27 +0000 (UTC) Received: (qmail 93862 invoked by uid 500); 12 Apr 2013 07:30:27 -0000 Delivered-To: apmail-karaf-dev-archive@karaf.apache.org Received: (qmail 93757 invoked by uid 500); 12 Apr 2013 07:30:27 -0000 Mailing-List: contact dev-help@karaf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@karaf.apache.org Delivered-To: mailing list dev@karaf.apache.org Received: (qmail 93741 invoked by uid 99); 12 Apr 2013 07:30:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 12 Apr 2013 07:30:27 +0000 X-ASF-Spam-Status: No, hits=-0.5 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of cschneider111@gmail.com designates 209.85.216.50 as permitted sender) Received: from [209.85.216.50] (HELO mail-qa0-f50.google.com) (209.85.216.50) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 12 Apr 2013 07:30:21 +0000 Received: by mail-qa0-f50.google.com with SMTP id bv4so730108qab.16 for ; Fri, 12 Apr 2013 00:30:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=RmfJyryBJUU0vUqOchJPjPWgX90QptPrQCkXvmkPb0A=; b=RIcx7FwOTBaE0YQFVcQe33xSRj0wIWf1j4+AFSeZ7OYdS673KFnltgnCvsQW7lmAGy PpIV+phrN20XvaLeGjHHN2h0yU+MYY+9/ZXipHWVDtX+IpyA5SU55KgGBAZBvN9NxzJQ AZejPgPsjsBzXgGn2VUa+8qV39Mxeao1oUCWk93RaJ3QkjFSVRlPLfjKqCmusvDhPTHN 0Ps3a6+ieqy4huX3H1B2ryiMojxrqw3jCzQJe0p0csh26uCOQ8eSazO+Te4t5Yp2mMMI 5qOfe2hXIcQPyv7e/2zzc3zoGAPZ4mQvxocgv4WxIMpjncVo1wAEQIVtN/+vGrhs49wK elug== X-Received: by 10.229.6.1 with SMTP id 1mr3606116qcx.17.1365751800485; Fri, 12 Apr 2013 00:30:00 -0700 (PDT) Received: from [10.0.0.102] (HSI-KBW-134-3-129-155.hsi14.kabel-badenwuerttemberg.de. [134.3.129.155]) by mx.google.com with ESMTPS id k8sm11883869qej.2.2013.04.12.00.29.59 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 12 Apr 2013 00:29:59 -0700 (PDT) Sender: Christian Schneider Message-ID: <5167B7F5.4010005@die-schneider.net> Date: Fri, 12 Apr 2013 09:29:57 +0200 From: Christian Schneider User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 MIME-Version: 1.0 To: dev@karaf.apache.org Subject: Re: Warning when files are not deployed by a feature References: <5166B780.8030201@die-schneider.net> <5167B1D4.2030802@nanthrax.net> In-Reply-To: <5167B1D4.2030802@nanthrax.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org I created the issue as https://issues.apache.org/jira/browse/KARAF-2266. Christian On 12.04.2013 09:03, Jean-Baptiste Onofr� wrote: > Hi Christian, > > We have an option "overwrite" to define if the file should be > overwritten or not during feature installation. > > I'm agree with you, we should log a warn message to inform the user if > a configfile or config (resulting to a file) don't overwrite the final > file. > > For the -f, I'm not sure: overriding the option in the features XML > could be risky, but basicly, it's the user responsibility. > > It sounds good to me. > > Do you want that I create the Jira about that ? > > Regards > JB > > On 04/11/2013 03:15 PM, Christian Schneider wrote: >> Hi all, >> >> karaf can deploy files like config files during the installation of a >> feature. If the file is already present then it is not overwritten. >> I wonder if we should print a warning in this case. One use case for >> this is a new version of a feature that adds a new needed property >> to a config file. If the old feature was already present then the old >> config will be present and the user may also have done changes. >> >> So there might be cases where a feature works if it can install its >> default configs but does not work when they are already present but >> invalid. >> So we could write for each file that is already present: >> "Warning: file to be deployed is already present and will not be >> changed." >> >> We could also provide an option in feature:install like -f that forces >> all files to be overwritten if someone wants to make sure the feature >> installation should use the defaults. >> >> What do you think? >> >> Christian >> > -- Christian Schneider http://www.liquid-reality.de Open Source Architect http://www.talend.com