This content has been marked as final.
Show 2 replies
-
1. Re: Components constructed multiple times?
israel.bgf Jun 1, 2009 6:24 PM (in response to gzoller.greg.zoller.aviall.com)I think that it's normal. Seam objects normally have two instances anyway (
raw
instance, and proxied instance for bijection). Page scope, is destroyed and rebuild lot of times in a request, cause it's serialized in some weird place that i dont know where exactly is.So yes, it's all normal. Dont be scared. And that's why you shouldnt use your constructor to initialize things, always use the @Create annotation.
@Create
public void init(){};Seam container is doing a lot of nasty things under the hood, and we shouldnt care about this. :)
-
2. Re: Components constructed multiple times?
gzoller.greg.zoller.aviall.com Jun 1, 2009 10:37 PM (in response to gzoller.greg.zoller.aviall.com)Makes sense...thanks for the info! I'll make sure I'm not doing expensive things in my constructors and favor @Create instead.
Greg