Hi Jan,
I have a working postgresql connection on Red Hat 7 with postgres 7.1 and
jboss 2.1 latest build. I have made the following entries in my jboss.jcml:
<mbean code="org.jboss.jdbc.JdbcProvider"
name="DefaultDomain:service=JdbcProvider">
<attribute
name="Drivers">oracle.jdbc.driver.OracleDriver,org.postgresql.Driver</attribute>
</mbean>
<mbean code="org.jboss.jdbc.XADataSourceLoader"
name="DefaultDomain:service=XADataSource,name=PostgresDS">
<attribute name="PoolName">PostgresDS</attribute>
<attribute name="URL">jdbc:postgresql:scidoc</attribute>
<attribute name="JDBCUser">mypostgresuser</attribute>
<attribute name="Password">mypostgrespasswd</attribute>
<attribute
name="DataSourceClass">org.opentools.minerva.jdbc.xa.wrapper.XADataSourceImpl</attribute>
</mbean>
I have jdbc7.0-1.2.jar in jboss's lib/ext directory and I didn't put
anything in jboss.conf.
Regards,
Alexander Jerusalem
At 14:27 31.03.01, you wrote:
>Hi,
>
>First my setup:
>JBoss 2.1
>PostgreSQL: 7.03 w. jdbc7.0-1.2.jar
>Linux Redhat 6.2
>
>
>I'm trying to use JBoss with Postgres for CMP.
>
>I've managed to get JBoss to load the driver; so far so good. I'm doing this
>by putting this in jboss.jcml:
><mbean code="org.jboss.jdbc.JdbcProvider"
>name="DefaultDomain:service=JdbcProvider">
> <attribute
>name="Drivers">org.hsql.jdbcDriver,org.enhydra.instantdb.jdbc.idbDriver,org.postgresql.Driver</attribute>
> </mbean>
>
>Also almost at the end of jboss.jcml I put:
><!-- Add your custom MBeans here -->
><mbean name="DefaultDomain:service=XADataSource,name=PostgresDB">
> <attribute name="URL">jdbc:postgresql://linuxbox/testdb</attribute>
> <attribute name="JDBCUser">jan</attribute>
> <attribute name="Password">jan</attribute>
></mbean>
>
>
>Finally, at the very end of jboss.conf I put:
>
><MLET CODE="org.jboss.jdbc.XADataSourceLoader"
>ARCHIVE="jboss.jar,jdbc7.0-1.2.jar,minerva-1_0b3.jar"
>CODEBASE="../../lib/ext/">
> <ARG TYPE="java.lang.String" VALUE="PostgresDB">
> <ARG TYPE="java.lang.String"
>VALUE="org.opentools.minerva.jdbc.xa.wrapper.XADataSourceImpl">
></MLET>
>
>I have seen different specifications of doing this depending on using JBoss
>2.0 and 2.1, but unfortunately the documentation in general is bit "thin" on
>this subject.
>
>The errors I'm getting is in two parts:
>
>[Service Control] Registered with server
>[Configuration] Could not create MBean
>DefaultDomain:service=XADataSource,name=PostgresDB()
>[Configuration] java.lang.ClassNotFoundException:
>[Configuration] at
>javax.management.loading.MLet.findClass(MLet.java:800)
>
>and
>
>[Service Control] Initialized 25 services
>[Service Control] Starting 25 MBeans
>[PostgresDB] Starting
>[PostgresDB] Stopped
>[PostgresDB] java.lang.IllegalStateException: Cannot start XA Connection
>Pool; there is no TransactionManager in JNDI!
>[PostgresDB] at
>org.jboss.jdbc.XADataSourceLoader.startService(XADataSourceLoader.java:320)
>
>Also, looking at the konsole output when executing run.sh tells me that the
>postgres jdbc driver loads sometime between the two errors - I don't know if
>this is normal?
>
>Any help is much appreciated.
>
>
>Regards
>
>Jan Petersen
>
>
>
>
>
>_______________________________________________
>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