Hi,

On Mon, Nov 6, 2017 at 7:16 PM, Bhathiya Jayasekara <bhath...@wso2.com>
wrote:

> Hi Renuka,
>
> On Mon, Nov 6, 2017 at 4:24 PM, Renuka Fernando <ren...@wso2.com> wrote:
>
>> Hi,
>>
>> The property environmentName is used to append environment name to
>> cookie and label is used to list down environments in the login page.
>>
>
> Stil not clear to me either. Let me ask 2 direct questions.
>
> 1) In your sample, you have 2 environments, development and production.
> But your environmentName is Default. What does that mean?
>
What if there are no multiple environments in deployment.yaml. Then cookie
names will not have any environment name append to it.   So to maintain
consistency of cookie names I think its better to have a default value for
environment.
But the name environment name can be confusing. As in your second question
sometimes this might not be environment (just provide the UI).

> 2) In case of UI service running separately, what should be the value of 
> environmentName?
> (I guess you don't need that in this case. Please confirm.)
>
Exactly this is one use case. UI can be served by separate node which is
not a environment . This is where the environment list comes into play.
User will have to definitely select either production or development here.
Default value is never present to the UI. It is only for internal reference
only.

I think overall there are some missing points in this design we need to
clarify.
@KasunTe, @PubuduG, Could you please shed some light here since, you have
closely followed the GSoc project.

>
> Thanks,
> Bhathiya
>
>
>>
>> Thank you
>>
>> On 6 November 2017 at 15:34, Pubudu Gunatilaka <pubu...@wso2.com> wrote:
>>
>>> Hi,
>>>
>>> environmentName is used to keep the environment to itself. This is used
>>> when the server is setting up the cookies by appending the env name to the
>>> cookies. The env list is to populate the env list.
>>>
>>> Thank you!
>>>
>>> On Mon, Nov 6, 2017 at 2:42 PM, Chamin Dias <cham...@wso2.com> wrote:
>>>
>>>> Hi Renuka,
>>>>
>>>> Step 7 : "The environment read its deployment.yaml to know the name of
>>>> itself and set cookies..."
>>>>
>>>> So this means the environment name is taken from the environment
>>>> itself. Is there any reason to exclude the environment in the provided
>>>> yaml file?
>>>>
>>>> Thanks.
>>>>
>>>>
>>>> On Mon, Nov 6, 2017 at 2:24 PM, Bhathiya Jayasekara <bhath...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Renuka,
>>>>>
>>>>> On Mon, Nov 6, 2017 at 11:27 AM, Renuka Fernando <ren...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> We are planning to implement new feature "Multi-Environment
>>>>>> Support"[1] for API Manager. The feature allows users to manage
>>>>>> environments through one User Interfaces.
>>>>>>
>>>>>> [image: Inline images 1]
>>>>>> Suppose there are three environments (i.e. three instance of API
>>>>>> manager) currently running in an organization. Users of the API Manager
>>>>>> have log into each environments and work with three different User
>>>>>> Interfaces. The proposed feature allow one User Interface to handle all
>>>>>> environments. User can switch environments and also enable new feature 
>>>>>> like
>>>>>> API difference in environments.
>>>>>>
>>>>>> This is the proposed design of multi-environment support for API
>>>>>> manager.
>>>>>> [image: Inline images 2]
>>>>>>
>>>>>> The UI service in the diagram may be a separate service for User
>>>>>> Interface or another environment itself.
>>>>>>
>>>>>>
>>>>>>    1. Browser request login page for the app (publisher/store/admin)
>>>>>>    from UI service.
>>>>>>    2. Serve the page.
>>>>>>    3. Browser call the ConfigurationsAPI
>>>>>>    (org.wso2.carbon.apimgt.rest.api.configurations)[2] to get
>>>>>>    available environments.
>>>>>>
>>>>>> Since this API is a part of UI service (but not of core), we may need
>>>>> a different name to indicate that.
>>>>>
>>>>>>
>>>>>>    1. Read deployment.yaml that contains environments' details
>>>>>>       - Sample deployment.yaml
>>>>>>       -
>>>>>>
>>>>>>       wso2.carbon.apimgt.environments:
>>>>>>         environmentName: Default
>>>>>>         environments:
>>>>>>         - host: dev.sample.com:9292
>>>>>>           loginTokenPath: /login/token
>>>>>>           label: Development
>>>>>>
>>>>>>
>>>>>>
>>>>> What's he dfference between environmentName and environments.label?
>>>>> (If environmentName represents the current environment, souldn't it
>>>>> be one of environments.labels?)
>>>>>
>>>>> Thanks,
>>>>> Bhathiya
>>>>>
>>>>>>
>>>>>>    -
>>>>>>
>>>>>>
>>>>>>
>>>>>>         - host: prod.sample.com:9292
>>>>>>           loginTokenPath: /login/token
>>>>>>           label: Production
>>>>>>
>>>>>>       1. Serve environments' details as JSON.
>>>>>>       - Browser then render a list of environments.
>>>>>>    2. Send request with user credentials to the proper environment
>>>>>>    to login.
>>>>>>    3. The environment read its deployment.yaml to know the name of
>>>>>>    itself and set cookies with appending the name to the cookie name.
>>>>>>
>>>>>> [1] https://github.com/wso2/carbon-apimgt/issues/4690
>>>>>> [2] https://github.com/wso2/carbon-apimgt/pull/4679
>>>>>>
>>>>>>
>>>>>> Appreciate any suggestions.
>>>>>> Thanks
>>>>>>
>>>>>> Best regards
>>>>>>
>>>>>> --
>>>>>> *Renuka Fernando*
>>>>>> Software Engineering Intern | WSO2 Inc
>>>>>>
>>>>>> Email : ren...@wso2.com
>>>>>> Mobile : +94 76 667 8752 <076%20667%208752>
>>>>>> Web : http://wso2.com
>>>>>> <http://wso2.com/signature>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> *Bhathiya Jayasekara*
>>>>> *Associate Technical Lead,*
>>>>> *WSO2 inc., http://wso2.com <http://wso2.com>*
>>>>>
>>>>> *Phone: +94715478185 <+94%2071%20547%208185>*
>>>>> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
>>>>> <http://www.linkedin.com/in/bhathiyaj>*
>>>>> *Twitter: https://twitter.com/bhathiyax
>>>>> <https://twitter.com/bhathiyax>*
>>>>> *Blog: http://movingaheadblog.blogspot.com
>>>>> <http://movingaheadblog.blogspot.com/>*
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Chamin Dias
>>>> Mobile : 0716097455 <071%20609%207455>
>>>> Email : cham...@wso2.com
>>>> LinkedIn : https://www.linkedin.com/in/chamindias
>>>>
>>>>
>>>
>>>
>>> --
>>> *Pubudu Gunatilaka*
>>> Committer and PMC Member - Apache Stratos
>>> Senior Software Engineer
>>> WSO2, Inc.: http://wso2.com
>>> mobile : +94774078049 <%2B94772207163>
>>>
>>>
>>
>>
>> --
>> *Renuka Fernando*
>> Software Engineering Intern | WSO2 Inc
>>
>> Email : ren...@wso2.com
>> Mobile : +94 76 667 8752 <076%20667%208752>
>> Web : http://wso2.com
>> <http://wso2.com/signature>
>>
>
>
>
> --
> *Bhathiya Jayasekara*
> *Associate Technical Lead,*
> *WSO2 inc., http://wso2.com <http://wso2.com>*
>
> *Phone: +94715478185 <+94%2071%20547%208185>*
> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
> <http://www.linkedin.com/in/bhathiyaj>*
> *Twitter: https://twitter.com/bhathiyax <https://twitter.com/bhathiyax>*
> *Blog: http://movingaheadblog.blogspot.com
> <http://movingaheadblog.blogspot.com/>*
>



-- 
Rajith Roshan
Senior Software Engineer, WSO2 Inc.
Mobile: +94-7 <%2B94-71-554-8430>17-064-214
_______________________________________________
Architecture mailing list
Architecture@wso2.org
https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture

Reply via email to