TransactionManager is now good and I need to get hold of the connection
pool / datasource.

In the jboss.conf file I define a connection pool with the following entry...

<MLET CODE = "org.jboss.jdbc.DataSourceImpl" ARCHIVE="jboss.jar,weblogic.jar" 
CODEBASE="../lib/ext/">
   <ARG TYPE="java.lang.String" VALUE="jdbc:weblogic:mssqlserver4:sbarlow@DEVDB:1433">
   <ARG TYPE="java.lang.String" VALUE="MSSQLServer">
   <ARG TYPE="java.lang.String" VALUE="weblogic.jdbc.mssqlserver4.Driver">
   <ARG TYPE="java.lang.String" VALUE="pduser">
   <ARG TYPE="java.lang.String" VALUE="pd">
</MLET>


In my code I am trying to get hold of the connection pool with the string...

"java:comp/env/jdbc/MSSQLServer"


But I get the following error...

[Test] Error loading persistence service. EXCEPTION [TOPLINK-7060]
(v2.5.1 Pre-release 2 April 25 2000):
TOPLink.Public.Exceptions.ValidationException
EXCEPTION DESCRIPTION:
Cannot acquire DataSource: comp/env/jdbc/MSSQLServer
javax.naming.InvalidNameException:
Not a compound name: comp/env/jdbc/MSSQLServer
[Test] LOCAL EXCEPTION STACK:


Am I defining a ConnectionPool correctly with the above MLET ?
Am I using the correct string to get hold of the connection pool defn?

Thanks.


Rickard �berg wrote:
> 
> Hey
> 
> Stuart Barlow wrote:
> >
> > I am trying to integtrate TOPLink and jBoss so that TOPLink can use
> > the jBoss server as its external transaction manager and get access to
> > connection pools defined and controlled by jBoss.
> >
> > We have to tell TOPLink to use an external transaction manager and then
> > set the Transaction manager to use.
> >
> > I was trying to get the TransactionManager from the InitialContext.
> > I have tried both the strings...
> >
> > javax.transaction.TransactionManager
> > java:comp/TransactionManager
> 
> It is bound to "TransactionManager".
> 
> /Rickard
> 
> >
> > Both times I get the complaint...
> >
> > [Test] (JBossTLPersistenceService): just about to get TransactionManager
> > [Test] Error loading persistence service.
> javax.naming.NameNotFoundException: javax.transaction.Transacti
> > onManager not bound
> > [Test] java.lang.NullPointerException
> > [Test]  at
> com.peopledoc.persistence.TLPersistenceService.getWriteableSession(TLPersis
> tenceService.java:5
> > 5)
> > [Test]  at
> com.peopledoc.components.documentstorage.TestBean.createUser(TestBean.java:
> 27)
> > [Test]  at java.lang.reflect.Method.invoke(Native Method)
> >         at
> com.peopledoc.persistence.TLPersistenceService.getWriteableSession(TLPersis
> tenceService.java:5
> > 5)
> >         at
> com.peopledoc.components.documentstorage.TestBean.createUser(TestBean.java:
> 27)
> >         at java.lang.reflect.Method.invoke(Native Method)
> >         at
> org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(Statele
> ssSessionContainer.
> > java:286)
> >         at
> org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:8
> 2)
> >         at
> org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessS
> essionInstanceInter
> > ceptor.java:73)
> >         at
> org.jboss.ejb.plugins.TxInterceptor.invoke(TxInterceptor.java:179)
> >         at
> org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:140)
> >         at
> org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.ja
> va:152)
> >         at
> org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invoke(JRMPContainer
> Invoker.java:129)
> >         at java.lang.reflect.Method.invoke(Native Method)
> >
> > Is the TransactionManager class not available to java classes on the
> > server?
> > Am I barking up the wrong tree?
> >
> > Thanks.
> >
> ---------------------------------------------------------------------------
> > Stuart Barlow
> > +44 131 468 8205
> >
> > --
> > --------------------------------------------------------------
> > To subscribe:        [EMAIL PROTECTED]
> > To unsubscribe:      [EMAIL PROTECTED]
> > Problems?:           [EMAIL PROTECTED]
> 
> --
> Rickard �berg
> 
> @home: +46 13 177937
> Email: [EMAIL PROTECTED]
> http://www.telkel.com
> http://www.jboss.org
> http://www.dreambean.com
> 
> --
> --------------------------------------------------------------
> To subscribe:        [EMAIL PROTECTED]
> To unsubscribe:      [EMAIL PROTECTED]
> Problems?:           [EMAIL PROTECTED]

-- 
---------------------------------------------------------------------------
Stuart Barlow
+44 131 468 8205


--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to