No solutions but a question. I am trying to use MySQL with the petstore
1.1.2. Which files did you adapt to make things work? When i try to rebuild
the petstore i get an error (assemble application....)

Thanks,
Maarten
----- Original Message -----
From: "Marcel Schepers" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, May 28, 2001 12:15 PM
Subject: Re: R: [JBoss-user] petstore mail/MailSession & db connection
errors


> Hello,
>
> I have a question regarding an error I get. In a JSP page I use a
> regular Java bean. Some properties are set and at the end I call the
> bean's create() methode to actually create a new EJB Entity bean.
> Creating the EJB fails: I get the error attached to the end of this
> message. Now the funny part is that the database contains the new EJB
> data. The question I would like to ask you: where to look for the
solution?
>
> The code I use in my regular Java access bean:
>
>    public void createEJB(){
>    if (DEBUG) {
>        System.out.println("FormAccessBean.create() --- entry");
>    } // end of if (DEBUG)
>
>    try{
>        String jndiName = "stam/Form";
>        Broker broker = Broker.getInstance();
>        FormHome formHome = (FormHome)
>        broker.getHome(jndiName, FormHome.class);
>
>        Form form = formHome.create(this.voorletters, this.tussenvoegsel,
>                    this.naam, this.adres, this.postcode,
>                    this.woonplaats, this.telefoonDag,
>                    this.telefoonAvond, this.geboortedatum,
>                    this.geslacht, this.email, this.groep,
>                    this.vrijeInvoer);
>
>        if (DEBUG) {
>        System.out.println("Form: " + form);
>        } // end of if (DEBUG)
>     }
>         ....
>     }
>
>
> I have a feeling that my mySQL transaction management is not
> configured properly. These are my mySQL settings in jboss.jcml
>
>   <!-- JDBC -->
>   <mbean code="org.jboss.jdbc.JdbcProvider"
>     name="DefaultDomain:service=JdbcProvider">
>    <attribute
>
>
name="Drivers">org.hsql.jdbcDriver,org.enhydra.instantdb.jdbc.idbDriver,org.
gjt.mm.mysql.Driver</attribute>
>
>
>   </mbean>
>   <mbean code="org.jboss.jdbc.XADataSourceLoader"
>     name="DefaultDomain:service=XADataSource,name=mySQLPool">
>    <attribute name="PoolName">mySQLPool</attribute>
>    <attribute
>
name="DataSourceClass">org.opentools.minerva.jdbc.xa.wrapper.XADataSourceImp
l</attribute>
>    <attribute name="Properties"></attribute>
>    <attribute name="URL">jdbc:mysql://x.x.nl/stam</attribute>
>    <attribute name="GCMinIdleTime">1200000</attribute>
>    <attribute name="JDBCUser">x</attribute>
>    <attribute name="MaxSize">10</attribute>
>    <attribute name="Password">x</attribute>
>    <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>
>
> And finally, I've attached the start of the error log messages.
>
>
> [EmbeddedTomcat] FormAccessBean.create() --- entry
> [Form] TRANSACTION ROLLBACK EXCEPTION:ejbCreate: null; nested exception
is:
>    javax.ejb.EJBException: ejbCreate: null
> [Form] javax.ejb.EJBException: ejbCreate: null
> [Form]     at
nl.inpact.stam.ejb.form.FormBean.ejbCreate(FormBean.java:168)
> [Form]     at java.lang.reflect.Method.invoke(Native Method)
> [Form]     at
>
org.jboss.ejb.plugins.BMPPersistenceManager.createEntity(BMPPersistenceManag
er.java:121)
> [Form]     at
> org.jboss.ejb.EntityContainer.createHome(EntityContainer.java:441)
> [Form]     at java.lang.reflect.Method.invoke(Native Method)
> [Form]     at
>
org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityContaine
r.java:639)
> [Form]     at
>
org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySync
hronizationInterceptor.java:160)
> [Form]     at
>
org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInt
erceptor.java:87)
> [Form]     at
>
org.jboss.ejb.plugins.TxInterceptorCMT.invokeNext(TxInterceptorCMT.java:135)
> [Form]     at
>
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.
java:263)
> [Form]     at
>
org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:86)
> [Form]     at
>
org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.jav
a:164)
> [Form]     at
> org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:106)
> [Form]     at
> org.jboss.ejb.EntityContainer.invokeHome(EntityContainer.java:316)
> [Form]     at
>
org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome(JRMPContai
nerInvoker.java:436)
> [Form]     at
> org.jboss.ejb.plugins.jrmp.interfaces.HomeProxy.invoke(HomeProxy.java:212)
> [Form]     at $Proxy9.create(Unknown Source)
> [Form]     at
> nl.inpact.stam.ejb.form.FormAccessBean.createEJB(FormAccessBean.java:128)
> [Form]     at
>
_0002fformhandle_0002ejspformhandle_jsp_29._jspService(_0002fformhandle_0002
ejspformhandle_jsp_29.java:432)
>
> Thank you,
>
> Marcel
>
>
> _______________________________________________
> 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

Reply via email to