You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stratos.apache.org by Udara Liyanage <ud...@wso2.com> on 2014/08/20 07:04:17 UTC

Keeping Duplicate config files

Hi,

We have duplicates some product configurations files, one inside product
and one in stratos-installer. At the boot time (when setup.sh is executed)
config files inside products will be replaced by the config files inside
stratos-installer.
Maintaining duplicate config files become an overhead when a parameter is
added to the config files in the product, it has to be added to the other
copy as well. Otherwise it may be missing at deployment time. This occurred
for expiryTimeout recently in autoscaler.xml

Possible solutions:
Replicate the changes as we do now,
Maintain only the config file in stratos-installer
or any other idea?

-- 

Udara Liyanage
Software Engineer
WSO2, Inc.: http://wso2.com
lean. enterprise. middleware

web: http://udaraliyanage.wordpress.com
phone: +94 71 443 6897

Re: Keeping Duplicate config files

Posted by Lahiru Sandaruwan <la...@wso2.com>.
On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:

> Hi,
>
> We have duplicates some product configurations files, one inside product
> and one in stratos-installer. At the boot time (when setup.sh is executed)
> config files inside products will be replaced by the config files inside
> stratos-installer.
> Maintaining duplicate config files become an overhead when a parameter is
> added to the config files in the product, it has to be added to the other
> copy as well. Otherwise it may be missing at deployment time. This occurred
> for expiryTimeout recently in autoscaler.xml
>
> Possible solutions:
> Replicate the changes as we do now,
> Maintain only the config file in stratos-installer
> or any other idea?
>

Can't we have the xml only in product and adjust the installer such that it
find the XMl tag and replace?



> --
>
> Udara Liyanage
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean. enterprise. middleware
>
> web: http://udaraliyanage.wordpress.com
> phone: +94 71 443 6897
>



-- 
--
Lahiru Sandaruwan
Committer and PMC member, Apache Stratos,
Senior Software Engineer,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: Keeping Duplicate config files

Posted by chris snow <ch...@gmail.com>.
Stratos running inside docker [1] does not use the stratos installer.

At the moment, the docker build copies the config files from tools and uses
sed to set the values at runtime. I didn't realise product also contained
the config files.  I would prefer to just have the config files in product
and set the values in the docker run script.

---
[1]
https://github.com/apache/stratos/tree/master/tools/stratos-docker-images/stratos
On 20 Aug 2014 06:30, "Gayan Gunarathne" <ga...@wso2.com> wrote:

