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 232820 - When netbeans is restarted under debugger, build is failed
Summary: When netbeans is restarted under debugger, build is failed
Status: NEW
Alias: None
Product: debugger
Classification: Unclassified
Component: Java (show other bugs)
Version: 7.2
Hardware: PC Linux
: P4 normal (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-16 15:05 UTC by Milutin Kristofic
Modified: 2013-08-27 12:01 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
The patch (599 bytes, patch)
2013-08-27 12:01 UTC, Martin Entlicher
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Milutin Kristofic 2013-07-16 15:05:51 UTC
1, run netbeans in debug mode inside netbeans
2, Open options and change laf to Dark Nimbus
3, Netbeans give you option to restart - restart netbeans
4, restart failed and this is in output:

FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=AGENT_ERROR_TRANSPORT_INIT(197)
ERROR: transport error 202: connect failed: Connection refused
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [../../../src/share/back/debugInit.c:741]
/home/mito/nb/jet-main/nbbuild/netbeans/platform/lib/nbexec: line 450:  3362 Aborted                 "/usr/lib/jvm/java-7-sun/bin/java" -Djdk.home="/usr/lib/jvm/java-7-sun" -classpath "/home/mito/nb/jet-main/nbbuild/netbeans/platform/lib/boot.jar:/home/mito/nb/jet-main/nbbuild/netbeans/platform/lib/org-openide-modules.jar:/home/mito/nb/jet-main/nbbuild/netbeans/platform/lib/org-openide-util.jar:/home/mito/nb/jet-main/nbbuild/netbeans/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-7-sun/lib/dt.jar:/usr/lib/jvm/java-7-sun/lib/tools.jar" -Dnetbeans.default_userdir_root="/home/mito/.netbeans" -Dnetbeans.running.environment=gnome -Dnetbeans.dirs="/home/mito/nb/jet-main/nbbuild/netbeans/nb:/home/mito/nb/jet-main/nbbuild/netbeans/ergonomics:/home/mito/nb/jet-main/nbbuild/netbeans/ide:/home/mito/nb/jet-main/nbbuild/netbeans/extide:/home/mito/nb/jet-main/nbbuild/netbeans/java:/home/mito/nb/jet-main/nbbuild/netbeans/apisupport:/home/mito/nb/jet-main/nbbuild/netbeans/webcommon:/home/mito/nb/jet-main/nbbuild/netbeans/websvccommon:/home/mito/nb/jet-main/nbbuild/netbeans/enterprise:/home/mito/nb/jet-main/nbbuild/netbeans/mobility:/home/mito/nb/jet-main/nbbuild/netbeans/profiler:/home/mito/nb/jet-main/nbbuild/netbeans/python:/home/mito/nb/jet-main/nbbuild/netbeans/php:/home/mito/nb/jet-main/nbbuild/netbeans/identity:/home/mito/nb/jet-main/nbbuild/netbeans/harness:/home/mito/nb/jet-main/nbbuild/netbeans/cnd:/home/mito/nb/jet-main/nbbuild/netbeans/dlight:/home/mito/nb/jet-main/nbbuild/netbeans/groovy:/home/mito/nb/jet-main/nbbuild/netbeans/extra:/home/mito/nb/jet-main/nbbuild/netbeans/javacard:/home/mito/nb/jet-main/nbbuild/netbeans/javafx:" -Dnetbeans.home="/home/mito/nb/jet-main/nbbuild/netbeans/platform" '-Dnetbeans.importclass=org.netbeans.upgrade.AutoUpgrade' '-Dnetbeans.accept_license_class=org.netbeans.license.AcceptLicense' '-XX:MaxPermSize=384m' '-Xmx768m' '-client' '-Xss2m' '-Xms32m' '-XX:PermSize=32m' '-Dnetbeans.logger.console=true' '-ea' '-Dapple.laf.useScreenMenuBar=true' '-Dapple.awt.graphics.UseQuartz=true' '-Dsun.java2d.noddraw=true' '-Dsun.java2d.dpiaware=true' '-Dsun.zip.disableMemoryMapping=true' '-Dplugin.manager.check.updates=false' '-Dnetbeans.extbrowser.manual_chrome_plugin_install=yes' '-Dnetbeans.full.hack=true' '-Xdebug' '-Xrunjdwp:transport=dt_socket,suspend=y,server=n,address=localhost:34030' -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/mito/nb/jet-main/nbbuild/testuserdir/var/log/heapdump.hprof" -splash:"/home/mito/nb/jet-main/nbbuild/testuserdir/var/cache/splash.png" org.netbeans.Main --cachedir "/home/mito/nb/jet-main/nbbuild/testuserdir/var/cache" --userdir "/home/mito/nb/jet-main/nbbuild/testuserdir" "--branding" "nb" 0<&0
/home/mito/nb/jet-main/nbbuild/templates/projectized.xml:402: The following error occurred while executing this line:
/home/mito/nb/jet-main/nbbuild/build.xml:925: The following error occurred while executing this line:
/home/mito/nb/jet-main/nbbuild/build.xml:1000: exec returned: 134
BUILD FAILED (total time: 15 minutes 35 seconds)
Comment 1 Martin Entlicher 2013-08-27 08:45:21 UTC
Reproduced.
NetBeans are run with the debug options after restart, but debugger has finished on NetBeans exit.
Debugger has no way to detect, that the application (NetBeans) is going to be run again.

IMHO the best fix for 7.4 is to remove debug options on restart.
In the future, we may add some interface, that would allow to notify debugger about the restart.
Comment 2 Martin Entlicher 2013-08-27 12:00:45 UTC
I do not consider this to be severe enough to make changes into the launcher just few days before code-freeze.
In the future we may want to introduce some mechanism that would allow the debugger to detect, that the application is restarting.

On UNIX systems this issue can be solved by applying the attached patch to
netbeans/platform/lib/nbexec.
Comment 3 Martin Entlicher 2013-08-27 12:01:33 UTC
Created attachment 139303 [details]
The patch