geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark Aufdencamp" <>
Subject Upgrading 1.1 EAR to 2.1 - OpenEJB 3 CMP/CMR Issues
Date Fri, 05 Dec 2008 06:49:20 GMT
Hi All,

I'm upgrading an EAR from G 1.1.1-Win32-Tomcat to G 2.1.3-Linux-Tomcat. 
I've successfully installed G 2.1 and managed to deploy my Database
Pools and Security Realms. I've edited my geonimo-application.xml and
openejb-jar.xml to reflect the new deployment plan name space.  I've
managed to successfully deploy the EAR on the server. I even managed to
migrate my databases to the new server after learning some MySQL
intricacies of Win32 vs Linux table and column name case sensitivity.

I can access my application and login via the defined JDBC Security
Realm.  Now the good stuff.  It has an EJB 2.1 CMP/CMR component that
gets wrapped by OpenJPA in OpenEJB 3.  No problem, it should work,

I receive an OpenJPA PersistenceException when first accessing the
EntityBean from a Session Bean (I will double check the authenticity of
this location, I believe it's an initial EJB Query).  OpenJPA spits out
a generated SQL Statement that it doesn't like.  It appears to be an
OpenJPA Syntax check of a "SHOW CREATE TABLE TableName;"  It
incorporates a MySQL specific table command ( TYPE = "InnoDB" ).  This
might pass validation if it were the newer MySQL syntax - ENGINE =
"InnoDB".  The newest MySQL 5 Driver rather than the installed 3.1.12
from the Geronimo Driver Repository might fix this.  Poking around and
setting the MySQL sql_mode to ANSI seems to resolve this problem and
will probably be more compatible with the default Derby SQL statement
builder and syntax checker.  So, I should hopefully be SQL dialect
neutral at this point.

Now I can retrieve a query of the Entities to display, but the CMR
component seems to be broken.  I have a Null Pointer Exception generated
in the OpenEJB BaseEjbProxyHandler class with the CMR method identified.
 Further up the stack, SetValuedCmr in openejb.core.cmp.cmp2 is
identified as the culprit.  It appears that the CMR methods are broken
and not capable of constructing the necessary queries.  

Am I missing something in the deployment descriptors to do CMP/CMR in
OpenEJB 3?

Do I need to setup some persistence information in open-ejb.xml for CMP
to run in OpenEJB 3?

Does a MySQL specific QL driver exist for G 2.1/OpenEJB 3?

I haven't found any specific discussion of running CMP/CMR from G 1.1 in
G 2.1.  Does it exist or do I get to be the guy:)

TIA for the help and guidance,

Mark Aufdencamp

View raw message