I've also seen some place where we need to improve in
the TenantAwareLoadBalanceEndpoint class. Here are my observations.

1) Five different inner "for-loops". This is a bad smell in the code.
2) We do a registry lookup for each and every unknown host name. This bit
of code is vulnerable to a DOS Attack.
3) This code looks more like procedural-oriented code.

Lets do a proper code review on this and refactor the code for the next
release. I've created a Redmine task for this.

Thanks,
Sameera.


On Fri, Aug 16, 2013 at 4:43 PM, Afkham Azeez <az...@wso2.com> wrote:

> There are a number of debug statements which do String concatenations, and
> are not wrapped in log.isDebugEnabled() conditions. Such statements will
> cause unnecessary performance overhead.
>
> --
> *Afkham Azeez*
> Director of Architecture; WSO2, Inc.; http://wso2.com
> Member; Apache Software Foundation; http://www.apache.org/
> * <http://www.apache.org/>**
> email: **az...@wso2.com* <az...@wso2.com>* 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*
>



-- 
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

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

Reply via email to