From dev-return-7744-apmail-openjpa-dev-archive=openjpa.apache.org@openjpa.apache.org Fri Apr 04 11:11:58 2008 Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 67086 invoked from network); 4 Apr 2008 11:11:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 4 Apr 2008 11:11:58 -0000 Received: (qmail 14066 invoked by uid 500); 4 Apr 2008 11:11:57 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 14014 invoked by uid 500); 4 Apr 2008 11:11:57 -0000 Mailing-List: contact dev-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openjpa.apache.org Delivered-To: mailing list dev@openjpa.apache.org Received: (qmail 13993 invoked by uid 99); 4 Apr 2008 11:11:57 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Apr 2008 04:11:57 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Apr 2008 11:11:23 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 6054E234C0B9 for ; Fri, 4 Apr 2008 04:09:24 -0700 (PDT) Message-ID: <1740207744.1207307364393.JavaMail.jira@brutus> Date: Fri, 4 Apr 2008 04:09:24 -0700 (PDT) From: "Christiaan (JIRA)" To: dev@openjpa.apache.org Subject: [jira] Updated: (OPENJPA-558) Performance difference between Oracle and Sql server of a factor 2 to 3 In-Reply-To: <589150524.1207307364336.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/OPENJPA-558?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Christiaan updated OPENJPA-558: ------------------------------- Attachment: Oracle Performance.zip > Performance difference between Oracle and Sql server of a factor 2 to 3 > ----------------------------------------------------------------------- > > Key: OPENJPA-558 > URL: https://issues.apache.org/jira/browse/OPENJPA-558 > Project: OpenJPA > Issue Type: Improvement > Environment: Kodo 4.1.4 (sql server 2005, Oracle 10, Oracle 11, ojdbc6 oracle driver) > Reporter: Christiaan > Attachments: Oracle Performance.zip > > > I am trying to include support for Oracle in our product. It currently supports ms sql server. One of the things I noticed is that many of our unit tests perform a factor 2 to 3 slower. I managed to isolate one of the performance bottlenecks which is included in the attached testcase. The persistent class is basically a 1-to-many relation with itself. The performance bottleneck is for the code being executed on getParent(). On my machine it gives the following output: > ============Executing test for Oracle============= > There are now 1110 components > Getting 1110 parents took 453ms > Getting 1110 parents with direct SQL took 156ms > ============Executing test for SQL============= > There are now 1110 components > Getting 1110 parents took 156ms > Getting 1110 parents with direct SQL took 156ms > Note, for both sql server and oracle I didn't do any performance tuning. One thing to note is that Oracle doesn't generate join syntax (which is probably related to issue openjpa-541). I tried setting fetchConfig.setJoinSyntax(JoinSyntaxes.SYNTAX_SQL92), but this didn't have any effect. However, executing the "and" syntax version versus the join syntax version with direct sql gives a time difference of 176 ms vs 156 ms. So this doesn't really explain the performance difference. I also tried a different oracle driver (datadirect) but this didn't give much difference either. Could this performance difference be caused by openjpa code? Did anyone encounter this as well? -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.