From dev-return-14072-apmail-openjpa-dev-archive=openjpa.apache.org@openjpa.apache.org Thu Oct 22 22:10:22 2009 Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 19747 invoked from network); 22 Oct 2009 22:10:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 22 Oct 2009 22:10:22 -0000 Received: (qmail 46783 invoked by uid 500); 22 Oct 2009 22:10:22 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 46732 invoked by uid 500); 22 Oct 2009 22:10:22 -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 46710 invoked by uid 99); 22 Oct 2009 22:10:22 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Oct 2009 22:10:22 +0000 X-ASF-Spam-Status: No, hits=-10.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI 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; Thu, 22 Oct 2009 22:10:19 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 7AC5B234C1EF for ; Thu, 22 Oct 2009 15:09:59 -0700 (PDT) Message-ID: <1572673910.1256249399501.JavaMail.jira@brutus> Date: Thu, 22 Oct 2009 22:09:59 +0000 (UTC) From: "Pinaki Poddar (JIRA)" To: dev@openjpa.apache.org Subject: [jira] Commented: (OPENJPA-1355) Recent snaphot versions of openjpa have problem with postgresPreparedStatementImpl constructor making Postgres impossible to use In-Reply-To: <358517201.1256051699566.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/OPENJPA-1355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12768935#action_12768935 ] Pinaki Poddar commented on OPENJPA-1355: ---------------------------------------- Hi Krzysztof, Thanks for finding this out. Fixed now -- can you try the fix? > Recent snaphot versions of openjpa have problem with postgresPreparedStatementImpl constructor making Postgres impossible to use > -------------------------------------------------------------------------------------------------------------------------------- > > Key: OPENJPA-1355 > URL: https://issues.apache.org/jira/browse/OPENJPA-1355 > Project: OpenJPA > Issue Type: Bug > Components: jdbc > Affects Versions: 2.0.0-M4 > Environment: -S1 snapshots from maven. pg jdbc driver 8.[3|4], pg 8.4 > Reporter: Krzysztof > Assignee: Pinaki Poddar > Priority: Blocker > > When calling prepared statement for the first time, following exception started to occur after upgrading to the latest snaphots (it worked in M3): > > java.lang.ExceptionInInitializerError: null > org.apache.openjpa.lib.util.ConcreteClassGenerator.newInstance(ConcreteClassGenerator.java:132) > org.apache.openjpa.jdbc.sql.PostgresDictionary$PostgresConnection.prepareStatement(PostgresDictionary.java:697) > org.apache.openjpa.lib.jdbc.DelegatingConnection.prepareStatement(DelegatingConnection.java:328) > org.apache.openjpa.jdbc.kernel.JDBCStoreManager$RefCountConnection.prepareStatement(JDBCStoreManager.java:1560) > org.apache.openjpa.lib.jdbc.DelegatingConnection.prepareStatement(DelegatingConnection.java:317) > org.apache.openjpa.jdbc.sql.SQLBuffer.prepareStatement(SQLBuffer.java:546) > org.apache.openjpa.jdbc.sql.SelectImpl.prepareStatement(SelectImpl.java:452) > org.apache.openjpa.jdbc.sql.SelectImpl.execute(SelectImpl.java:389) > org.apache.openjpa.jdbc.sql.SelectImpl.execute(SelectImpl.java:363) > org.apache.openjpa.jdbc.sql.LogicalUnion$UnionSelect.execute(LogicalUnion.java:427) > org.apache.openjpa.jdbc.sql.LogicalUnion.execute(LogicalUnion.java:230) > org.apache.openjpa.jdbc.sql.LogicalUnion.execute(LogicalUnion.java:220) > org.apache.openjpa.jdbc.kernel.SelectResultObjectProvider.open(SelectResultObjectProvider.java:94) > org.apache.openjpa.kernel.QueryImpl$PackingResultObjectProvider.open(QueryImpl.java:2027) > org.apache.openjpa.lib.rop.WindowResultList.(WindowResultList.java:57) > org.apache.openjpa.jdbc.kernel.JDBCFetchConfigurationImpl.newResultList(JDBCFetchConfigurationImpl.java:278) > org.apache.openjpa.kernel.QueryImpl.toResult(QueryImpl.java:1239) > org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:1000) > org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:856) > org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:787) > org.apache.openjpa.kernel.DelegatingQuery.execute(DelegatingQuery.java:525) > org.apache.openjpa.persistence.QueryImpl.execute(QueryImpl.java:291) > org.apache.openjpa.persistence.QueryImpl.getResultList(QueryImpl.java:303) > gaia.cu7.dal.VariStore.fetchSourcesHistogram(VariStore.java:733) > gaia.cu7.dal.VariStore.getSourcesHistogram(VariStore.java:689) > gaia.cu7.omimpl.test.SourceImplTest.testHistogramCreation(SourceImplTest.java:930) > sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > java.lang.reflect.Method.invoke(Method.java:597) > org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44) > org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15) > org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41) > org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20) > org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28) > org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31) > org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:73) > org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:46) > org.junit.runners.ParentRunner.runChildren(ParentRunner.java:180) > org.junit.runners.ParentRunner.access$000(ParentRunner.java:41) > org.junit.runners.ParentRunner$1.evaluate(ParentRunner.java:173) > org.junit.runners.ParentRunner.run(ParentRunner.java:220) > Caused by: java.lang.IllegalArgumentException: wrong number of arguments > sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) > sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) > sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) > java.lang.reflect.Constructor.newInstance(Constructor.java:513) > org.apache.openjpa.lib.util.ConcreteClassGenerator.newInstance(ConcreteClassGenerator.java:130) > This might be related to the svn revision: > Revision 813149 - (view) (annotate) - [select for diffs] > Modified Wed Sep 9 22:43:49 2009 UTC (5 weeks, 5 days ago) by ppoddar > OPENJPA-1285: Dynamic JDBC 4 Wrappers use constructor to save reflection cost > seems the offending statement from org.apache.openjpa.jdbc.sql.PostgresDictionary$PostgresConnection.prepareStatement(PostgresDictionary.java:697) > has wrong number of parameters: > ... > return ConcreteClassGenerator. > newInstance(postgresPreparedStatementImpl, > PreparedStatement.class, > super.prepareStatement(sql, rsType, rsConcur, false), > Connection.class, PostgresConnection.this, > PostgresDictionary.class, _dict); > Are the type classes really needed here? > Could you confirm it passes your internal tests for postgres on the openjpa trunk if you think this problem is caused by something else? > Best regards, > Krzysztof -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.