On Tue, Mar 15, 2011 at 5:49 PM, Afkham Azeez <[email protected]> wrote:
> > > On Tue, Mar 15, 2011 at 5:45 PM, Senaka Fernando <[email protected]> wrote: > >> >> >> On Tue, Mar 15, 2011 at 5:33 PM, Afkham Azeez <[email protected]> wrote: >> >>> >>> >>> On Tue, Mar 15, 2011 at 10:40 AM, Senaka Fernando <[email protected]>wrote: >>> >>>> Hi Azeez, >>>> >>>> On Sat, Mar 12, 2011 at 8:34 PM, Afkham Azeez <[email protected]> wrote: >>>> >>>>> Yes, perhaps we should cache the CarbonContext which is created for a >>>>> tenant. Can we have a single CarbonContext instance for all users of a >>>>> given >>>>> tenant? >>>> >>>> >>>> No, for a single user of a single tenant the CarbonContext can be >>>> created just once. The reason is, our authorizations are based on user, and >>>> we create separate instances of registries, which are user-aware so that >>>> the >>>> credentials can be provided only once. This is because we don't have a >>>> concept of credential which is cached at the Context-level. If we have >>>> that, >>>> we don't need multiple registry and realm objects. The same should also >>>> solve multiple similar problems. However, I'm not sure about the impact >>>> this >>>> change would bring. >>>> >>> >>> But we can't cache CarbonContext per tenant per user. Have you got an >>> idea of how we can implement this? >>> >> >> That should be doable. IMO we need a cache-key, which has both username >> and tenant id in it. That's it. >> > > It will consume a lot of memory. > Yes, that's the pitfall. But, I wonder how this was working in 3.1.0? Was there some sort of caching at that level? session-scoped? Thanks, Senaka. > > >> >> Thanks, >> Senaka. >> >>> >>> >>>> >>>> WDYT? >>>> >>>> Thanks, >>>> Senaka. >>>> >>>>> >>>>> >>>>> On Fri, Mar 11, 2011 at 10:12 PM, Senaka Fernando <[email protected]>wrote: >>>>> >>>>>> Hi Azeez, >>>>>> >>>>>> OK, so it seems to be wrong to be reconstructing the carbon context >>>>>> over and over again, for each request that comes in. This was cached in >>>>>> some >>>>>> scope (session or context), making this a one-time overhead. Did this >>>>>> change >>>>>> from 3.1.0 to 3.2.0 for some reason? >>>>>> >>>>>> Thanks, >>>>>> Senaka. >>>>>> >>>>>> On Fri, Mar 11, 2011 at 3:54 PM, Afkham Azeez <[email protected]> wrote: >>>>>> >>>>>>> As can be seen in the JProfiler screenshot, there getRegistry methods >>>>>>> are introducing a big overhead. >>>>>>> >>>>>>> -- >>>>>>> *Afkham Azeez* >>>>>>> Senior Software Architect & Senior Manager; WSO2, Inc.; >>>>>>> http://wso2.com, >>>>>>> * >>>>>>> * >>>>>>> *Member; Apache Software Foundation; >>>>>>> **http://www.apache.org/*<http://www.apache.org/> >>>>>>> * >>>>>>> email: **[email protected]* <[email protected]>* cell: >>>>>>> <%2B94%2077%203320919> <%2B94%2077%203320919> >>>>>>> <%2B94%2077%203320919><%2B94%2077%203320919><%2B94%2077%203320919><%2B94%2077%203320919>+94 >>>>>>> 77 3320919 >>>>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>* >>>>>>> twitter: >>>>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez> >>>>>>> * >>>>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez* >>>>>>> * >>>>>>> * >>>>>>> *Lean . Enterprise . Middleware* >>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Carbon-dev mailing list >>>>>>> [email protected] >>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> *Senaka Fernando* >>>>>> Product Manager - WSO2 Governance Registry; >>>>>> Associate Technical Lead; WSO2, Inc.; http://wso2.com* >>>>>> Member; Apache Software Foundation; http://apache.org >>>>>> >>>>>> E-mail: senaka AT wso2.com >>>>>> **P: <%2B1%20408%20754%207388> >>>>>> <%2B1%20408%20754%207388><%2B1%20408%20754%207388><%2B1%20408%20754%207388><%2B1%20408%20754%207388>+1 >>>>>> 408 754 7388; ext: 51736*; *M: >>>>>> <%2B94%2077%20322%201818><%2B94%2077%20322%201818><%2B94%2077%20322%201818><%2B94%2077%20322%201818><%2B94%2077%20322%201818>+94 >>>>>> 77 322 1818 >>>>>> Linked-In: http://www.linkedin.com/in/senakafernando >>>>>> >>>>>> *Lean . Enterprise . Middleware >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> *Afkham Azeez* >>>>> Senior Software Architect & Senior Manager; WSO2, Inc.; >>>>> http://wso2.com, >>>>> * >>>>> * >>>>> *Member; Apache Software Foundation; >>>>> **http://www.apache.org/*<http://www.apache.org/> >>>>> * >>>>> email: **[email protected]* <[email protected]>* cell: >>>>> <%2B94%2077%203320919> <%2B94%2077%203320919> >>>>> <%2B94%2077%203320919><%2B94%2077%203320919>+94 >>>>> 77 3320919 >>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>* >>>>> twitter: >>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez> >>>>> * >>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez* >>>>> * >>>>> * >>>>> *Lean . Enterprise . Middleware* >>>>> >>>>> >>>> >>>> >>>> -- >>>> *Senaka Fernando* >>>> Product Manager - WSO2 Governance Registry; >>>> Associate Technical Lead; WSO2, Inc.; http://wso2.com* >>>> Member; Apache Software Foundation; http://apache.org >>>> >>>> E-mail: senaka AT wso2.com >>>> **P: <%2B1%20408%20754%207388> >>>> <%2B1%20408%20754%207388><%2B1%20408%20754%207388>+1 >>>> 408 754 7388; ext: 51736*; *M: >>>> <%2B94%2077%20322%201818><%2B94%2077%20322%201818><%2B94%2077%20322%201818>+94 >>>> 77 322 1818 >>>> Linked-In: http://www.linkedin.com/in/senakafernando >>>> >>>> *Lean . Enterprise . Middleware >>>> >>>> >>> >>> >>> -- >>> *Afkham Azeez* >>> Senior Software Architect & Senior Manager; WSO2, Inc.; http://wso2.com >>> , >>> * >>> * >>> *Member; Apache Software Foundation; >>> **http://www.apache.org/*<http://www.apache.org/> >>> * >>> email: **[email protected]* <[email protected]>* cell: >>> <%2B94%2077%203320919><%2B94%2077%203320919>+94 >>> 77 3320919 >>> blog: **http://blog.afkham.org* <http://blog.afkham.org>* >>> twitter: **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez> >>> * >>> linked-in: **http://lk.linkedin.com/in/afkhamazeez* >>> * >>> * >>> *Lean . Enterprise . Middleware* >>> >>> >> >> >> -- >> *Senaka Fernando* >> Product Manager - WSO2 Governance Registry; >> Associate Technical Lead; WSO2, Inc.; http://wso2.com* >> Member; Apache Software Foundation; http://apache.org >> >> E-mail: senaka AT wso2.com >> **P: <%2B1%20408%20754%207388>+1 408 754 7388; ext: 51736*; *M: >> <%2B94%2077%20322%201818>+94 77 322 1818 >> Linked-In: http://www.linkedin.com/in/senakafernando >> >> *Lean . Enterprise . Middleware >> >> > > > -- > *Afkham Azeez* > Senior Software Architect & Senior Manager; WSO2, Inc.; http://wso2.com, > * > * > *Member; Apache Software Foundation; > **http://www.apache.org/*<http://www.apache.org/> > * > email: **[email protected]* <[email protected]>* cell: +94 77 3320919 > blog: **http://blog.afkham.org* <http://blog.afkham.org>* > twitter: **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez> > * > linked-in: **http://lk.linkedin.com/in/afkhamazeez* > * > * > *Lean . Enterprise . Middleware* > > -- *Senaka Fernando* Product Manager - WSO2 Governance Registry; Associate Technical Lead; WSO2, Inc.; http://wso2.com* Member; Apache Software Foundation; http://apache.org E-mail: senaka AT wso2.com **P: +1 408 754 7388; ext: 51736*; *M: +94 77 322 1818 Linked-In: http://www.linkedin.com/in/senakafernando *Lean . Enterprise . Middleware
_______________________________________________ Carbon-dev mailing list [email protected] http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