> Do we recommend to use the Stratos product build itself without using the
> Stratos installer?
>
> If we recommed to use the Stratos installer every time,IMO we can maintain
> the config in separately in stratus installer and in setup time we can add
> them appropriately.
>
> Thanks,
> Gayan
>
>
> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>
>> Hi,
>>
>> We have duplicates some product configurations files, one inside product
>> and one in stratos-installer. At the boot time (when setup.sh is executed)
>> config files inside products will be replaced by the config files inside
>> stratos-installer.
>> Maintaining duplicate config files become an overhead when a parameter is
>> added to the config files in the product, it has to be added to the other
>> copy as well. Otherwise it may be missing at deployment time. This occurred
>> for expiryTimeout recently in autoscaler.xml
>>
>> Possible solutions:
>> Replicate the changes as we do now,
>> Maintain only the config file in stratos-installer
>> or any other idea?
>>
>> --
>>
>> Udara Liyanage
>> Software Engineer
>> WSO2, Inc.: http://wso2.com
>> lean. enterprise. middleware
>>
>> web: http://udaraliyanage.wordpress.com
>> phone: +94 71 443 6897
>>
>
>
>
> --
> Best Regards,
>
> Gayan Gunarathne
> Technical Lead
> WSO2 Inc. (http://wso2.com)
> email  : gayang@wso2.com  | mobile : +94 766819985
>
>

Re: Keeping Duplicate config files

Posted by Nirmal Fernando <ni...@gmail.com>.
On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com> wrote:

> Do we recommend to use the Stratos product build itself without using the
> Stratos installer?
>

Yes, Gayan, we do.

>
> If we recommed to use the Stratos installer every time,IMO we can maintain
> the config in separately in stratus installer and in setup time we can add
> them appropriately.
>
> Thanks,
> Gayan
>
>
> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>
>> Hi,
>>
>> We have duplicates some product configurations files, one inside product
>> and one in stratos-installer. At the boot time (when setup.sh is executed)
>> config files inside products will be replaced by the config files inside
>> stratos-installer.
>> Maintaining duplicate config files become an overhead when a parameter is
>> added to the config files in the product, it has to be added to the other
>> copy as well. Otherwise it may be missing at deployment time. This occurred
>> for expiryTimeout recently in autoscaler.xml
>>
>> Possible solutions:
>> Replicate the changes as we do now,
>> Maintain only the config file in stratos-installer
>> or any other idea?
>>
>> --
>>
>> Udara Liyanage
>> Software Engineer
>> WSO2, Inc.: http://wso2.com
>> lean. enterprise. middleware
>>
>> web: http://udaraliyanage.wordpress.com
>> phone: +94 71 443 6897
>>
>
>
>
> --
> Best Regards,
>
> Gayan Gunarathne
> Technical Lead
> WSO2 Inc. (http://wso2.com)
> email  : gayang@wso2.com  | mobile : +94 766819985
>
>



-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: Keeping Duplicate config files

Posted by Nirmal Fernando <ni...@gmail.com>.
Does this solve the problem? Isn't the problem we're trying to solve is
that people forget to edit the changes in both the places that particular
file been used? Even if we use 1 file, still the person who changes that
file need to update the installer scripts to add this new change.


On Wed, Aug 20, 2014 at 2:10 PM, Reka Thirunavukkarasu <re...@wso2.com>
wrote:

> +1 for Lahiru' suggestion. In that way it will be more consistent. Whoever
> touches the configuration file in the product, just need to make sure
> whether the referred XML tags is properly updated in the stratos installer.
>
> Thanks,
> Reka
>
>
> On Wed, Aug 20, 2014 at 12:14 PM, Akila Ravihansa Perera <
> ravihansa@wso2.com> wrote:
>
>> IMO, we shouldn't replicate config files in stratos-installer. I agree
>> with Lahiru's suggestion. We can keep the XML files in product modules
>> and write to those files by looking up XML tags. We need to get rid of
>> those place holders.
>>
>> On Wed, Aug 20, 2014 at 12:07 PM, Sajith Kariyawasam <sa...@wso2.com>
>> wrote:
>> >
>> > On Wed, Aug 20, 2014 at 12:01 PM, Sajith Kariyawasam <sa...@wso2.com>
>> > wrote:
>> >>
>> >> How about if we keep the config files inside product distribution, and
>> we
>> >> write a script in stratos-installer to copy / replace config files from
>> >> original location (product distribution) to stratos-installer 's config
>> >> directory?
>> >>
>> >>
>> > Sorry, my suggestion wouldn't work, I didn't notice that the config
>> files
>> > which are in stratos-installer having place holders
>> >
>> >>
>> >> On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <
>> nirmal070125@gmail.com>
>> >> wrote:
>> >>>
>> >>> I think we have to maintain it in two places otherwise if the file
>> isn't
>> >>> there in the product distribution, product would fail to start and
>> also
>> >>> since we're using place holders in the config files inside the
>> installer,
>> >>> some of those could cause failures when parsing the XML.
>> >>>
>> >>>
>> >>> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com>
>> >>> wrote:
>> >>>>
>> >>>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
>> >>>> wrote:
>> >>>>>
>> >>>>> Do we recommend to use the Stratos product build itself without
>> using
>> >>>>> the Stratos installer?
>> >>>>
>> >>>> yes. If we configure and start stratos manually, that process will
>> not
>> >>>> use configuration files which are inside stratos installer.
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>> If we recommed to use the Stratos installer every time,IMO we can
>> >>>>> maintain the config in separately in stratus installer and in setup
>> time we
>> >>>>> can add them appropriately.
>> >>>>>
>> >>>>> Thanks,
>> >>>>> Gayan
>> >>>>>
>> >>>>>
>> >>>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com>
>> >>>>> wrote:
>> >>>>>>
>> >>>>>> Hi,
>> >>>>>>
>> >>>>>> We have duplicates some product configurations files, one inside
>> >>>>>> product and one in stratos-installer. At the boot time (when
>> setup.sh is
>> >>>>>> executed) config files inside products will be replaced by the
>> config files
>> >>>>>> inside stratos-installer.
>> >>>>>> Maintaining duplicate config files become an overhead when a
>> parameter
>> >>>>>> is added to the config files in the product, it has to be added to
>> the other
>> >>>>>> copy as well. Otherwise it may be missing at deployment time. This
>> occurred
>> >>>>>> for expiryTimeout recently in autoscaler.xml
>> >>>>>>
>> >>>>>> Possible solutions:
>> >>>>>> Replicate the changes as we do now,
>> >>>>>> Maintain only the config file in stratos-installer
>> >>>>
>> >>>> +1 to having all configurations in startos installer and referred
>> those
>> >>>> when building product. But this will provide the control over only
>> for the
>> >>>> configuration files which are used only in startos components not
>> for files
>> >>>> such as carbon.xml, etc. If so we have to keep duplicates for those
>> >>>> (non-stratos config files)
>> >>>>
>> >>>>>> or any other idea?
>> >>>>>>
>> >>>>>> --
>> >>>>>>
>> >>>>>> Udara Liyanage
>> >>>>>> Software Engineer
>> >>>>>> WSO2, Inc.: http://wso2.com
>> >>>>>> lean. enterprise. middleware
>> >>>>>>
>> >>>>>> web: http://udaraliyanage.wordpress.com
>> >>>>>> phone: +94 71 443 6897
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>> --
>> >>>>> Best Regards,
>> >>>>>
>> >>>>> Gayan Gunarathne
>> >>>>> Technical Lead
>> >>>>> WSO2 Inc. (http://wso2.com)
>> >>>>> email  : gayang@wso2.com  | mobile : +94 766819985
>> >>>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>> --
>> >>>> Dinesh Bandara
>> >>>> Software Engineer
>> >>>> WSO2 Inc.; http://wso2.com
>> >>>> lean.enterprise.middleware
>> >>>>
>> >>>
>> >>>
>> >>>
>> >>> --
>> >>> Best Regards,
>> >>> Nirmal
>> >>>
>> >>> Nirmal Fernando.
>> >>> PPMC Member & Committer of Apache Stratos,
>> >>> Senior Software Engineer, WSO2 Inc.
>> >>>
>> >>> Blog: http://nirmalfdo.blogspot.com/
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >> --
>> >> Sajith Kariyawasam
>> >> Mobile: +94772269575
>> >
>> >
>> >
>> >
>> > --
>> > --
>> > Sajith Kariyawasam
>> > Mobile: +94772269575
>>
>>
>>
>> --
>> Akila Ravihansa Perera
>> WSO2 Inc
>>
>> Blog: http://ravihansa3000.blogspot.com
>>
>
>
>
> --
> Reka Thirunavukkarasu
> Senior Software Engineer,
> WSO2, Inc.:http://wso2.com,
> Mobile: +94776442007
>
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: Keeping Duplicate config files

Posted by Reka Thirunavukkarasu <re...@wso2.com>.
+1 for Lahiru' suggestion. In that way it will be more consistent. Whoever
touches the configuration file in the product, just need to make sure
whether the referred XML tags is properly updated in the stratos installer.

Thanks,
Reka


On Wed, Aug 20, 2014 at 12:14 PM, Akila Ravihansa Perera <ravihansa@wso2.com
> wrote:

> IMO, we shouldn't replicate config files in stratos-installer. I agree
> with Lahiru's suggestion. We can keep the XML files in product modules
> and write to those files by looking up XML tags. We need to get rid of
> those place holders.
>
> On Wed, Aug 20, 2014 at 12:07 PM, Sajith Kariyawasam <sa...@wso2.com>
> wrote:
> >
> > On Wed, Aug 20, 2014 at 12:01 PM, Sajith Kariyawasam <sa...@wso2.com>
> > wrote:
> >>
> >> How about if we keep the config files inside product distribution, and
> we
> >> write a script in stratos-installer to copy / replace config files from
> >> original location (product distribution) to stratos-installer 's config
> >> directory?
> >>
> >>
> > Sorry, my suggestion wouldn't work, I didn't notice that the config files
> > which are in stratos-installer having place holders
> >
> >>
> >> On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <
> nirmal070125@gmail.com>
> >> wrote:
> >>>
> >>> I think we have to maintain it in two places otherwise if the file
> isn't
> >>> there in the product distribution, product would fail to start and also
> >>> since we're using place holders in the config files inside the
> installer,
> >>> some of those could cause failures when parsing the XML.
> >>>
> >>>
> >>> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com>
> >>> wrote:
> >>>>
> >>>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
> >>>> wrote:
> >>>>>
> >>>>> Do we recommend to use the Stratos product build itself without using
> >>>>> the Stratos installer?
> >>>>
> >>>> yes. If we configure and start stratos manually, that process will not
> >>>> use configuration files which are inside stratos installer.
> >>>>>
> >>>>>
> >>>>>
> >>>>> If we recommed to use the Stratos installer every time,IMO we can
> >>>>> maintain the config in separately in stratus installer and in setup
> time we
> >>>>> can add them appropriately.
> >>>>>
> >>>>> Thanks,
> >>>>> Gayan
> >>>>>
> >>>>>
> >>>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com>
> >>>>> wrote:
> >>>>>>
> >>>>>> Hi,
> >>>>>>
> >>>>>> We have duplicates some product configurations files, one inside
> >>>>>> product and one in stratos-installer. At the boot time (when
> setup.sh is
> >>>>>> executed) config files inside products will be replaced by the
> config files
> >>>>>> inside stratos-installer.
> >>>>>> Maintaining duplicate config files become an overhead when a
> parameter
> >>>>>> is added to the config files in the product, it has to be added to
> the other
> >>>>>> copy as well. Otherwise it may be missing at deployment time. This
> occurred
> >>>>>> for expiryTimeout recently in autoscaler.xml
> >>>>>>
> >>>>>> Possible solutions:
> >>>>>> Replicate the changes as we do now,
> >>>>>> Maintain only the config file in stratos-installer
> >>>>
> >>>> +1 to having all configurations in startos installer and referred
> those
> >>>> when building product. But this will provide the control over only
> for the
> >>>> configuration files which are used only in startos components not for
> files
> >>>> such as carbon.xml, etc. If so we have to keep duplicates for those
> >>>> (non-stratos config files)
> >>>>
> >>>>>> or any other idea?
> >>>>>>
> >>>>>> --
> >>>>>>
> >>>>>> Udara Liyanage
> >>>>>> Software Engineer
> >>>>>> WSO2, Inc.: http://wso2.com
> >>>>>> lean. enterprise. middleware
> >>>>>>
> >>>>>> web: http://udaraliyanage.wordpress.com
> >>>>>> phone: +94 71 443 6897
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>> --
> >>>>> Best Regards,
> >>>>>
> >>>>> Gayan Gunarathne
> >>>>> Technical Lead
> >>>>> WSO2 Inc. (http://wso2.com)
> >>>>> email  : gayang@wso2.com  | mobile : +94 766819985
> >>>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> --
> >>>> Dinesh Bandara
> >>>> Software Engineer
> >>>> WSO2 Inc.; http://wso2.com
> >>>> lean.enterprise.middleware
> >>>>
> >>>
> >>>
> >>>
> >>> --
> >>> Best Regards,
> >>> Nirmal
> >>>
> >>> Nirmal Fernando.
> >>> PPMC Member & Committer of Apache Stratos,
> >>> Senior Software Engineer, WSO2 Inc.
> >>>
> >>> Blog: http://nirmalfdo.blogspot.com/
> >>
> >>
> >>
> >>
> >> --
> >> --
> >> Sajith Kariyawasam
> >> Mobile: +94772269575
> >
> >
> >
> >
> > --
> > --
> > Sajith Kariyawasam
> > Mobile: +94772269575
>
>
>
> --
> Akila Ravihansa Perera
> WSO2 Inc
>
> Blog: http://ravihansa3000.blogspot.com
>



-- 
Reka Thirunavukkarasu
Senior Software Engineer,
WSO2, Inc.:http://wso2.com,
Mobile: +94776442007

Re: Keeping Duplicate config files

Posted by Akila Ravihansa Perera <ra...@wso2.com>.
IMO, we shouldn't replicate config files in stratos-installer. I agree
with Lahiru's suggestion. We can keep the XML files in product modules
and write to those files by looking up XML tags. We need to get rid of
those place holders.

On Wed, Aug 20, 2014 at 12:07 PM, Sajith Kariyawasam <sa...@wso2.com> wrote:
>
> On Wed, Aug 20, 2014 at 12:01 PM, Sajith Kariyawasam <sa...@wso2.com>
> wrote:
>>
>> How about if we keep the config files inside product distribution, and we
>> write a script in stratos-installer to copy / replace config files from
>> original location (product distribution) to stratos-installer 's config
>> directory?
>>
>>
> Sorry, my suggestion wouldn't work, I didn't notice that the config files
> which are in stratos-installer having place holders
>
>>
>> On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <ni...@gmail.com>
>> wrote:
>>>
>>> I think we have to maintain it in two places otherwise if the file isn't
>>> there in the product distribution, product would fail to start and also
>>> since we're using place holders in the config files inside the installer,
>>> some of those could cause failures when parsing the XML.
>>>
>>>
>>> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com>
>>> wrote:
>>>>
>>>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
>>>> wrote:
>>>>>
>>>>> Do we recommend to use the Stratos product build itself without using
>>>>> the Stratos installer?
>>>>
>>>> yes. If we configure and start stratos manually, that process will not
>>>> use configuration files which are inside stratos installer.
>>>>>
>>>>>
>>>>>
>>>>> If we recommed to use the Stratos installer every time,IMO we can
>>>>> maintain the config in separately in stratus installer and in setup time we
>>>>> can add them appropriately.
>>>>>
>>>>> Thanks,
>>>>> Gayan
>>>>>
>>>>>
>>>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com>
>>>>> wrote:
>>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> We have duplicates some product configurations files, one inside
>>>>>> product and one in stratos-installer. At the boot time (when setup.sh is
>>>>>> executed) config files inside products will be replaced by the config files
>>>>>> inside stratos-installer.
>>>>>> Maintaining duplicate config files become an overhead when a parameter
>>>>>> is added to the config files in the product, it has to be added to the other
>>>>>> copy as well. Otherwise it may be missing at deployment time. This occurred
>>>>>> for expiryTimeout recently in autoscaler.xml
>>>>>>
>>>>>> Possible solutions:
>>>>>> Replicate the changes as we do now,
>>>>>> Maintain only the config file in stratos-installer
>>>>
>>>> +1 to having all configurations in startos installer and referred those
>>>> when building product. But this will provide the control over only for the
>>>> configuration files which are used only in startos components not for files
>>>> such as carbon.xml, etc. If so we have to keep duplicates for those
>>>> (non-stratos config files)
>>>>
>>>>>> or any other idea?
>>>>>>
>>>>>> --
>>>>>>
>>>>>> Udara Liyanage
>>>>>> Software Engineer
>>>>>> WSO2, Inc.: http://wso2.com
>>>>>> lean. enterprise. middleware
>>>>>>
>>>>>> web: http://udaraliyanage.wordpress.com
>>>>>> phone: +94 71 443 6897
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>>
>>>>> Gayan Gunarathne
>>>>> Technical Lead
>>>>> WSO2 Inc. (http://wso2.com)
>>>>> email  : gayang@wso2.com  | mobile : +94 766819985
>>>>>
>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Dinesh Bandara
>>>> Software Engineer
>>>> WSO2 Inc.; http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>
>>
>>
>>
>> --
>> --
>> Sajith Kariyawasam
>> Mobile: +94772269575
>
>
>
>
> --
> --
> Sajith Kariyawasam
> Mobile: +94772269575



-- 
Akila Ravihansa Perera
WSO2 Inc

Blog: http://ravihansa3000.blogspot.com

Re: Keeping Duplicate config files

Posted by Sajith Kariyawasam <sa...@wso2.com>.
On Wed, Aug 20, 2014 at 12:01 PM, Sajith Kariyawasam <sa...@wso2.com>
wrote:

> How about if we keep the config files inside product distribution, and we
> write a script in stratos-installer to copy / replace config files from
> original location (product distribution) to stratos-installer 's config
> directory?
>
>
> Sorry, my suggestion wouldn't work, I didn't notice that the config files
which are in stratos-installer having place holders


> On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <ni...@gmail.com>
> wrote:
>
>> I think we have to maintain it in two places otherwise if the file isn't
>> there in the product distribution, product would fail to start and also
>> since we're using place holders in the config files inside the installer,
>> some of those could cause failures when parsing the XML.
>>
>>
>> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com>
>> wrote:
>>
>>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
>>> wrote:
>>>
>>>> Do we recommend to use the Stratos product build itself without using
>>>> the Stratos installer?
>>>>
>>> yes. If we configure and start stratos manually, that process will not
>>> use configuration files which are inside stratos installer.
>>>
>>>>
>>>>
>>> If we recommed to use the Stratos installer every time,IMO we can
>>>> maintain the config in separately in stratus installer and in setup time we
>>>> can add them appropriately.
>>>>
>>>> Thanks,
>>>> Gayan
>>>>
>>>>
>>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> We have duplicates some product configurations files, one inside
>>>>> product and one in stratos-installer. At the boot time (when setup.sh is
>>>>> executed) config files inside products will be replaced by the config files
>>>>> inside stratos-installer.
>>>>> Maintaining duplicate config files become an overhead when a parameter
>>>>> is added to the config files in the product, it has to be added to the
>>>>> other copy as well. Otherwise it may be missing at deployment time. This
>>>>> occurred for expiryTimeout recently in autoscaler.xml
>>>>>
>>>>> Possible solutions:
>>>>> Replicate the changes as we do now,
>>>>> Maintain only the config file in stratos-installer
>>>>>
>>>> +1 to having all configurations in startos installer and referred those
>>> when building product. But this will provide the control over only for the
>>> configuration files which are used only in startos components not for files
>>> such as carbon.xml, etc. If so we have to keep duplicates for those
>>> (non-stratos config files)
>>>
>>> or any other idea?
>>>>>
>>>>> --
>>>>>
>>>>> Udara Liyanage
>>>>> Software Engineer
>>>>> WSO2, Inc.: http://wso2.com
>>>>> lean. enterprise. middleware
>>>>>
>>>>> web: http://udaraliyanage.wordpress.com
>>>>> phone: +94 71 443 6897
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>>
>>>> Gayan Gunarathne
>>>> Technical Lead
>>>> WSO2 Inc. (http://wso2.com)
>>>> email  : gayang@wso2.com  | mobile : +94 766819985
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> *Dinesh Bandara*
>>> Software Engineer
>>> WSO2 Inc.; http://wso2.com
>>> lean.enterprise.middleware
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> *--*
> *Sajith Kariyawasam*
> *Mobile: +94772269575 <%2B94772269575>*
>



-- 
*--*
*Sajith Kariyawasam*
*Mobile: +94772269575*

Re: Keeping Duplicate config files

Posted by Sajith Kariyawasam <sa...@wso2.com>.
How about if we keep the config files inside product distribution, and we
write a script in stratos-installer to copy / replace config files from
original location (product distribution) to stratos-installer 's config
directory?


On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <ni...@gmail.com>
wrote:

> I think we have to maintain it in two places otherwise if the file isn't
> there in the product distribution, product would fail to start and also
> since we're using place holders in the config files inside the installer,
> some of those could cause failures when parsing the XML.
>
>
> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com> wrote:
>
>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
>> wrote:
>>
>>> Do we recommend to use the Stratos product build itself without using
>>> the Stratos installer?
>>>
>> yes. If we configure and start stratos manually, that process will not
>> use configuration files which are inside stratos installer.
>>
>>>
>>>
>> If we recommed to use the Stratos installer every time,IMO we can
>>> maintain the config in separately in stratus installer and in setup time we
>>> can add them appropriately.
>>>
>>> Thanks,
>>> Gayan
>>>
>>>
>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> We have duplicates some product configurations files, one inside
>>>> product and one in stratos-installer. At the boot time (when setup.sh is
>>>> executed) config files inside products will be replaced by the config files
>>>> inside stratos-installer.
>>>> Maintaining duplicate config files become an overhead when a parameter
>>>> is added to the config files in the product, it has to be added to the
>>>> other copy as well. Otherwise it may be missing at deployment time. This
>>>> occurred for expiryTimeout recently in autoscaler.xml
>>>>
>>>> Possible solutions:
>>>> Replicate the changes as we do now,
>>>> Maintain only the config file in stratos-installer
>>>>
>>> +1 to having all configurations in startos installer and referred those
>> when building product. But this will provide the control over only for the
>> configuration files which are used only in startos components not for files
>> such as carbon.xml, etc. If so we have to keep duplicates for those
>> (non-stratos config files)
>>
>> or any other idea?
>>>>
>>>> --
>>>>
>>>> Udara Liyanage
>>>> Software Engineer
>>>> WSO2, Inc.: http://wso2.com
>>>> lean. enterprise. middleware
>>>>
>>>> web: http://udaraliyanage.wordpress.com
>>>> phone: +94 71 443 6897
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>>
>>> Gayan Gunarathne
>>> Technical Lead
>>> WSO2 Inc. (http://wso2.com)
>>> email  : gayang@wso2.com  | mobile : +94 766819985
>>>
>>>
>>
>>
>>
>> --
>> *Dinesh Bandara*
>> Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
*--*
*Sajith Kariyawasam*
*Mobile: +94772269575*

Re: Keeping Duplicate config files

Posted by Shiroshica Kulatilake <sh...@wso2.com>.
If one set has placeholders then they are ideally not duplicates right ?

For exact duplicates would having a git post-commit hook be a solution ?


On Wed, Aug 20, 2014 at 11:46 AM, Nirmal Fernando <ni...@gmail.com>
wrote:

> I think we have to maintain it in two places otherwise if the file isn't
> there in the product distribution, product would fail to start and also
> since we're using place holders in the config files inside the installer,
> some of those could cause failures when parsing the XML.
>
>
> On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com> wrote:
>
>> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
>> wrote:
>>
>>> Do we recommend to use the Stratos product build itself without using
>>> the Stratos installer?
>>>
>> yes. If we configure and start stratos manually, that process will not
>> use configuration files which are inside stratos installer.
>>
>>>
>>>
>> If we recommed to use the Stratos installer every time,IMO we can
>>> maintain the config in separately in stratus installer and in setup time we
>>> can add them appropriately.
>>>
>>> Thanks,
>>> Gayan
>>>
>>>
>>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> We have duplicates some product configurations files, one inside
>>>> product and one in stratos-installer. At the boot time (when setup.sh is
>>>> executed) config files inside products will be replaced by the config files
>>>> inside stratos-installer.
>>>> Maintaining duplicate config files become an overhead when a parameter
>>>> is added to the config files in the product, it has to be added to the
>>>> other copy as well. Otherwise it may be missing at deployment time. This
>>>> occurred for expiryTimeout recently in autoscaler.xml
>>>>
>>>> Possible solutions:
>>>> Replicate the changes as we do now,
>>>> Maintain only the config file in stratos-installer
>>>>
>>> +1 to having all configurations in startos installer and referred those
>> when building product. But this will provide the control over only for the
>> configuration files which are used only in startos components not for files
>> such as carbon.xml, etc. If so we have to keep duplicates for those
>> (non-stratos config files)
>>
>> or any other idea?
>>>>
>>>> --
>>>>
>>>> Udara Liyanage
>>>> Software Engineer
>>>> WSO2, Inc.: http://wso2.com
>>>> lean. enterprise. middleware
>>>>
>>>> web: http://udaraliyanage.wordpress.com
>>>> phone: +94 71 443 6897
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>>
>>> Gayan Gunarathne
>>> Technical Lead
>>> WSO2 Inc. (http://wso2.com)
>>> email  : gayang@wso2.com  | mobile : +94 766819985
>>>
>>>
>>
>>
>>
>> --
>> *Dinesh Bandara*
>> Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
Shiroshica Kulatilake

Architect,
WSO2, Inc. http://wso2.com/
Phone: +94 776523867

Re: Keeping Duplicate config files

Posted by Nirmal Fernando <ni...@gmail.com>.
I think we have to maintain it in two places otherwise if the file isn't
there in the product distribution, product would fail to start and also
since we're using place holders in the config files inside the installer,
some of those could cause failures when parsing the XML.


On Wed, Aug 20, 2014 at 11:36 AM, Dinesh Bandara <di...@wso2.com> wrote:

> On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com>
> wrote:
>
>> Do we recommend to use the Stratos product build itself without using the
>> Stratos installer?
>>
> yes. If we configure and start stratos manually, that process will not use
> configuration files which are inside stratos installer.
>
>>
>>
> If we recommed to use the Stratos installer every time,IMO we can maintain
>> the config in separately in stratus installer and in setup time we can add
>> them appropriately.
>>
>> Thanks,
>> Gayan
>>
>>
>> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>>
>>> Hi,
>>>
>>> We have duplicates some product configurations files, one inside product
>>> and one in stratos-installer. At the boot time (when setup.sh is executed)
>>> config files inside products will be replaced by the config files inside
>>> stratos-installer.
>>> Maintaining duplicate config files become an overhead when a parameter
>>> is added to the config files in the product, it has to be added to the
>>> other copy as well. Otherwise it may be missing at deployment time. This
>>> occurred for expiryTimeout recently in autoscaler.xml
>>>
>>> Possible solutions:
>>> Replicate the changes as we do now,
>>> Maintain only the config file in stratos-installer
>>>
>> +1 to having all configurations in startos installer and referred those
> when building product. But this will provide the control over only for the
> configuration files which are used only in startos components not for files
> such as carbon.xml, etc. If so we have to keep duplicates for those
> (non-stratos config files)
>
> or any other idea?
>>>
>>> --
>>>
>>> Udara Liyanage
>>> Software Engineer
>>> WSO2, Inc.: http://wso2.com
>>> lean. enterprise. middleware
>>>
>>> web: http://udaraliyanage.wordpress.com
>>> phone: +94 71 443 6897
>>>
>>
>>
>>
>> --
>> Best Regards,
>>
>> Gayan Gunarathne
>> Technical Lead
>> WSO2 Inc. (http://wso2.com)
>> email  : gayang@wso2.com  | mobile : +94 766819985
>>
>>
>
>
>
> --
> *Dinesh Bandara*
> Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: Keeping Duplicate config files

Posted by Dinesh Bandara <di...@wso2.com>.
On Wed, Aug 20, 2014 at 11:00 AM, Gayan Gunarathne <ga...@wso2.com> wrote:

> Do we recommend to use the Stratos product build itself without using the
> Stratos installer?
>
yes. If we configure and start stratos manually, that process will not use
configuration files which are inside stratos installer.

>
>
If we recommed to use the Stratos installer every time,IMO we can maintain
> the config in separately in stratus installer and in setup time we can add
> them appropriately.
>
> Thanks,
> Gayan
>
>
> On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:
>
>> Hi,
>>
>> We have duplicates some product configurations files, one inside product
>> and one in stratos-installer. At the boot time (when setup.sh is executed)
>> config files inside products will be replaced by the config files inside
>> stratos-installer.
>> Maintaining duplicate config files become an overhead when a parameter is
>> added to the config files in the product, it has to be added to the other
>> copy as well. Otherwise it may be missing at deployment time. This occurred
>> for expiryTimeout recently in autoscaler.xml
>>
>> Possible solutions:
>> Replicate the changes as we do now,
>> Maintain only the config file in stratos-installer
>>
> +1 to having all configurations in startos installer and referred those
when building product. But this will provide the control over only for the
configuration files which are used only in startos components not for files
such as carbon.xml, etc. If so we have to keep duplicates for those
(non-stratos config files)

or any other idea?
>>
>> --
>>
>> Udara Liyanage
>> Software Engineer
>> WSO2, Inc.: http://wso2.com
>> lean. enterprise. middleware
>>
>> web: http://udaraliyanage.wordpress.com
>> phone: +94 71 443 6897
>>
>
>
>
> --
> Best Regards,
>
> Gayan Gunarathne
> Technical Lead
> WSO2 Inc. (http://wso2.com)
> email  : gayang@wso2.com  | mobile : +94 766819985
>
>



-- 
*Dinesh Bandara*
Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

Re: Keeping Duplicate config files

Posted by Gayan Gunarathne <ga...@wso2.com>.
Do we recommend to use the Stratos product build itself without using the
Stratos installer?

If we recommed to use the Stratos installer every time,IMO we can maintain
the config in separately in stratus installer and in setup time we can add
them appropriately.

Thanks,
Gayan


On Wed, Aug 20, 2014 at 10:34 AM, Udara Liyanage <ud...@wso2.com> wrote:

> Hi,
>
> We have duplicates some product configurations files, one inside product
> and one in stratos-installer. At the boot time (when setup.sh is executed)
> config files inside products will be replaced by the config files inside
> stratos-installer.
> Maintaining duplicate config files become an overhead when a parameter is
> added to the config files in the product, it has to be added to the other
> copy as well. Otherwise it may be missing at deployment time. This occurred
> for expiryTimeout recently in autoscaler.xml
>
> Possible solutions:
> Replicate the changes as we do now,
> Maintain only the config file in stratos-installer
> or any other idea?
>
> --
>
> Udara Liyanage
> Software Engineer
> WSO2, Inc.: http://wso2.com
> lean. enterprise. middleware
>
> web: http://udaraliyanage.wordpress.com
> phone: +94 71 443 6897
>



-- 
Best Regards,

Gayan Gunarathne
Technical Lead
WSO2 Inc. (http://wso2.com)
email  : gayang@wso2.com  | mobile : +94 766819985