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 161745 - Deplyment fails when profiling web application
Summary: Deplyment fails when profiling web application
Status: RESOLVED DUPLICATE of bug 161759
Alias: None
Product: profiler
Classification: Unclassified
Component: Base (show other bugs)
Version: 6.x
Hardware: All Windows XP
: P2 blocker (vote)
Assignee: issues@profiler
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2009-04-02 10:39 UTC by Jaroslav Pospisil
Modified: 2009-04-02 16:19 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE logfile (47.17 KB, text/plain)
2009-04-02 14:06 UTC, Jiri Sedlacek
Details
GlassFish log (9.98 KB, text/plain)
2009-04-02 14:08 UTC, Jiri Sedlacek
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jaroslav Pospisil 2009-04-02 10:39:44 UTC
Build 200904020200,JDK1.6.0_13,Win Vista

Start IDE with new userdir,create new ant web application on Glassfish (not matter if v2 or v3) and click on Profile in
context menu.Left everything default and click Run. Profiling starts and it seems everything is OK, but in the contrary
with this in Output window I can see,that BUILD FAILED.

profile-j2ee:
start-profiled-server-extraargs:
The Sun Java System Application Server could not start.
More information about the cause is in the Server log file.
Possible reasons include:
 - IDE timeout: refresh the server node to see if it's running now.
 - Port conflicts. (use netstat -a to detect possible port numbers already used by the operating system.) 
 - Incorrect server configuration (domain.xml to be corrected manually) 
 - Corrupted Deployed Applications preventing the server to start.(This can be seen in the server.log file. In this
case, domain.xml needs to be modified).
 - Invalid installation location.
C:\Users\jp154641\Documents\NetBeansProjects\WebApplication6\nbproject\profiler-build-impl.xml:19: The following error
occurred while executing this line:
C:\Users\jp154641\Documents\NetBeansProjects\WebApplication6\nbproject\profiler-build-impl.xml:30: Starting server in
profile mode failed.
BUILD FAILED (total time: 25 seconds)


I've user freshly installed IDE(All config),new userdir and freshly installed Glassfish server.
Comment 1 Jiri Sedlacek 2009-04-02 14:05:20 UTC
This is incomplete, next time please attach IDE & server logfile.
Reproduced using the same configuration & steps, will add the logfiles myself.
Comment 2 Jiri Sedlacek 2009-04-02 14:05:56 UTC
IDE Output:

profile-j2ee:
start-profiled-server-extraargs:
Server is ready waiting for profiler to attach...
Profiler attached, waiting for the server to start up...
C:\Users\JiS\Documents\NetBeansProjects\WebApplication1\nbproject\profiler-build-impl.xml:19: The following error
occurred while executing this line:
C:\Users\JiS\Documents\NetBeansProjects\WebApplication1\nbproject\profiler-build-impl.xml:30: Starting of server in
profile mode timed-out after 300 secs.
BUILD FAILED (total time: 5 minutes 9 seconds)
Comment 3 Jiri Sedlacek 2009-04-02 14:06:54 UTC
Created attachment 79279 [details]
IDE logfile
Comment 4 Jiri Sedlacek 2009-04-02 14:08:01 UTC
Created attachment 79280 [details]
GlassFish log
Comment 5 Jiri Sedlacek 2009-04-02 14:11:03 UTC
I can see several problems here:

 1/ No root methods are set, this means GlassFish startup is fully instrumented
 2/ Exceptions in server log: Could not load Logmanager, java.lang.RuntimeException: recursivecall
 3/ Exceptions in IDE log: java.net.URISyntaxException: Illegal character in path (from MiscUtils.getClassPathFromManifest)
Comment 6 Jiri Sedlacek 2009-04-02 14:13:59 UTC
The 1/ could be related to Issue 161759.
The 2/ is a known problem in GlassFish server.
The 3/ could be related to Issue 161751 or just introduced by fixing Issue 157978.
Comment 7 Tomas Hurka 2009-04-02 14:18:16 UTC
This one probably causing the problem. I am not sure, why 'space' is illegal character in path. I will investigate.

java.net.URISyntaxException: Illegal character in path at index 16: file:/C:/Program Files/glassfish-v2.1/lib/endorsed/webservices-extra-api.jar
	at java.net.URI$Parser.fail(URI.java:2809)
	at java.net.URI$Parser.checkChars(URI.java:2982)
	at java.net.URI$Parser.parseHierarchical(URI.java:3066)
	at java.net.URI$Parser.parse(URI.java:3014)
	at java.net.URI.<init>(URI.java:578)
	at java.net.URL.toURI(URL.java:918)
	at org.netbeans.lib.profiler.utils.MiscUtils.getClassPathFromManifest(MiscUtils.java:376)
	at org.netbeans.lib.profiler.utils.MiscUtils.getPathComponents(MiscUtils.java:349)
	at org.netbeans.lib.profiler.classfile.ClassRepository.initClassPaths(ClassRepository.java:410)
	at org.netbeans.lib.profiler.ProfilerClient.setVMProperties(ProfilerClient.java:1421)
	at org.netbeans.lib.profiler.ProfilerClient.connectToServer(ProfilerClient.java:1637)
	at org.netbeans.lib.profiler.ProfilerClient.establishConnectionWithServer(ProfilerClient.java:776)
	at org.netbeans.lib.profiler.TargetAppRunner.initiateSession(TargetAppRunner.java:344)
	at org.netbeans.modules.profiler.NetBeansProfiler$3.doInBackground(NetBeansProfiler.java:1090)
	at org.netbeans.lib.profiler.ui.SwingWorker$2.run(SwingWorker.java:113)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:573)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1005)

Comment 8 Jiri Sedlacek 2009-04-02 14:21:34 UTC
Some more findings: after the timeout the server process is still alive and being instrumented. After another 2~3
minutes a warning dialog about the 64K methods limit has been shown.

It looks like in fact everything is OK and just extremely slow, due to no root methods defined the server startup takes
more time than the serverplugin timeout limit - thus the BUILD FAILED message. Still a regression.
Comment 9 Tomas Hurka 2009-04-02 15:45:01 UTC
URISyntaxException is harmless and it does not cause this bug. I will file separate issue for it. So far it looks like it is dup of #161759.
Comment 10 Tomas Hurka 2009-04-02 16:19:22 UTC
 I cannot reproduce this bug with latest NetBeans build, which contains the fix for issue #161759. Closing as duplicate.

*** This issue has been marked as a duplicate of 161759 ***