This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 146442 - [65cat] org.netbeans.api.db.explorer.DatabaseException: Communications link failure Last packet sent to the server was 39 ms ago.
Summary: [65cat] org.netbeans.api.db.explorer.DatabaseException: Communications link f...
Status: VERIFIED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: David Vancouvering
URL: http://statistics.netbeans.org/except...
Keywords:
: 127966 142639 147246 147365 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-09-07 20:01 UTC by big_al
Modified: 2008-09-18 17:05 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 107341


Attachments
stacktrace (5.22 KB, text/plain)
2008-09-07 20:01 UTC, big_al
Details

Note You need to log in before you can comment on or make changes to this bug.
Description big_al 2008-09-07 20:01:33 UTC
Build: NetBeans IDE Dev (Build 200809021401)
VM: Java HotSpot(TM) 64-Bit Server VM, 1.6.0_05-b13-52, Java(TM) SE Runtime Environment, 1.6.0_05-b13-120
OS: Mac OS X, 10.5.4, x86_64

User Comments: 
Opening table definitions

Stacktrace: 
org.netbeans.api.db.explorer.DatabaseException: Communications link failure

Last packet sent to the server was 39 ms ago.
        at org.netbeans.modules.db.explorer.infos.TableNodeInfo.initChildren(TableNodeInfo.java:167)
        at org.netbeans.modules.db.explorer.infos.TableNodeInfo.initChildren(TableNodeInfo.java:78)
        at org.netbeans.modules.db.explorer.infos.DatabaseNodeInfo.loadChildren(DatabaseNodeInfo.java:710)
        at org.netbeans.modules.db.explorer.infos.DatabaseNodeInfo.getChildren(DatabaseNodeInfo.java:698)
        at org.netbeans.modules.db.explorer.nodes.DatabaseNode$DatabaseNodeChildFactory.createKeys(DatabaseNode.java:382)
        at org.openide.nodes.AsynchChildren.run(AsynchChildren.java:147)
Comment 1 big_al 2008-09-07 20:01:43 UTC
Created attachment 69253 [details]
stacktrace
Comment 2 David Vancouvering 2008-09-08 17:39:22 UTC
It looks like the connection went down, but we should be catching this and displaying a useful error dialog rather than
reporting an exception.
Comment 3 big_al 2008-09-08 18:46:09 UTC
That's correct. I believe that I had left the laptop for a long time causing the connection to time out. What worried me
a bit was the fact that I couldn't reconnect to the database without restarting NetBeans. In the service tab it would
show that I had disconnected and re-connected successfully, but every time I tried to obtain the table definitions or
view data it would give me the same exception about Communication link failure. I did confirm that I could connect to
the database outside NetBeans.
Comment 4 David Vancouvering 2008-09-08 19:30:02 UTC
Oh, that's particularly disconcerting.  I'll see if I can reproduce.
Comment 5 John Baker 2008-09-08 20:35:00 UTC
Looks like the same issue as 142639
I was waiting for the "test" method but I guess it's been implemented and ready to use
Comment 6 David Vancouvering 2008-09-09 00:58:18 UTC
*** Issue 127966 has been marked as a duplicate of this issue. ***
Comment 7 David Vancouvering 2008-09-09 01:02:44 UTC
*** Issue 142639 has been marked as a duplicate of this issue. ***
Comment 8 David Vancouvering 2008-09-09 01:31:30 UTC
*** Issue 145942 has been marked as a duplicate of this issue. ***
Comment 9 David Vancouvering 2008-09-16 21:52:10 UTC
It's pretty easy to reproduce this, BTW:

- Start MySQL
- Connect to a database
- Open up the table node
- Stop MySQL
- Start MySQL
- Enjoy the exception
Comment 10 David Vancouvering 2008-09-17 00:46:07 UTC
9b6a38761855

Fixed this by having a method that checks the connection, and if it's lost, ask the user if they want to reconnect
Comment 11 David Vancouvering 2008-09-17 19:44:57 UTC
*** Issue 147246 has been marked as a duplicate of this issue. ***
Comment 12 Quality Engineering 2008-09-18 05:27:19 UTC
Integrated into 'main-golden', will be available in build *200809180201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/9b6a38761855
User: David Van Couvering <davidvc@netbeans.org>
Log: #146442: [65cat] org.netbeans.api.db.explorer.DatabaseException: Communications link failure Fixed this by having a method that checks the connection, and if it's lost, ask the user if they want to reconnect
Comment 13 Roman Mostyka 2008-09-18 13:58:08 UTC
Verified with build 080918.
Comment 14 David Vancouvering 2008-09-18 17:05:30 UTC
*** Issue 147365 has been marked as a duplicate of this issue. ***