Path: csiph.com!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: Cecil Westerhof Newsgroups: comp.lang.java.programmer Subject: Re: Performance JPA Date: Wed, 11 Nov 2015 06:20:51 +0100 Organization: Decebal Computing Lines: 45 Message-ID: <87oaf13ydo.fsf@Equus.decebal.nl> References: <87lhagkcsh.fsf@Equus.decebal.nl> <563763d9$0$23727$e4fe514c@news.xs4all.nl> <87d1vrk20x.fsf@Equus.decebal.nl> <87ziyvhs0r.fsf@Equus.decebal.nl> <87mvuui2ws.fsf@Equus.decebal.nl> <87si4e49ja.fsf@Equus.decebal.nl> <5641ba67$0$23779$e4fe514c@news.xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="528adfd6ad074c92fdc6a7f8fb9e23d8"; logging-data="25781"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX182qi2wVpNPAw5Nn7P0cnvQ39zwqtfJA7c=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) X-Homepage: http://www.decebal.nl/ Cancel-Lock: sha1:9eGyFuKc5xOh0jzyOlbtUf7HV/c= sha1:6Ly/kdtO03W6jbXJD9/NU00etb4= Xref: csiph.com comp.lang.java.programmer:33098 On Tuesday 10 Nov 2015 10:35 CET, silvio@internet.com wrote: > On 11/10/2015 08:07 AM, Cecil Westerhof wrote: >> >> I got some progress. Last week the old and new version where run in >> the same environment/database. The performance problem still stood. >> So there is certainly a problem with the new program. Because >> several things have changed I am not sure what would be the >> problem, but the rest is convinced it is a JPA problem. >> >> In principal database logging is going to be enabled, but I am >> waiting already a week for this. >> >> Yesterday I was told that the queries themselves do not take a lot >> of time. In my opinion it could then be one of the other changes. >> But I am told that JPA does a lot of things beside retrieving >> things out of the database and that those other things JPA is doing >> are the problem. Sounds far-fetched to me, but this is the first >> time I am working with JPA. Could they be right? If so: how do we >> pinpoint this? >> >> >> I think it is time for profiling. As long as we are not sure what >> the problem is, it is impossible to solve it. Until now I never had >> to profile in Java. We work with Eclipse Kepler and IBM WebSpere >> Application Server v8.0. What are good resources to learn to >> profile the code? >> > > Hello Cecil, > > Have you already looked into stuff like eager vs. lazy fetching? I > have come across lots of performance issues caused by eager > fetching. That is only important with relations, or not? Those are mot used. At list not on JPA level. There are some relations, but without link tables. So they are fetched manually. In JDBC and in JPA. In principal it is not possible to change the database, but I will try to get the link tables implemented so we can implement relations. -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof