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.
jdk6.0_05, netbeans-hudson-trunk-1247-javaee -start IDE w/ fresh user dir -expand Databases node in services tab => see attachment
Created attachment 58898 [details] screenshot
Hi, jungi, can you please tell me the date on this build? I checked in some changes on Friday, and I want to know if this is something you have seen on a build *after* or *before* this change. If you can tell me the actual Mercurial revision number, even better. Thanks, David
Hi David, the build is from today evening CET, only few hours old - 23.3.2008 17:53:54 - see: http://deadlock.netbeans.org/hudson/job/trunk/1247/ for more details (not sure how long the link will be active) I can also reproduce this in my own build from today's morning on JDK5.0.15, hg tip shows: D:\hg\development>hg tip changeset: 75022:b911c98a7c14 tag: tip user: jungi@netbeans.org date: Sun Mar 23 18:38:58 2008 +0100 summary: IZ #119811: Missing/incorrect step name in samples wizard
btw: the order of steps seems to be quite important here, so: if I start the IDE with fresh userdir, expand databases node, register glassfish and check DB nodes then everything seems to be OK if I start the IDE with fresh userdir, register glassfish, expand databases node and check DB nodes then sample DB connection is shown twice as on a screenshot I attached. --lukas
there seems to be something strange, see attached screenshot (sorry, I really don't remember what I've done now...)
Created attachment 58905 [details] screenshot
Great, thanks for the details, jungi.
Just tried this on my Mac, and I can't reproduce. I'll try on XP. I don't have a Vista installation...
I'm not sure what happened, but I can now reliably reproduce this even without registering Glassfish. Investigating...
http://hg.netbeans.org/main?cmd=changeset;node=14f68c0f292c
still reproducible in 6.1 see attached screenshot note that my current steps we're a bit different: -started IDE with fresh userdir -create some web app and work with it for a while -go to services tab and expand the DB node => there was no jdbc/sample connection registered -never mind, I created my own DB (music) and got to issue 132037 -well, so I restarted the IDE, went to DB node and expanded it => jdbc/sample connection is registered twice
Created attachment 59845 [details] screenshot from mostly up-to-date (~6hours old) 6.1rc1
Hm, what you're describing sounds like a slightly different bug, but same behavior. Can you make the duplicate connection go away with a restart?
Unfortunately no - restart doesn't remove the duplicated node :( Do you want me to file another bug for that and let this one be closed?
No, it's OK, we can use this bug.
OK, reproduced on Windows XP off of a fresh trunk build. Just to be clear, this is based off of a build with -Dcluster.config=standard, and I pre-register Glassfish by setting -J-Dcom.sun.aas.installRoot=/path/to/Glassfish when I start NB. I will try this on MacOS rather than in my XP instance, as it's easier to work directly in Mac.
Bummer, can't reproduce on Mac. This means trying to debug across the virtual machine boundary. Not fun.
OK, I just looked and config/Databases/Connections actually physically has two copies of the sample connection. Now I need to figure out why it's being registered twice. BTW, I can't reproduce issue 132027 - the sample connections are visible the first time, without restart required.
OK, I just looked and config/Databases/Connections actually physically has two copies of the sample connection. Now I need to figure out why it's being registered twice. BTW, I can't reproduce issue 132027 - the sample connections are visible the first time, without restart required. Also, ugh, the Java DB node is not visible, so this is a one-two punch of a bug.
More info: - You can reproduce duplicate connection without having to create a web project - The missing Java DB (and MySQL) nodes is random. This is actually a separate bug that I closed because I couldn't reproduce, but I will re-open it. I logged when the method createSampleDatabase() was run in the derby module, and it's only run once, but we end up with two connections. So I haven't found the culprit yet.
OK, two separate modules are trying to create and register the sample database. Here are the stack traces: java.lang.Exception: Stack trace at java.lang.Thread.dumpStack(Thread.java:1206) at org.netbeans.modules.derby.api.DerbyDatabases.registerDatabase(DerbyDatabases.java:361) at org.netbeans.modules.derby.api.DerbyDatabases.createSampleDatabase(DerbyDatabases.java:282) at org.netbeans.modules.j2ee.sun.ide.j2ee.db.RegisterPointbase$ConfigureJavaDBSamples.run(RegisterPointbase.java:319) java.lang.Exception: Stack trace at java.lang.Thread.dumpStack(Thread.java:1206) at org.netbeans.modules.derby.api.DerbyDatabases.registerDatabase(DerbyDatabases.java:361) at org.netbeans.modules.derby.api.DerbyDatabases.createSampleDatabase(DerbyDatabases.java:282) at org.netbeans.modules.derby.Installer$RegisterJDKDerby.registerSampleDatabase(Installer.java:108) at org.netbeans.modules.derby.Installer$RegisterJDKDerby.run(Installer.java:87) There appears to be a timing issue, because registerDatabase calls ConnectionManager.addConnection(), and this in turn calls RootNodeInfo.addConnectionNoConnect(), which has the following code: if (ConnectionList.getDefault().contains(dbconn)) { return; } It looks like both threads check the ConnectionList simultaneously and then both add their connection to the list. addConnectionNoConnect should probably synchronize checking the list and then adding to the list.
http://hg.netbeans.org/main?cmd=changeset;node=96c2d254192c
As per previous comment, this is fixed now.
Integrated into 'main-golden', available in NB_Trunk_Production #271 build Changeset: http://hg.netbeans.org/main/rev/96c2d254192c User: David Van Couvering <davidvc@netbeans.org> Log: #130877 - Java DB sample connection was showing up twice Fixed by adding necessary synchronization when working with ConnectionList
Lukasi, can you please verify the bugfix in trunk builds. Only verified bugfixes can go into NB 6.1 Patch (3) release. Thanks, -R
v. in trunk
I've transplanted the changeset http://hg.netbeans.org/main?cmd=changeset;node=96c2d254192c into release61_fixes repository as http://hg.netbeans.org/release61_fixes?cmd=changeset;node=e6ec4dcef5ec The changeset http://hg.netbeans.org/main?cmd=changeset;node=14f68c0f292c was already part of release61_fixes source base see http://hg.netbeans.org/release61_fixes?cmd=changeset;node=14f68c0f292c for ref.