Sameera isn't CarbonContext.getCurrentContext() supposed to return the
context associated with the current thread???


On Tue, Oct 1, 2013 at 11:45 AM, Sameera Jayasoma <same...@wso2.com> wrote:

> Hi Folks,
>
> Some of you may be wondering why we are doing this change now. The
> simplest reason is, to ensure the consistency of its usage.
>
> Over the past few years somehow we've ended up adding more methods to this
> API and also ended up putting two different set of APIs for setting and
> getting the CarbonContext object.  Its not the time to check who has done
> this, but its the time to properly refactor this API as well as its usages.
> Following is the two sets of APIs. Carbon kernel and component developers
> have used these methods interchangeably. This has caused some inconsistency
> in the CarbonPlatform. We've faced many issues related to this during the
> 4.2.0 release. Thats why we thought of fixing this once for all.
>
>
> CarbonContext.getCurrentContext()
> CarbonContext.getCurrentContext(MessageContext msgCtx)
> CarbonContext.getCurrentContext(HttpSession session)
> CarbonContext.getCurrentContext(AxisConfiguration config)
> CarbonContext.getCurrentContext(ConfigurationContext ctx)
> CarbonContext.getCurrentContext(ThriftSession session)
>
> -----------------
> *CarbonContext.getThreadLocalVariable()*
>
> The plan is the use the latter API from now onwards. We are deprecating
> the former set of APIs. Now we need to ensure that each running Thread in
> the system should have an associated CarbonContext object.
>
>
> Thanks,
> Sameera.
>
> --
> Sameera Jayasoma,
> Architect,
>
>  WSO2, Inc. (http://wso2.com)
> email: same...@wso2.com
> blog: http://sameera.adahas.org
> twitter: https://twitter.com/sameerajayasoma
> flickr: http://www.flickr.com/photos/sameera-jayasoma/collections
> Mobile: 0094776364456
>
> Lean . Enterprise . Middleware
>
> _______________________________________________
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Sanjiva Weerawarana, Ph.D.
Founder, Chairman & CEO; WSO2, Inc.;  http://wso2.com/
email: sanj...@wso2.com; phone: +94 11 763 9614; cell: +94 77 787 6880 | +1
650 265 8311
blog: http://sanjiva.weerawarana.org/

Lean . Enterprise . Middleware
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to