What properties are specified in your persistence.xml? Just from the information provided, my guess is that some of the tables are already present and match your entity definitions, so there's no need to modify anything? Now, if you are saying that you are starting with a cleanly created database each time, then something else is out of whack. The other common question is how are you enhancing your Entity classes [1]? If you are accidentally relying on the sub-classing support for enhancement, then that could be an issue as well.
Kevin [1] http://webspherepersistence.blogspot.com/2009/02/openjpa-enhancement.html On Mon, Jun 4, 2012 at 1:01 PM, Lukas Stampf <sta...@qse.ifs.tuwien.ac.at>wrote: > Hi, > > I am using openjpa 2.2.0 in conjunction with Apache Karaf. Database is the > current version of h2. > I have multiple bundles which have their own persistence.xml. They all > access the same database. > > My problem is the following: > 1) Sometimes the tables get created correct, so the general configuration > should be ok. > 2) But when it fails, there are tables missing. But it is not a whole > persistence-unit missing. The unit contains 7 entities, 3 get created the > remaining 4 get skipped. > 3) I dont get any exceptions, turning openjpa logging to trace also shows > none. All I see is 3 CREATE statements , where should be and sometimes are > 7. > > Anybody an idea what could go wrong? I already tried multiple flags > (multithreaded=true,....). Nothing worked. > > Any suggestion would be appreciated. > Lukas Stampf > >