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 163165 - glassfish v3 debugger port issues
Summary: glassfish v3 debugger port issues
Status: RESOLVED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: GlassFish (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: Vince Kraemer
URL: http://blogs.sun.com/vkraemer/entry/d...
Keywords:
Depends on:
Blocks:
 
Reported: 2009-04-20 23:14 UTC by pbelbin
Modified: 2009-05-03 21:27 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pbelbin 2009-04-20 23:14:51 UTC
when I try and use the debugger with glassfish v3, it's not straight forward.

the web admin gui allows one to set what the port number for debugging is, but, it seems that this is entirely ignored.

the only port I've been able to successfully use is the one that's displayed during the felix startup.

one of the issues with this is that the port seems to change from one startup to the next, which means you have to 
update the port number every time (it seems) felix is restarted.

it should be possible to 

a) make the web admin pages and the actual port number match up
b) set a fixed port number for debugging so that the same port will be usable across restarts of glassfish v3
Comment 1 Martin Entlicher 2009-04-21 07:18:50 UTC
It's an issue of web module how it starts the server.
Comment 2 Vince Kraemer 2009-04-21 16:05:53 UTC
The user is able to debug... so I have trouble with the notion that this is a defect.

The current behavior is optimized for the 'Debug' and 'Debug Main Project' actions... which is the more widely used method.

The method currently used also allows multiple debug sessions on a single computer at the same time.

I will add a new Option on the Java page of the Server properties that will allow this kind of behavior.  It should be
available in the build some time next week.
Comment 3 pbelbin 2009-04-21 22:18:43 UTC
well, defect or enhancement, I'll let you decide, however:

I can understand that you guys are looking at it from the standpoint of wanting people to right click on the project, 
and use 'debug', and you're somehow figuring out what the correct port is.

that mode of use may be just fine for single web-app on a server with not much else going on.

however, I'm dealing with multiple projects, often having layered calls between them, where I need to interact with 
one project's web pages in order to cause a call to happen into another project that I'm actually intent on 
debugging.  After all, once you go into debugging, aren't you really debugging 'everything' that's running on the app 
server, and not just the one project?

it is for me, a much simpler paradigm just to say 'debug all the code on the server.  lets connect to the server and 
debug the code' regardless of which project the code is in.  hence, I prefer to deploy all the code, and 'connect' to 
the debugger enabled glassfish instance, and not have to 'start' a particular project in debug mode.

the other thing here is that most of my code does not really have a UI.  It may be accessed entirely / purely via web 
service calls either from other layers of my code, or, from somewhere else entirely.

the gui I need to use may not even be a web browser.  this reality further reinforces the notion that I don't want 
to 'start' a particular project.

remember also that this is an issue that I'm seeing only with glassfish V3.  with glassfish V2, it behaves very 
nicely, and I can always connect to the server using a static port of 9009.  not some random port somewhere up in the 
stratosphere, and, which changes between restarts of glassfish.

that's why I consider this to be a bug, and not an enhancement.

either way, I will be very appreciative of having a solution that supports my mode of use of netbeans.

all the best!
peter.
Comment 4 Vince Kraemer 2009-04-22 01:16:18 UTC
Thanks for the clarifications.
Comment 5 Quality Engineering 2009-04-25 07:30:53 UTC
Integrated into 'main-golden', will be available in build *200904250201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/d9f9c3477abc
User: Vince Kraemer <vkraemer@netbeans.org>
Log: #163165: allow user to set and see the debug port... very useful for 'Start in Debug Mode'
Comment 6 Vince Kraemer 2009-04-25 19:16:38 UTC
blog with description coming soon
Comment 7 Vince Kraemer 2009-04-29 19:25:36 UTC
Still haven't had time for the blog post.  Here is a screenshot...
http://blogs.sun.com/vkraemer/resource/debug-field.png