[jboss-dev] EJB3 DevForum: Resource adapter file name hard coded into ejb3/MessagingContainer
Jaikiran Pai
jpai at redhat.com
Thu Apr 23 07:24:16 EDT 2009
Clebert Suconic wrote:
>
> Why the resource adapter is hard coded on
> org.jboss.ejb3.mdb.MessagingContainer?
You mean the jms-ra.rar filename right?
>
> For instance i was going to rename it for JBM2, since we have our own
> provider now, but i couldn't as there is this hard-coded instance.
Not really a solution to what you are trying to achieve (i.e. removing
dependency on the file names), but I think we (EJB3) can move the
hardcoding out of the MessagingContainer and instead introduce this as
an annotation through ejb3-interceptors-aop.xml:
<domain name="Message Driven Bean" extends="Intercepted Bean"
inheritBindings="true">
...
<annotation expr="class(*) AND
!class(@org.jboss.ejb3.annotation.ResourceAdapter)">
@org.jboss.ejb3.annotation.ResourceAdapter ("jms-ra.rar")
</annotation>
</domain>
> What if the user was using another JMS provider besides JBM, JBM2 or
> JBossMQ?
The ResourceAdapter can be overriden by using the
@org.jboss.ejb3.annotation.ResourceAdapter on the MDB:
@ResourceAdapter("somecustom-ra.rar")
public class MyMDB
{
...
}
> It seems that this was supposed to be used around creating non
> existent when deploying MDBs,
Not sure.
> but as far as I remember that feature was Brocked long ago, so this
> code could probably be removed?
Creation of non-existent destinations is now available through a
property https://jira.jboss.org/jira/browse/JBAS-6013
regards,
-Jaikiran
More information about the jboss-development
mailing list