Thanks. That helped a bit. But only after editing the section for
DefaultDS, like this:

  <mbean code="org.jboss.jdbc.XADataSourceLoader"
name="DefaultDomain:service=XADataSource,name=DefaultDS">
    <attribute name="PoolName">DefaultDS</attribute>
    <attribute
name="DataSourceClass">org.opentools.minerva.jdbc.xa.wrapper.XADataSourceIm
pl</attribute>
    <attribute name="Properties"></attribute>

<!--
    <attribute
name="URL">jdbc:HypersonicSQL:hsql://localhost:1476</attribute>
-->
    <attribute
name="URL">jdbc:rmi://localhost:1099/jdbc:cloudscape:CloudscapeDB;create=tr
ue</attribute>

    <attribute name="GCMinIdleTime">1200000</attribute>
    <attribute name="JDBCUser">sa</attribute>
    <attribute name="MaxSize">10</attribute>
    <attribute name="Password" />
    <attribute name="GCEnabled">false</attribute>
    <attribute name="InvalidateOnError">false</attribute>
    <attribute name="TimestampUsed">false</attribute>
    <attribute name="Blocking">true</attribute>
    <attribute name="GCInterval">120000</attribute>
    <attribute name="IdleTimeout">1800000</attribute>
    <attribute name="IdleTimeoutEnabled">false</attribute>
    <attribute name="LoggingEnabled">false</attribute>
    <attribute name="MaxIdleTimeoutPercent">1.0</attribute>
    <attribute name="MinSize">0</attribute>
  </mbean>


I now have another problem:
>From a session bean I use an entity bean to read a string from a database
record. But the call blocks unless I set the transaction attribute for that
business method to 'Never'.
I use BMP and checked that the variable contains the correct value:

  public String getPassword() {
    System.out.println( "CCB.getPassword() - enter" );
    System.out.println( "CCB.getPassword() - m_password = " + m_password );
    return m_password;
  }

I don't get any output and the application hangs and finally the
transaction is rolled back, if the transaction attribute is 'Required'.

Any idea?

Ralph

----- Original Message -----
From: Roy Yip <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, July 04, 2001 11:22 PM
Subject: Re: [JBoss-user] How to map to cloudscape database


> Hi!
>
> You should have defined both "JdbcProvider" & "XADataSource" services in
> your jboss.jcml as something like :-
> ...
> <mbean code="org.jboss.jdbc.JdbcProvider"
> name="DefaultDomain:service=JdbcProvider">
>   <attribute
> name="Drivers">COM.cloudscape.core.RmiJdbcDriver</attribute>
> </mbean>
> ...
> <mbean code="org.jboss.jdbc.XADataSourceLoader"
> name="DefaultDomain:service=XADataSource,name=Cloudscape">
>   <attribute name="PoolName">Cloudscape</attribute>
>   ...
>   <attribute
>
name="URL">jdbc:rmi://localhost:1099/jdbc:cloudscape:CloudscapeDB;create=tr
ue</attribute>
>   ...
> </mbean>
> ...
> That should bring up something like :-
> ...
> [JDBC provider] Initializing
> [JDBC provider] Loaded COM.cloudscape.core.RmiJdbcDriver
> [JDBC provider] Initialized
> ...
> [Cloudscape] Starting
> [Cloudscape] XA Connection pool Cloudscape bound to java:/Cloudscape
> [Cloudscape] Started
> ...
> when you start jboss. Then in jboss.xml in your META-INF, do something
> like :-
> ...
> <resource-manager>
>   <res-name>jdbc/ConferenceDB</res-name>  <!-- the JNDI used by your EJB
> -->
>   <res-jndi-name>java:/Cloudscape</res-jndi-name>  <!-- the "actual"
> JNDI resource name bound by jboss -->
> </resource-manager>
> ...
>
> ralph wrote:
> >
> > I copied the cloudscape driver files to [jboss-home] \ lib \ ext.
> > Edited jboss.conf
> > Started jBoss.
> > Deployed a few beans in a jar-file.
> > Everything appears to be okay according to server.log and standard
output.
> > :-)
> >
> > Now:
> > What do I need to do in order to map my datasource name correctly,
meaning:
> >
> > In my beans I want to connect to Cloudscape this way:
> >
> >     DataSource ds = (DataSource)
> > nitial.lookup( "java:comp/env/jdbc/ConferenceDB" );
> >
> > The beans which should access cloudscape have the following
resource-ref in
> > ejb-jar.xml:
> > <resource-ref>
> >    <res-ref-name> jdbc/ConferenceDB </res-ref-name>
> >    <res-type> javax.sql.DataSource </res-type>
> >    <res-auth> Container </res-auth>
> >    <res-sharing-scope> Shareable </res-sharing-scope>
> > </resource-ref>
> >
> > Currently, after deploying my jar file, the output on port 8082 looks
like
> > this for these beans:
> >
> >   + env (class: org.jnp.interfaces.NamingContext)
> >   |   + jdbc (class: org.jnp.interfaces.NamingContext)
> >   |   |   + ConferenceDB[link -> java: / DefaultDS] (class:
> > javax.naming.LinkRef)
> >
> > I guess that should say Cloudscape instead of DefaultDS - or not ?
> >
> > I know it has something to do with jBoss.xml, but didn't find an
example
> > for that. What has to go into jboss.xml ?
> >
> > Thanks
> > Ralph
> >



_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to