Mantis - Resin
Viewing Issue Advanced Details
2528 minor always 03-14-08 13:06 03-25-08 14:10
closed 3.1.5  
none 3.1.6  
0002528: amber initialization order
(rep by Riccardo Cohen)

I have one single entity ejb :

package adlejb;
public class Ejbuser
 @Id @Column(name="adlid") @GeneratedValue int id;
 @Basic @Column(name="adlfirstname") String firstname;
 @Basic @Column(name="adlname") String name;

and the config in persistence.xml is :

<persistence xmlns="" [^] version="1.0">
 <persistence-unit name="Adlhessian">
   <exclude-unlisted-classes />

But I continue to have the error =

com.caucho.amber.AmberRuntimeException: 'adlejb.Ejbuser' with classloader EnvironmentClassLoader[web-app:http://localhost:8000] [^] is an illegal instance class

What does it mean ? I found no error, and tried to have a look at mailinglist archive with no success. I looked at the samples, but found nothing really different...

The crazy about this is that I built this simple app from another simple app configured exactly the same manner, but the other does not make any amber error ! I tried to rename everything several times, but nothing seems to remove this error. I had the same problem sometimes with resin 3.0 and in 2006 Rodrigo Westrupp answered that I should work with resin 3.1.

<persistence xmlns="" [^] version="1.0">
 <persistence-unit name="Adlhessian">
   <exclude-unlisted-classes />
<web-app xmlns=""> [^]
 <database jndi-name="jdbc/adlhessian">
     <url>jdbc:mysql://localhost/adlhessian</url> [^]
     <init-param autoReconnect="true"/>
     <init-param noDatetimeStringSync="true"/>
     <init-param jdbcCompliantTruncation="false"/>
 <ejb-server data-source="jdbc/adlhessian" create-database-schema="false"/>
 <servlet servlet-name="adlservice" servlet-class="adlhessian.Adlservice"/>
 <servlet-mapping url-pattern="/adlservice/*" servlet-name="adlservice"/>

03-25-08 14:10