db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pavel Bortnovskiy <pbortnovs...@jefferies.com>
Subject RE: NPE
Date Mon, 10 Dec 2012 18:07:38 GMT
Hello, Rick:

Thank you for your prompt response.
I'm currently using Derby 10.8.2.2.
Should I use the same version or upgrade?

Can you please also advise which debug jars I can use?

Thx,
Pavel.

-----Original Message-----
From: Rick Hillegas [mailto:rick.hillegas@oracle.com]
Sent: Monday, December 10, 2012 1:05 PM
To: derby-user@db.apache.org
Subject: Re: NPE

Hi Pavel,

Can you reproduce this problem with the debug version of Derby? That would give us line numbers
in the stack trace.

Thanks,
-Rick

On 12/10/12 9:23 AM, Pavel Bortnovskiy wrote:
>
> Hello:
>
> While testing my application, which uses Derby in memory-only mode, I
> get NPE inside Derby under "mysterious" circumstances.
>
> At this point, I can't even figure out what's triggering it and where
> this could happen, but let me preempt my troubleshooting with some
> stack traces. Perhaps someone, with good knowledge of Derby's code,
> may offer some explanation. Here are some stack traces:
>
> Mon Dec 10 12:12:36 EST 2012 Thread[DatabasePublisher[WRITER],5,main]
> (XID = 235), (SESSIONID = 5), (DATABASE = memory:test), (DRDAID =
> null), Failed Statement is: select * from READER
>
> java.lang.NullPointerException
>
> at
> org.apache.derby.impl.store.access.conglomerate.GenericScanController.
> reopenAfterEndTransaction(Unknown
> Source)
>
> at
> org.apache.derby.impl.store.access.conglomerate.GenericScanController.
> fetchRows(Unknown
> Source)
>
> at
> org.apache.derby.impl.store.access.heap.HeapScan.fetchNextGroup(Unknow
> n Source)
>
> at
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.reloadArray(U
> nknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.getNextRowCor
> e(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ProjectRestrictResultSet.getNextRowC
> ore(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getNextRo
> wFromSource(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getNextRo
> wCore(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRow(U
> nknown
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(Unknown
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedResultSet.next(Unknown Source)
>
> at QueryResults$1.hasNext(QueryResults.java:268)
>
> at DatabasePublisher.process(DatabasePublisher.java:318)
>
> at java.lang.Thread.run(Thread.java:662)
>
> or
>
> 2012-12-10 12:12:36,537 [DatabasePublisher[WRITER]] ERROR QueryResults
> - Unable to execute ResultSet.next() for Statement ""select * from
> READER" [DERBY]"
>
> java.sql.SQLException: Java exception: ': java.lang.NullPointerException'.
>
> at
> org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unkno
> wn
> Source)
>
> at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown
> Source)
>
> at org.apache.derby.impl.jdbc.Util.javaException(Unknown Source)
>
> at
> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(
> Unknown
> Source)
>
> at
> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unk
> nown
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown
> Source)
>
> at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown
> Source)
>
> at
> org.apache.derby.impl.jdbc.EmbedResultSet.closeOnTransactionError(Unkn
> own
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(Unknown
> Source)
>
> at org.apache.derby.impl.jdbc.EmbedResultSet.next(Unknown Source)
>
> at QueryResults$1.hasNext(QueryResults.java:268)
>
> at DatabasePublisher.process(DatabasePublisher.java:318)
>
> at java.lang.Thread.run(Thread.java:662)
>
> Caused by: java.sql.SQLException: Java exception: ':
> java.lang.NullPointerException'.
>
> at
> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown
> Source)
>
> at
> org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportA
> crossDRDA(Unknown
> Source)
>
> ... 14 more
>
> Caused by: java.lang.NullPointerException
>
> at
> org.apache.derby.impl.store.access.conglomerate.GenericScanController.
> reopenAfterEndTransaction(Unknown
> Source)
>
> at
> org.apache.derby.impl.store.access.conglomerate.GenericScanController.
> fetchRows(Unknown
> Source)
>
> at
> org.apache.derby.impl.store.access.heap.HeapScan.fetchNextGroup(Unknow
> n Source)
>
> at
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.reloadArray(U
> nknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.getNextRowCor
> e(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ProjectRestrictResultSet.getNextRowC
> ore(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getNextRo
> wFromSource(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.ScrollInsensitiveResultSet.getNextRo
> wCore(Unknown
> Source)
>
> at
> org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRow(U
> nknown
> Source)
>
> ... 6 more
>
> One more thing I can share is that this seems to also be a timing
> problem - if the code is executed slowly, line-by-line in the
> debugger, then this problem doesn't occur. But if run at full speed,
> then these exceptions are thrown. The problem is not intermittent and
> easily reproduced 100% of the time on my end.
>
> Any thoughts would be greatly appreciated.
>
> Pavel.
>
>
>
>             Jefferies archives and monitors outgoing and incoming
>             e-mail. The contents of this email, including any
>             attachments, are confidential to the ordinary user of the
>             email address to which it was addressed. If you are not
>             the addressee of this email you may not copy, forward,
>             disclose or otherwise use it or any part of it in any form
>             whatsoever. This email may be produced at the request of
>             regulators or in connection with civil litigation.
>             Jefferies accepts no liability for any errors or omissions
>             arising as a result of transmission. Use by other than
>             intended recipients is prohibited. In the United Kingdom,
>             Jefferies operates as Jefferies International Limited;
>             registered in England: no. 1978621; registered office:
>             Vintners Place, 68 Upper Thames Street, London EC4V 3BJ.
>             Jefferies International Limited is authorised and
>             regulated by the Financial Services Authority.
>


Jefferies archives and monitors outgoing and incoming e-mail. The contents of this email,
including any attachments, are confidential to the ordinary user of the email address to which
it was addressed. If you are not the addressee of this email you may not copy, forward, disclose
or otherwise use it or any part of it in any form whatsoever. This email may be produced at
the request of regulators or in connection with civil litigation. Jefferies accepts no liability
for any errors or omissions arising as a result of transmission. Use by other than intended
recipients is prohibited. In the United Kingdom, Jefferies operates as Jefferies International
Limited; registered in England: no. 1978621; registered office: Vintners Place, 68 Upper Thames
Street, London EC4V 3BJ. Jefferies International Limited is authorised and regulated by the
Financial Services Authority.

Mime
View raw message