Bug 161670 - Error when profile simple maven project
Error when profile simple maven project
Status: VERIFIED FIXED
Product: profiler
Classification: Unclassified
Component: Base
6.x
All All
: P2 (vote)
: 6.x
Assigned To: issues@profiler
issues@profiler
: SPACE_IN_PATH
: 164151 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-04-01 13:52 UTC by Jaroslav Pospisil
Modified: 2009-05-04 14:44 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jaroslav Pospisil 2009-04-01 13:52:25 UTC
Build 200904010000 (M3),Win Vista, JDK1.6.0_13

Create new Maven project from Quickstart archetype and invoke profile action. Left everything default. Error appears and
progress bar progresses indefinitely.

NetBeans: Executing 'cmd /c mvn.bat -Dexec.args= -XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=C:\Users\jp154641\Documents\NetBeansProjects\mavenproject6\nbproject\private\profiler 
-agentpath:C:/Program Files/NetBeans 6.7 M3/profiler3/lib/deployed/jdk16/windows/profilerinterface.dll=C:/Program
Files/NetBeans 6.7 M3/profiler3/lib,5140,10 -classpath %classpath com.mycompany.mavenproject6.App
-Dprofiler.action=profile -Dexec.executable=C:\Program Files\Java\jdk1.6.0_13\bin\java.exe -Dnetbeans.execution=true
process-classes org.codehaus.mojo:exec-maven-plugin:1.1:exec'
NetBeans:      JAVA_HOME =C:\Program Files\Java\jdk1.6.0_13
Scanning for projects...
------------------------------------------------------------------------
Building mavenproject6
   task-segment: [process-classes, org.codehaus.mojo:exec-maven-plugin:1.1:exec]
------------------------------------------------------------------------
[resources:resources]
Using default encoding to copy filtered resources.
[compiler:compile]
Compiling 1 source file to C:\Users\jp154641\Documents\NetBeansProjects\mavenproject6\target\classes
[exec:exec]
Error occurred during initialization of VM
Could not find agent library in absolute path: C:/Program
------------------------------------------------------------------------
[ERROR]BUILD ERROR
------------------------------------------------------------------------
Result of cmd.exe /X /C ""C:\Program Files\Java\jdk1.6.0_13\bin\java.exe" -XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=C:Usersjp154641DocumentsNetBeansProjectsmavenproject6nbprojectprivateprofiler  -agentpath:C:/Program
Files/NetBeans 6.7 M3/profiler3/lib/deployed/jdk16/windows/profilerinterface.dll=C:/Program Files/NetBeans 6.7
M3/profiler3/lib,5140,10 -classpath C:\Users\jp154641\Documents\NetBeansProjects\mavenproject6\target\classes
com.mycompany.mavenproject6.App" execution is: '1'.
------------------------------------------------------------------------
For more information, run Maven with the -e switch
------------------------------------------------------------------------
Total time: 4 seconds
Finished at: Wed Apr 01 14:47:26 CEST 2009
Final Memory: 6M/12M
------------------------------------------------------------------------

For Maven Web application project,there's no error message and Ant projects work OK.
Comment 1 J Bachorik 2009-04-02 11:40:18 UTC
This is caused by the space in path in the IDE installation. 

Fixed follows in:
http://hg.netbeans.org/profiler-main/rev/cd99c1a39d48
Comment 2 Quality Engineering 2009-04-08 07:47:44 UTC
Integrated into 'main-golden', will be available in build *200904080201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/cd99c1a39d48
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #161670 - profiling maven application fails if the IDE is installed in path with space
Comment 3 Jaroslav Pospisil 2009-04-08 10:22:41 UTC
The path is still processed badly - now it considers Files/Netbeans as task, but build still fails - reopening.

NetBeans: Executing 'cmd /c mvn.bat -Dexec.args= -XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=C:\Users\jp154641\Documents\NetBeansProjects\mavenproject13\nbproject\private\profiler 
"-agentpath:C:/Program Files/NetBeans Dev
200904080201/profiler3/lib/deployed/jdk16/windows/profilerinterface.dll=C:/Program Files/NetBeans Dev
200904080201/profiler3/lib,5140,10" -classpath %classpath com.mycompany.mavenproject13.App -Dprofiler.action=profile
-Dexec.executable=C:\Program Files\Java\jdk1.6.0_13\bin\java.exe -Dnetbeans.execution=true process-classes
org.codehaus.mojo:exec-maven-plugin:1.1:exec'
NetBeans:      JAVA_HOME =C:\Program Files\Java\jdk1.6.0_13
Scanning for projects...
------------------------------------------------------------------------
[ERROR]BUILD FAILURE
------------------------------------------------------------------------
Invalid task 'Files/NetBeans': you must specify a valid lifecycle phase, or a goal in the format plugin:goal or
pluginGroupId:pluginArtifactId:pluginVersion:goal
------------------------------------------------------------------------
For more information, run Maven with the -e switch
------------------------------------------------------------------------
Total time: < 1 second
Finished at: Wed Apr 08 11:17:07 CEST 2009
Final Memory: 1M/4M
------------------------------------------------------------------------
Comment 4 Quality Engineering 2009-04-08 19:59:55 UTC
Integrated into 'main-golden', will be available in build *200904081400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/cd99c1a39d48
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #161670 - profiling maven application fails if the IDE is installed in path with space
Comment 5 J Bachorik 2009-04-14 10:04:33 UTC
The root cause is the same as in #156366 - the maven can not handle executing a java application with arguments
containing space.
This is a real bummer as NetBeans gets installed to path with spaces by default on windows (...\Program Files\NetBeans
6.7\...) and all the profiler files are installed there as well - resulting in no profiler functionality at all.
Comment 6 J Bachorik 2009-04-14 14:11:26 UTC
Found the way to escape quotes being passed as exec.args to mojo:exec plugin. This seems to resolve the problem with
space in path.
Fixed in http://hg.netbeans.org/profiler-main/rev/2664e31191cd
Comment 7 Quality Engineering 2009-04-16 08:03:46 UTC
Integrated into 'main-golden', will be available in build *200904160201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/2664e31191cd
User: Jaroslav Bachorik <yardus@netbeans.org>
Log: #161670 - maven specific handling of space in path in exec.args property
Comment 8 ecastro 2009-04-30 17:30:17 UTC
*** Issue 164151 has been marked as a duplicate of this issue. ***
Comment 9 Jaroslav Pospisil 2009-05-04 14:44:07 UTC
v.


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo