I'm fairly new to this, so forgive me if my terminology and/or conclusions are wrong.
I spent the morning getting the dvdstore example (in jboss-seam-1.1.0.GA) to run using
mysql and tomcat/embeddable EJB.
Some things that got in the way:
1.
The example (out of the box, before switching to mysql from hsql) failed to start on
tomcat; I got a "javax.naming.NamingException: Local server is not initialized"
error. I figured out it was trying to start jbpm (org.jboss.seam.core.jbpm) before ejb
(org.jboss.seam.core.ejb). This failed because jbpm initializes hibernate which failed to
find the datasource in jndi (it gets bound during ejb initialization).
So I reordered the component definitions in components.xml, placing <core:ejb.../>
before <core:jbpm.../>. This solved it.
2.
The import.sql loading failed for 2 reasons. First, mysql apparently interprets
insert into ACTORS (ID, NAME) values (0, 'Audrey Hepburn') as
insert into ACTORS (NAME) values ('Audrey Hepburn')
and gives it an id of 1. This causes the second insert to fail the primary key
constraint.
Second, PRODUCTS.TITLE is defined to be a varchar(50) in Product.java, but product
67's title is 59 characters ("The Life Aquatic with Steve Zissou - Criterion
Collection ").
I changed import.sql, replacing Audrey's id of 0 with 68 throughout. I then changed
Product.java, line 90 from @Column(name="TITLE",nullable=false,length=50)
to
@Column(name="TITLE",nullable=false,length=100)
This solved it.
With those fixed, it runs fine.
Should I put one or more of these issues in jira?
Also, I noticed that (out of the box) the dvdstore tests (which use the Embedded EJB
container) correctly load ejb and then jbpm. Why would the behavior be any different on
tomcat?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3998079#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...