Another JMS question, how should I go about creating a session such that its
transactional context is consistent with the executing bean? I assume that
the resource manager fluff is there to deal with some of this? Should I
assume that the session is transacted with an AUTO_ACK mode? I am surprised
the bean does not get a session as a resource instead of a connection
factory.
--jason
On Thu, 12 Apr 2001, Scott M Stark wrote:
> A ConnectionFactory is a resource factory and the spec talks about JMS
> being located by convention under the java:comp/env/jms context. To
> access a QueueConnectionFactory independent of which app server you
> deploy in you would define an ejb-jar resource-ref as:
>
> ejb-jar.xml:
> <ejb-jar>
> <display-name>ENC Tests</display-name>
> <enterprise-beans>
> <session>
> <description>A session bean on looks up stuff in the ENC</description>
> ...
> <!-- JMS Connection Factories (java:comp/env/jms) -->
> <resource-ref>
> <description>Default QueueFactory</description>
> <res-ref-name>jms/QueFactory</res-ref-name>
> <res-type>javax.jms.QueueConnectionFactory</res-type>
> <res-auth>Container</res-auth>
> </resource-ref>
> </session>
> </enterprise-beans>
> </ejb-jar>
>
> jboss.xml:
> <jboss>
> <enterprise-beans>
> <session>
> <ejb-name>ENCBean</ejb-name>
> <resource-ref>
> <resource-name>QueFactory</resource-name>
> <res-ref-name>jms/QueFactory</res-ref-name>
> </resource-ref>
> </session>
> </enterprise-beans>
>
> <resource-managers>
> <resource-manager res-class="">
> <res-name>QueFactory</res-name>
> <res-jndi-name>QueueConnectionFactory</res-jndi-name>
> </resource-manager>
> </resource-managers>
> </jboss>
>
> Your bean is indepdendent of the app server but its deployment unit is not.
>
> ----- Original Message -----
> From: "Jason Dillon" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, April 12, 2001 5:25 PM
> Subject: Re: [JBoss-user] Using JMS resources (or other resources)
>
>
> > That is more or less what I am going to be doing, but I wanted to know if
> > there was a standard way to provide the queue information to a bean. My
> > guess is that it should be as a resource, but I am not 100% sure.
> >
> > --jason
> >
>
>
>
> _______________________________________________
> JBoss-user mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/jboss-user
>
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user