You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by SB...@ILSTechnology.com on 2005/04/03 13:46:29 UTC

No current connection exception

Hi,
        I have apache derby 10.0 running on a MontaVista Linux system (3.1
Professional with Linux/i686 2.4.20)  in embedded mode.
The java level is Sun's jre 1.4.2_04.
There are around 500,000 records in a table in the DB.
I have one thread inserting rows into this table at a rate of around 50
msecs.
Another thread is periodically doing selects on this table and some
deletes.
After running for about 10 hours the thread that is inserting rows catches
a SQLException with the follwing details:

SQLError is 40000
 SQLState is 08003
 SQL Error Message is 'No current connection'

No other thread in the VM has issed a shutdown request to derby.

What conditions could cause the DB to close connections to it ? Has anyone
else seen this error before ?
The error does not occur consistently.

Thanks in advance.
Sunil.





Re: No current connection exception

Posted by SB...@ILSTechnology.com.
 Thanks for the pointer to look at derby.log.
It indicated that derby hit an OutOfMemory exception and shut the Db down.
Once that occurred all requests made to the DB got the 40000/08003 error.

Sunil




|---------+----------------------------->
|         |           Kathey Marsden    |
|         |           <kmarsdenderby@sbc|
|         |           global.net>       |
|         |                             |
|         |           04/03/2005 04:20  |
|         |           PM                |
|         |           Please respond to |
|         |           "Derby Discussion"|
|---------+----------------------------->
  >---------------------------------------------------------------------------------------------------------------------------------------|
  |                                                                                                                                       |
  |       To:       Derby Discussion <de...@db.apache.org>                                                                           |
  |       cc:                                                                                                                             |
  |       Subject:  Re: No current connection exception                                                                                   |
  >---------------------------------------------------------------------------------------------------------------------------------------|




SBarboza@ILSTechnology.com wrote:

>Hi,
>        I have apache derby 10.0 running on a MontaVista Linux system (3.1
>Professional with Linux/i686 2.4.20)  in embedded mode.
>The java level is Sun's jre 1.4.2_04.
>There are around 500,000 records in a table in the DB.
>I have one thread inserting rows into this table at a rate of around 50
>msecs.
>Another thread is periodically doing selects on this table and some
>deletes.
>After running for about 10 hours the thread that is inserting rows catches
>a SQLException with the follwing details:
>
>SQLError is 40000
> SQLState is 08003
> SQL Error Message is 'No current connection'
>
>No other thread in the VM has issed a shutdown request to derby.
>
>What conditions could cause the DB to close connections to it ? Has anyone
>else seen this error before ?
>The error does not occur consistently.
>
>Thanks in advance.
>Sunil.
>
>
>
>
>
>
>
No clear cut answers except to say it doesn't sound like you should lose
your connection in the scenario you describe.
Sounds like something went wrong before you lost your connection, so I
am not sure how helpful it would be to look at the trace at the time you
got the "no Current Connection"  error.

Here are a few hints for debugging the problem.

Check the derby.log and see if you see a trace.
Check the connection on the thread doing the select to determine if it
is a problem specific to this connection or to the entire derby system.

If that is not revealing make a file called  derby.properties in
derby.system.home (or the directory where java starts if
derby.system.home is not set) and put the following lines in it., rerun
and look at the derby.log again.

derby.stream.error.logSeverityLevel=0
derby.language.logStatementText=true

This might generate a lot of output in your scenario, but is usually
helpful in debugging something like this  since the problem shows up
right at the end of the derby.log if the program exits after the failure.

Kathey








Re: No current connection exception

Posted by Kathey Marsden <km...@sbcglobal.net>.
SBarboza@ILSTechnology.com wrote:

>Hi,
>        I have apache derby 10.0 running on a MontaVista Linux system (3.1
>Professional with Linux/i686 2.4.20)  in embedded mode.
>The java level is Sun's jre 1.4.2_04.
>There are around 500,000 records in a table in the DB.
>I have one thread inserting rows into this table at a rate of around 50
>msecs.
>Another thread is periodically doing selects on this table and some
>deletes.
>After running for about 10 hours the thread that is inserting rows catches
>a SQLException with the follwing details:
>
>SQLError is 40000
> SQLState is 08003
> SQL Error Message is 'No current connection'
>
>No other thread in the VM has issed a shutdown request to derby.
>
>What conditions could cause the DB to close connections to it ? Has anyone
>else seen this error before ?
>The error does not occur consistently.
>
>Thanks in advance.
>Sunil.
>
>
>
>
>
>  
>
No clear cut answers except to say it doesn't sound like you should lose
your connection in the scenario you describe.
Sounds like something went wrong before you lost your connection, so I
am not sure how helpful it would be to look at the trace at the time you
got the "no Current Connection"  error.

Here are a few hints for debugging the problem.

Check the derby.log and see if you see a trace.
Check the connection on the thread doing the select to determine if it
is a problem specific to this connection or to the entire derby system.

If that is not revealing make a file called  derby.properties in
derby.system.home (or the directory where java starts if
derby.system.home is not set) and put the following lines in it., rerun
and look at the derby.log again.

derby.stream.error.logSeverityLevel=0
derby.language.logStatementText=true

This might generate a lot of output in your scenario, but is usually
helpful in debugging something like this  since the problem shows up
right at the end of the derby.log if the program exits after the failure.

Kathey