[
https://jira.jboss.org/jira/browse/JBSEAM-4140?page=com.atlassian.jira.pl...
]
Jozef Hartinger commented on JBSEAM-4140:
-----------------------------------------
What my change does is that the component is instantiated only if it is configured from
component descriptor - the bean class of the component is either ResourceHome or
ResourceQuery. These themselves are instantiable at any time (there is no required
injection that could not be satisfied nor security checks). On the other hand, if someone
uses these components by extension (he or she may want to inject something from a
different scope or use security restrictions), these components are not being instantiated
anymore at component registration (as their bean classes are subclasses of original
resource classes). Instead, users are encouraged to use @Path annotation to set the URI in
this case.
However, I must say that I like your idea of mapping the resources outside the component
itself. Does not put the limitations my solution does.
ResteasyDispatches instantiates resources even if they are not
instantiable at that time.
-----------------------------------------------------------------------------------------
Key: JBSEAM-4140
URL:
https://jira.jboss.org/jira/browse/JBSEAM-4140
Project: Seam
Issue Type: Bug
Components: WS
Affects Versions: 2.1.2.CR1
Reporter: Jozef Hartinger
Assignee: Christian Bauer
Priority: Critical
Fix For: 2.1.2.CR2
right now, for every descendant of AbstractResource we simply create an instance and take
a look at the path attribute value - this breaks if someone is extending the component and
injects another component which is not available when resources get registered, uses
@Restrict etc...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira