You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openwebbeans.apache.org by Mark Struberg <st...@yahoo.de> on 2010/03/23 15:09:59 UTC

please avoid putting into internal maps in external locations

Hi folks!

Please, don't put somthing into a map by writing code like

JavassistProxyFactory.getInterceptorProxyClasses().put(bean, proxyClass);

This is absolutely unmaintainable!
Maps should generally be considered immutable if they are not defined inside the own dependency chain (member of own class or protected member of superclass)

txs,
strub

__________________________________________________
Do You Yahoo!?
Sie sind Spam leid? Yahoo! Mail verfügt über einen herausragenden Schutz gegen Massenmails. 
http://mail.yahoo.com 

Re: AW: please avoid putting into internal maps in external locations

Posted by Gurkan Erdogdu <gu...@yahoo.com>.
>>>To relativate this: I'm currently a bit frustrated and angry mainly
about myself, because such things should never have slipped under my
radar.
:)


>>>Part of our code is currently so complex that only the one who wrote it understands it, so we are really low with reviews atm.
That is me :) But do not think it is so complicated 

>>>We should move on to stick more to design principals, and if a code
like the current InterceptorHandler is so complex and cyclically
refered by lots >>>of classes, then we should listen to findbugs, pmd, ...
and refactor that code.
Same.

>>>If we have a clearer design in this area, then the code should shrink down to ~50% and also will be much easier to read.
You are more than welcome :)

Thanks;

--Gurkan


________________________________
From: Mark Struberg <st...@yahoo.de>
To: dev@openwebbeans.apache.org
Sent: Tue, March 23, 2010 4:28:59 PM
Subject: AW: please avoid putting into internal maps in external locations

To relativate this: I'm currently a bit frustrated and angry mainly about myself, because such things should never have slipped under my radar. 

Part of our code is currently so complex that only the one who wrote it understands it, so we are really low with reviews atm.

We should move on to stick more to design principals, and if a code like the current InterceptorHandler is so complex and cyclically refered by lots of classes, then we should listen to findbugs, pmd, ... and refactor that code.

If we have a clearer design in this area, then the code should shrink down to ~50% and also will be much easier to read.

LieGrue,
strub

--- Mark Struberg <st...@yahoo.de> schrieb am Di, 23.3.2010:

> Von: Mark Struberg <st...@yahoo.de>
> Betreff: please avoid putting into internal maps in external locations
> An: dev@openwebbeans.apache.org
> Datum: Dienstag, 23. März, 2010 15:09 Uhr
> Hi folks!
> 
> Please, don't put somthing into a map by writing code like
> 
> JavassistProxyFactory.getInterceptorProxyClasses().put(bean,
> proxyClass);
> 
> This is absolutely unmaintainable!
> Maps should generally be considered immutable if they are
> not defined inside the own dependency chain (member of own
> class or protected member of superclass)
> 
> txs,
> strub
> 
> __________________________________________________
> Do You Yahoo!?
> Sie sind Spam leid? Yahoo! Mail verfügt über einen
> herausragenden Schutz gegen Massenmails. 
> http://mail.yahoo.com
> 

__________________________________________________
Do You Yahoo!?
Sie sind Spam leid? Yahoo! Mail verfügt über einen herausragenden Schutz gegen Massenmails. 
http://mail.yahoo.com



      ___________________________________________________________________
Yahoo! Türkiye açıldı!  http://yahoo.com.tr
İnternet üzerindeki en iyi içeriği Yahoo! Türkiye sizlere sunuyor!

AW: please avoid putting into internal maps in external locations

Posted by Mark Struberg <st...@yahoo.de>.
To relativate this: I'm currently a bit frustrated and angry mainly about myself, because such things should never have slipped under my radar. 

Part of our code is currently so complex that only the one who wrote it understands it, so we are really low with reviews atm.

We should move on to stick more to design principals, and if a code like the current InterceptorHandler is so complex and cyclically refered by lots of classes, then we should listen to findbugs, pmd, ... and refactor that code.

If we have a clearer design in this area, then the code should shrink down to ~50% and also will be much easier to read.

LieGrue,
strub

--- Mark Struberg <st...@yahoo.de> schrieb am Di, 23.3.2010:

> Von: Mark Struberg <st...@yahoo.de>
> Betreff: please avoid putting into internal maps in external locations
> An: dev@openwebbeans.apache.org
> Datum: Dienstag, 23. März, 2010 15:09 Uhr
> Hi folks!
> 
> Please, don't put somthing into a map by writing code like
> 
> JavassistProxyFactory.getInterceptorProxyClasses().put(bean,
> proxyClass);
> 
> This is absolutely unmaintainable!
> Maps should generally be considered immutable if they are
> not defined inside the own dependency chain (member of own
> class or protected member of superclass)
> 
> txs,
> strub
> 
> __________________________________________________
> Do You Yahoo!?
> Sie sind Spam leid? Yahoo! Mail verfügt über einen
> herausragenden Schutz gegen Massenmails. 
> http://mail.yahoo.com
> 

__________________________________________________
Do You Yahoo!?
Sie sind Spam leid? Yahoo! Mail verfügt über einen herausragenden Schutz gegen Massenmails. 
http://mail.yahoo.com