Flavia Rainone [
http://community.jboss.org/people/flavia.rainone%40jboss.com] replied to
the discussion
"Implementing a non-flat deployment for Weld Integration"
To view the discussion, visit:
http://community.jboss.org/message/554219#554219
--------------------------------------------------------------
Ales Justin wrote:
How often is this - loadBeanDeploymentArchive - method used?
Or, shouldn't the (potential) operation [Archive|Deployment]::isReachable(Archive
other) be O(1),
a simple hash lookup of pre-build reachable archives / deployments?
I was
mentioning keeping only a single map of CL->Archives and bypassing the is reachable
check. My argument on this is that is it really possible that Weld will request for a non
reachable beanClass? If the beanClass is not reachable from the current deployment CL, the
code won't run, because the CL can't load beanClass. Thus, IMHO, I don't think
that it is possible that Weld will ever request for a beanClass associated with an Archive
that is not visible to the current Deployment. But, as I don't know nothing about Weld
implementation, I'm hoping that Pete or Ales will answer this question ;)
Having a pre-built map of reachable archives is totally a different story, i.e., more
complex to implement and will incur at an extra cost to maintain (I have again to walk
through the graph to be able to define which archives are visible, this time it won't
be done at every loadBeanDeploymentArchive request; but it will be done for every
pre-existing deployment at every new deployment, and the cost will increase according to
the number of Archives we have in Default Domain).
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/554219#554219]
Start a new discussion in JBoss Microcontainer Development POJO Server at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]