Re: How to encrypt DB password in persistence.xml

2009-09-01 Thread wang yu
Hello, Mike, Do we have a target day for OpenJPA 2.0 GA? >From http://openjpa.apache.org/jpa-20-roadmap.html , may I assume it will be released before the end of the year? Both password Encryption and get cache from factory in JPA spec are very useful for me. I use Spring to manager the life circ

Re: How to persist then update in same transaction

2009-09-01 Thread Diane J
My DAO tests inherit from Springs AbstractJpaTests which start/commit the transaction for me. The only differences are that when I deploy to websphere, websphere handles the transactions and in test spring does and the other difference is that I enhance the classes when I deploy and donot when tes

Re: How to encrypt DB password in persistence.xml

2009-09-01 Thread Kevin Sutter
Hi, Yes, we do have plans to GA OpenJPA 2.0 before the end of the year, but it all depends on external factors which we have little control over. We need a finalized spec from the JCP -- current target date of Nov 16, 2009. And, we need a TCK (test suite) delivered at approximately the same timef

Re: How to persist then update in same transaction

2009-09-01 Thread Kevin Sutter
Why are you performing the merge()? Since you are doing all of this within a single transaction and you are not detaching any of these entities, there is no need to do the merge(). You have already persisted orgType earlier in your code path. So, go ahead and set the OwnerOrgId and then complete

Re: How to persist then update in same transaction

2009-09-01 Thread Rick Curtis
I would also suggest that you enhance [1] your Entities when you test, otherwise you test a different code path than what you run in WAS. Thanks, Rick On Tue, Sep 1, 2009 at 8:32 AM, Kevin Sutter wrote: > Why are you performing the merge()? Since you are doing all of this within > a single tra

Re: OpenJPA1.2.2 - NativeQuery - IN clause

2009-09-01 Thread HaricotBean
Thanks to all. I did try the Collection approach but OpenJPA generates an error and complains about the underlying type (ArrayList, HashSet, etc.) being an invalid type for th expression. Not being familiar with the OpenJPA source I took a quick look at fisheye for org.apache.openjpa.persistence

Re: OpenJPA1.2.2 - NativeQuery - IN clause

2009-09-01 Thread Fay Wang
Sorry, I probably confuse you about the JPQL and native (SQL) query. The Collection approach will work with JPQL, but not with SQL (native query, regardless it is named or not). For JPQL, the Query object is created in the following way: Query q = em.createQuery("select e from Entity1 e where e

RE: How to persist then update in same transaction

2009-09-01 Thread C N Davies
What I find is that if I retrieve an entity using an instance of the entity manager, then retrieve another type of entity using a different instance of the entity manager, then join the two entities, any attempt to call merge on the first entity causes OpenJPA to complain that the second entity is

performance hit from RestoreState=all?

2009-09-01 Thread Heather Sterling
Hi, I was wondering whether there was a performance hit by setting the following property or whether it was just a behavioral statement. Thanks, Heather Sterling

Re: How to persist then update in same transaction

2009-09-01 Thread Daryl Stultz
On Tue, Sep 1, 2009 at 1:39 PM, C N Davies wrote: > What I find is Chris, I thought you and I were done trying to figure out if my error condition is the same as yours! I'm intrigued by this new information of yours. Can you provide a simple code sketch that illustrates the problem you are havi

RE: How to persist then update in same transaction

2009-09-01 Thread C N Davies
Hi Daryl, I've moved one of my new apps to hibernate as I said I was going to, but I also have a smaller less time critical app I am still using OpenJPA for, this is the one where I see the behaviour described below. It's quite easy to reproduce, basically it works like this: Create an instance

Re: How to persist then update in same transaction

2009-09-01 Thread Daryl Stultz
On Tue, Sep 1, 2009 at 2:30 PM, C N Davies wrote: > > Hope I explained that ok. > > Thanks, when I get a chance I'll see if I can map it to my model. -- Daryl Stultz _ 6 Degrees Software and Consulting, Inc. http://www.6degrees.com mailto:da...@6degrees.com