openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Patrick Linskey" <plins...@gmail.com>
Subject Re: Slow JPA
Date Fri, 04 Apr 2008 15:18:26 GMT
Hi,

Are you calling merge() or persist() a lot? There's a known
inefficiency in 1.1.0-SNAPSHOT (not 1.0) with merging right now.

Also, what does the generated SQL look like in your examples?

-Patrick

On Fri, Apr 4, 2008 at 7:55 AM, Brill Pappin <brill@pappin.ca> wrote:
> We were using 1.0 in this project, but its showing up in another
>  project using 1.1.
>
>  I really *want* to use ojpa but I don't have time to mess around and
>  the problem is significant.
>  There seem to be other inefficiencies as well that don't seem to need
>  to be there.
>
>  Not sure what we're going to do about it though, all the ORM
>  frameworks are going through some sort of growing pain at the moment
>  and I can't say I'm happy with any of them.
>
>  - Brill Pappin
>
>
>
>  On Fri, Apr 4, 2008 at 10:44 AM, Patrick T <soberdrunk22@hotmail.com> wrote:
>  >
>  >  My issue is even just fetching the entities. Despite of changing
>  >  relationships to LAZY fetch, I find that querying the DB takes a really long
>  >  time. I have experienced the commit issue as well,but I've worked around
>  >  that by being careful on what I cascade through different entities.
>  >
>  >
>  >
>  >  Brill Pappin wrote:
>  >  >
>  >  > As a rule you can expect *any* orm framework to be slower than simple
>  >  > JDBC,
>  >  > there is simply more to do... What you gain from it is ease of maintenance
>  >  > and implementation which will save you time later (often a lot of time).
>  >  > As with anything, you need to weigh the benefits of any solution over
>  >  > another but in my experience most applications don't require such high
>  >  > throughput that anyone would notice a couple of milliseconds saved here
>  >  > and
>  >  > there... Of course it'll depend on what your doing :)
>  >  >
>  >  > However...
>  >  >
>  >  > I've just been doing some work tonight, and am finding that begin() ->
>  >  > commit() transactions take longer and longer (in my case I have a very
>  >  > large
>  >  > update that is broken down into chunks). I haven't traced the problem yet
>  >  > and it may be configuration related, however the time grows exponentially.
>  >  > Does that sound like the same problem you are having?
>  >  >
>  >  > - Brill
>  >  >
>  >  > -----Original Message-----
>  >  > From: Patrick T [mailto:soberdrunk22@hotmail.com]
>  >  > Sent: Friday, March 28, 2008 3:55 PM
>  >  > To: users@openjpa.apache.org
>  >  > Subject: Slow JPA
>  >  >
>  >  >
>  >  > Hello Everyone,
>  >  >
>  >  > I'm just wondering if anyone else is finding JPA slower than simple jdbc
>  >  > implementations. I have tried setting up some of the attributes to Lazy
>  >  > fetch and I still find it to be extremely slow. This is causing my web
>  >  > pages
>  >  > to load in the upwards of 10 seconds. I have tried running the PCEnhancer
>  >  > and still takes a long time to fetch data. Does anyone have any
>  >  > suggestions
>  >  > to speed it up? Thanks.
>  >  >
>  >  > Patrick
>  >  > --
>  >  > View this message in context:
>  >  > http://www.nabble.com/Slow-JPA-tp16360845p16360845.html
>  >  > Sent from the OpenJPA Users mailing list archive at Nabble.com.
>  >  >
>  >  >
>  >  >
>  >
>  >  --
>  >  View this message in context: http://www.nabble.com/Slow-JPA-tp16360845p16491755.html
>  >  Sent from the OpenJPA Users mailing list archive at Nabble.com.
>  >
>  >
>



-- 
Patrick Linskey
202 669 5907

Mime
View raw message