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.
[#2007081300, jdk1.5.0] to reproduce: ------------- 1) stop Derby if running 2) invoke Tools > Java DB Database > Create Database... 3) enter Database Name 4) click OK ERROR: IDE throws:
Created attachment 46594 [details] java.net.ConnectException: Connection refused
Right, it should wait. But note that after 5 seconds it will display a dialog asking the user whether to wait more (as it currently does when starting the server while making a connection from the Runtime tab). Will this play nicely with the T9Y keyword? If not, perhaps I could provide a method to start the database in tests, which would display no dialogs and which the test would call before creating a database.
*** Issue 113815 has been marked as a duplicate of this issue. ***
We are solving similar problem in automated tests, a method like: DerbyRegistry.getDefault().isStarted(); which will return true only if the database is running and ready to accept connections, would come in useful.
Build: NetBeans IDE Dev (Build 200709200000) VM: Java HotSpot(TM) Client VM, 1.6.0_03-b02 OS: Linux, 2.6.20-16-generic, i386 User Comments: if derby is not running and i want to create database ( in tools ->...), warning window appears telling server is not listening on port 1527 (thats true)...but exception i would not expect. And of course in this case i would expect that server will start and after that db will be created.
Created attachment 49138 [details] stacktrace
Fixed. Checking in src/org/netbeans/modules/derby/RegisterDerby.java; /cvs/db/derby/src/org/netbeans/modules/derby/RegisterDerby.java,v <-- RegisterDerby.java new revision: 1.31; previous revision: 1.30 done Checking in src/org/netbeans/modules/derby/api/DerbyDatabases.java; /cvs/db/derby/src/org/netbeans/modules/derby/api/DerbyDatabases.java,v <-- DerbyDatabases.java new revision: 1.7; previous revision: 1.6 done
Build: NetBeans IDE Dev (Build 200910170201) VM: Java HotSpot(TM) 64-Bit Server VM, 14.2-b01, Java(TM) SE Runtime Environment, 1.6.0_16-b01 OS: Linux, 2.6.28-15-generic, amd64 User Comments: Stacktrace: java.net.ConnectException: Connection timed out at java.net.PlainSocketImpl.socketConnect(PlainSocketImpl.java:0) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:525)
Created attachment 89712 [details] stacktrace