Hi Sarubi,

I have a couple of questions regarding the fit between the changes that
this script does and the config automation tools.

Is this a tool focused on evaluation part of the product or the deployment
part? IMO both would require a re-evaluation of the approach.

IIUC, this script would alter the startup pack, with file additions and
removals done to config files, deployable artifacts, and other library
files. This could be a problematic case for continuous config automation
story.

Consider a scenario where Puppet (or any other tool) configures a set of
instances, using the APIM pack as the root. The tool might be configured to
continuously run (say, with a 30-minute interval). Is there a chance for
the server to be reconfigured every time the tool is run, because the tool
detects the changes that this script does at the startup, as changes that
should be rolled back?  In that case, it might be better to have this tool
as a separate script rather than one which starts up the server as well.

Another point against such a tool bound to server startup would be the
mixing of concerns. AFAIU, what this script does falls under what the
config automation tools do. IMO WSO2 server startup scripts should only
work on the bootstrapping of the server runtime, rather than the config
automation part. Also, we would essentially be repeating what the config
automation tools should do, but in Bash which sometimes is a lot harder.
Obtaining config values, managing them meaningfully, and applying them to
files is essentially what a config automation tool does. We may be
re-inventing the wheel here. For an example, should this tool be concerned
about the port offset at all since even dev deployments will be done using
separate VMs/Containers? Or should it be worried about different values for
the config options in different environments?

Additionally, users who manage config automation usually adhere to one set
of scripts. Puppet users almost always go for Puppet, Chef users for Chef
etc. What we would be delivering might step on what they already have, or
are comfortable working with, and in turn, the adaption rate might take a
hit.

IMO you might benefit from reviewing your approach with the Installation
Experience effort, as the responsibilities of this tool fall close to, if
not overlap with, what the Installation Experience scripts deliver/would
deliver with different providers.

WDYT?


Regards,
Chamila de Alwis
Committer and PMC Member - Apache Stratos
Associate Technical Lead | WSO2
+94 77 220 7163
Blog: https://medium.com/@chamilad




On Sun, Jun 3, 2018 at 9:24 PM Sarubi Thillainathan <[email protected]> wrote:

