Hi Anuruddha,

ApplicationContext is not the runtime. It is a static reference to the
application definition. In which we have a life cycle to identify whether
it is created/deployed/undeploying. The actual runtime can be found in the
Applications Topology where it already has the relevant life cycle. I think
that you need to use applications runtime to check on the  relevant status.

Thanks,
Reka

On Mon, Sep 14, 2015 at 10:13 AM, Anuruddha Liyanarachchi <
anurudd...@wso2.com> wrote:

> Hi,
>
> But we are not setting the ApplicationContext to active state when
> application gets activated. We are only using three states [1].
>
> Don't we have to introduce "Active" state also to the ApplicationContext
> and change UI, API and events accordingly.
>
> [1]
> https://github.com/apache/stratos/blob/stratos-4.1.x/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/applications/pojo/ApplicationContext.java#L28-L30
> <https://github.com/apache/stratos/blob/stratos-4.1.x/components/org.apache.stratos.autoscaler/src/main/java/org/apache/stratos/autoscaler/applications/pojo/ApplicationContext.java#L28-L30>
>
> On Thu, Sep 10, 2015 at 7:32 PM, Gayan Gunarathne <gay...@wso2.com> wrote:
>
>> yeah. I think we already have that application active status.In
>> integration tests we already checking this for assert the application
>> activation. I think you can do the same here and allow sign up only when
>> application is on active state.
>>
>> Thanks,
>> Gayan
>>
>> On Thu, Sep 10, 2015 at 7:24 PM, Akila Ravihansa Perera <
>> raviha...@wso2.com> wrote:
>>
>>> Don't we already have an Active status [1] for Applications?
>>>
>>> [1]
>>> https://github.com/apache/stratos/blob/stratos-4.1.x/components/org.apache.stratos.messaging/src/main/java/org/apache/stratos/messaging/domain/application/ApplicationStatus.java#L37
>>>
>>> On Thu, Sep 10, 2015 at 6:54 PM, Anuruddha Liyanarachchi <
>>> anurudd...@wso2.com> wrote:
>>>
>>>> Hi Devs,
>>>>
>>>> I am planing to do $subject in Stratos. This will prevent users from
>>>> signing-up before application is active.
>>>>
>>>> The application life cycle will be as [1].
>>>>  WDYT?
>>>>
>>>> [1]
>>>> https://docs.google.com/drawings/d/1XOVZkgp_UUpGvD_HykECU_8yoA2YWgfpqv6wX2mgacY/edit?usp=sharing
>>>>
>>>> --
>>>> *Thanks and Regards,*
>>>> Anuruddha Lanka Liyanarachchi
>>>> Software Engineer - WSO2
>>>> Mobile : +94 (0) 712762611
>>>> Tel      : +94 112 145 345
>>>> a <thili...@wso2.com>nurudd...@wso2.com
>>>>
>>>
>>>
>>>
>>> --
>>> Akila Ravihansa Perera
>>> WSO2 Inc.;  http://wso2.com/
>>>
>>> Blog: http://ravihansa3000.blogspot.com
>>>
>>
>>
>>
>> --
>>
>> Gayan Gunarathne
>> Technical Lead, WSO2 Inc. (http://wso2.com)
>> Committer & PMC Member, Apache Stratos
>> email : gay...@wso2.com  | mobile : +94 775030545 <%2B94%20766819985>
>>
>>
>>
>
>
>
> --
> *Thanks and Regards,*
> Anuruddha Lanka Liyanarachchi
> Software Engineer - WSO2
> Mobile : +94 (0) 712762611
> Tel      : +94 112 145 345
> a <thili...@wso2.com>nurudd...@wso2.com
>



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

Reply via email to