> Hi Prasanna/All,
>
> These are the points and improvements that we discussed at the review
> meeting (prepared by Thilini).
>
>    - Print logs for each action and failures
>    - Alter the script in order to handle already completed actions. For
>    example, if the script was executed for multiple times, print a log and
>    skip already completed actions like webapp copying/removing, print a log
>    - Do a server startup time comparison with and without the
>    optimizations
>    - Test throttling feature with optimization
>    - Provide the option to invoke the profile optimization shell script
>    during startup also
>    - Change the logic and separate out each profile optimization
>    - Remove authenticationendpoint.war from gateway, publisher and store
>    profiles
>    - Remove calculator webapp from all profiles
>    - Remove micro gateway from the build and the publisher profile
>    - Avoid registry indexing from gateway and traffic manager. Add a note
>    in the documentation on how to enable indexing, in a case whether the
>    indexing is required in the gateway.
>    - Remove synapse configs from km, publisher and traffic manager
>    - Set optimized = true option in the script.
>
> Mail thread can be found in [1].
>
>
> [1]Updated invitation: [APIM] [REVIEW] Tool to configure changes while
> starting an API-M profile
>
> On Sun, Jun 3, 2018 at 12:17 AM, Prasanna Dangalla <[email protected]>
> wrote:
>
>> Hi Sarubi,
>>
>> Shall we add the points and improvements that we discussed recently ti
>> this mail thread.
>>
>> Further make sure the tool will not fail if you run it multiple times for
>> the same profile.
>>
>> Thanks
>> Prasanna
>>
>> On Fri, Jun 1, 2018 at 5:42 PM Chamin Dias <[email protected]> wrote:
>>
>>> Hi,
>>>
>>> How are we going to maintain the code for this? Are we going to maintain
>>> this like the import-export tool
>>> <https://github.com/wso2/product-apim/tree/v2.2.0/modules/api-import-export>
>>> or are we going to maintain it separately (another repo maybe)?
>>>
>>> Thanks.
>>>
>>> On Fri, Jun 1, 2018 at 11:38 AM, Sarubi Thillainathan <[email protected]>
>>> wrote:
>>>
>>>> Adding architecture
>>>>
>>>> On Thu, May 31, 2018 at 10:00 AM, Sarubi Thillainathan <[email protected]
>>>> > wrote:
>>>>
>>>>> Hi Naduni,
>>>>>
>>>>> Currently, I'm handling port offsets as passing an environment
>>>>> variable when starting the server only if the user wants to change the 
>>>>> port.
>>>>>
>>>>>
>>>>> Thanks
>>>>>
>>>>> On Wed, May 30, 2018 at 12:26 PM, Dinusha Dissanayake <
>>>>> [email protected]> wrote:
>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, May 30, 2018 at 12:13 PM, Naduni Pamudika <[email protected]>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi Sarubi,
>>>>>>>
>>>>>>> How are you going to handle port offsets for the profiles? I think
>>>>>>> rather than reading the offset from the carbon.xml file, it would be 
>>>>>>> easy
>>>>>>> to give it as a parameter when running the script. We can make this
>>>>>>> parameter optional. Otherwise the user has to update carbon.xml file 
>>>>>>> before
>>>>>>> running the script and I do not see any reason for doing it as we are
>>>>>>> automating the process here.
>>>>>>>
>>>>>> Port offset can be passed as a environment variable  like we do *sh
>>>>>> wso2server.sh -DportOffset={offset}*. I am not sure if it is the
>>>>>> best way to do this.
>>>>>>
>>>>>>> Thanks,
>>>>>>> Naduni
>>>>>>>
>>>>>>> On Wed, May 30, 2018 at 11:45 AM, Dinusha Dissanayake <
>>>>>>> [email protected]> wrote:
>>>>>>>
>>>>>>>> Hi Krishan/All,
>>>>>>>>
>>>>>>>> On Wed, May 30, 2018 at 11:35 AM, Krishan Wijesena <
>>>>>>>> [email protected]> wrote:
>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, May 30, 2018 at 10:51 AM, Sarubi Thillainathan <
>>>>>>>>> [email protected]> wrote:
>>>>>>>>>
>>>>>>>>>> Hi Fazlan,
>>>>>>>>>>
>>>>>>>>>> Yes, it's a shell script. As per the discussion with Nuwan, we
>>>>>>>>>> have planned that user have to manually run the script file 
>>>>>>>>>> according to
>>>>>>>>>> his/her profile preference before starting the server.
>>>>>>>>>>
>>>>>>>>>    how about starting the server using the same script. If some
>>>>>>>>> one want to run KM profile, user just want to execute the script with
>>>>>>>>> prefered configurations for KM.
>>>>>>>>>
>>>>>>>> AFAIR, this is going to remove unnecessary web apps and do the
>>>>>>>> necessary configuration. If there are using tools like "chef" or 
>>>>>>>> "yajsw"
>>>>>>>> for there further configurations , then starting the server using the 
>>>>>>>> same
>>>>>>>> script might not be ideal.
>>>>>>>>
>>>>>>>> Thanks,
>>>>>>>> DinushaD.
>>>>>>>>
>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, May 30, 2018 at 10:39 AM, Fazlan Nazeem <[email protected]
>>>>>>>>>> > wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi Sarubi,
>>>>>>>>>>>
>>>>>>>>>>> Is this going to be a shell script?
>>>>>>>>>>>
>>>>>>>>>>> If so how are you planning to execute this? Does the user have
>>>>>>>>>>> to manually run the script before starting the server with the 
>>>>>>>>>>> profile or
>>>>>>>>>>> will the script execution be automatically executed when we start 
>>>>>>>>>>> the
>>>>>>>>>>> server with the profile?
>>>>>>>>>>>
>>>>>>>>>>> On Wed, May 30, 2018 at 10:34 AM, Sarubi Thillainathan <
>>>>>>>>>>> [email protected]> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi all,
>>>>>>>>>>>> I am working on a project to optimize the API-M profiles by
>>>>>>>>>>>> automating the configuration changes while starting an API-M 
>>>>>>>>>>>> profile.
>>>>>>>>>>>> According to the user input, perform corresponding profile set up 
>>>>>>>>>>>> for the
>>>>>>>>>>>> wso2am-2.5.0-SNAPSHOT on both Unix and Windows environments.
>>>>>>>>>>>>
>>>>>>>>>>>> Please find the milestone plan in [1] for the project $Subject.
>>>>>>>>>>>>
>>>>>>>>>>>> Comments or Suggestions are highly appreciated.
>>>>>>>>>>>>
>>>>>>>>>>>> [1]
>>>>>>>>>>>> https://docs.google.com/spreadsheets/d/1C7UyD1e3JvPM17ZpivwDjboL8GX2CD5ZF1B3QTBhFaU/edit?usp=sharing
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks,
>>>>>>>>>>>> --
>>>>>>>>>>>> *Sarubi Thillainathan *
>>>>>>>>>>>> *Software Engineer - WSO2 Inc.*
>>>>>>>>>>>>
>>>>>>>>>>>> *Mobile : +94 (0) 76 68 49 101*
>>>>>>>>>>>> --
>>>>>>>>>>>> You received this message because you are subscribed to the
>>>>>>>>>>>> Google Groups "WSO2 Engineering Group" group.
>>>>>>>>>>>> To unsubscribe from this group and stop receiving emails from
>>>>>>>>>>>> it, send an email to [email protected].
>>>>>>>>>>>> For more options, visit
>>>>>>>>>>>> https://groups.google.com/a/wso2.com/d/optout.
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Thanks & Regards,
>>>>>>>>>>>
>>>>>>>>>>> *Fazlan Nazeem*
>>>>>>>>>>> Senior Software Engineer
>>>>>>>>>>> WSO2 Inc
>>>>>>>>>>> Mobile : +94772338839
>>>>>>>>>>> [email protected]
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> *Sarubi Thillainathan *
>>>>>>>>>> *Software Engineer - WSO2 Inc.*
>>>>>>>>>>
>>>>>>>>>> *Mobile : +94 (0) 76 68 49 101*
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> You received this message because you are subscribed to the
>>>>>>>>>> Google Groups "WSO2 Engineering Group" group.
>>>>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>>>>> send an email to [email protected].
>>>>>>>>>> For more options, visit
>>>>>>>>>> https://groups.google.com/a/wso2.com/d/optout.
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>>> *Krishan Wijesena*
>>>>>>>>> Software Engineer | WSO2
>>>>>>>>>
>>>>>>>>> Email : [email protected]
>>>>>>>>> Mobile : +94776219923
>>>>>>>>> WSO2 Inc : http://wso2.com
>>>>>>>>> [image: http://wso2.com/signature] <http://wso2.com/signature>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> You received this message because you are subscribed to the Google
>>>>>>>>> Groups "WSO2 Engineering Group" group.
>>>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>>>> send an email to [email protected].
>>>>>>>>> For more options, visit
>>>>>>>>> https://groups.google.com/a/wso2.com/d/optout.
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Dinusha Dissanayake
>>>>>>>> Software Engineer
>>>>>>>> WSO2 Inc
>>>>>>>> Mobile: +94712939439
>>>>>>>> <https://wso2.com/signature>
>>>>>>>>
>>>>>>>> --
>>>>>>>> You received this message because you are subscribed to the Google
>>>>>>>> Groups "WSO2 Engineering Group" group.
>>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>>> send an email to [email protected].
>>>>>>>> For more options, visit
>>>>>>>> https://groups.google.com/a/wso2.com/d/optout.
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> *Naduni Pamudika*
>>>>>>> Software Engineer | WSO2
>>>>>>> Mobile: +94 719 143658 <+94%2071%20914%203658>
>>>>>>> [image: http://wso2.com/signature] <http://wso2.com/signature>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Dinusha Dissanayake
>>>>>> Software Engineer
>>>>>> WSO2 Inc
>>>>>> Mobile: +94712939439
>>>>>> <https://wso2.com/signature>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> *Sarubi Thillainathan *
>>>>> *Software Engineer - WSO2 Inc.*
>>>>>
>>>>> *Mobile : +94 (0) 76 68 49 101*
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> *Sarubi Thillainathan *
>>>> *Software Engineer - WSO2 Inc.*
>>>>
>>>> *Mobile : +94 (0) 76 68 49 101*
>>>>
>>>> _______________________________________________
>>>> Architecture mailing list
>>>> [email protected]
>>>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>>>>
>>>>
>>>
>>>
>>> --
>>> Chamin Dias
>>> Mobile : 0716097455
>>> Email : [email protected]
>>> LinkedIn : https://www.linkedin.com/in/chamindias
>>>
>>> _______________________________________________
>>> Architecture mailing list
>>> [email protected]
>>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>>>
>>
>
>
> --
> *Sarubi Thillainathan *
> *Software Engineer - WSO2 Inc.*
>
> *Mobile : +94 (0) 76 68 49 101*
> _______________________________________________
> Architecture mailing list
> [email protected]
> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>
_______________________________________________
Architecture mailing list
[email protected]
https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture

Reply via email to