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 64263 - Profiling of applets doesn't work
Summary: Profiling of applets doesn't work
Status: CLOSED FIXED
Alias: None
Product: profiler
Classification: Unclassified
Component: Base (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@profiler
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-13 16:34 UTC by ehucka
Modified: 2006-10-09 10:48 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
applet (3.24 KB, text/plain)
2005-09-13 16:36 UTC, ehucka
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ehucka 2005-09-13 16:34:32 UTC
Steps to reproduce:
1. open an attached applet in IDE
2. invoke Profile|Profile Other|Profile "Applet.java"
3. choose CPU profiling, whole app
4. start profiling

Result: profiling doesn't start and some error messages are thrown int log

Profiler.connectToStartedApp: **************************************************
Profiler.connectToStartedApp: profiling settings -------------------------------
name: Preset: Entire Application
profilingType =8
overrideGlobalSettings =false
workingDir =
jvmArgs:
portNo =5140
javaPlatform =<project>
threadsMonitoringEnabled =false
cpuProfilingType =0
instrScheme =3
threadCPUTimerOn =false
instrumentGetterSetterMethods =true
instrumentEmptyMethods =false
instrumentMethodInvoke =true
instrumentSpawnedThreads =false
nProfiledThreadsLimit =32
sortResultsByThreadCPUTime =false
samplingInterval =10
instrumentationRootMethods =[Source Code defined via methods: 1 methods:
  class: applet.Applet
    method: <init>  ()V
  , Source Code defined via methods: 1 methods:
  class: applet.Applet
    method: init  ()V
  , Source Code defined via methods: 1 methods:
  class: applet.Applet
    method: start  ()V
  , Source Code defined via methods: 1 methods:
  class: applet.Applet
    method: stop  ()V
  , Source Code defined via methods: 1 methods:
  class: applet.Applet
    method: destroy  ()V
  , Source Code defined via methods: 1 methods:
  class: java.awt.EventDispatchThread
    method: run  ()V
  ]
codeFragmentSelection =null
codeRegionCPUResBufSize =1000
runGCOnGetResultsInMemoryProfiling =true
allocTrackEvery =10
allocStackTraceLimit =0
selectedInstrFilter =Exclude Java Core Classes

Profiler.connectToStartedApp: session settings ---------------------------------
mainClass:
mainClassPath:
/space/Builds/dev/netbeans/ide6/modules/ext/swing-layout-0.7.jar:/mnt/data/Documents/Work/testspecs/profiler/data/projects/j2se/build/classes
mainArgs:
jvmArgs =-Djava.security.policy=applet.policy
workingDir =/space/Builds/dev/netbeans/bin
javaExecutable =/space/jdk/bin/java
javaVersionString =jdk15
portNo =5140
Profiler.connectToStartedApp: **************************************************
Instrumentation filter:
  Filter type: Exclusive
  Filter value: java/ javax/ sun/ sunw/ org/omg/CORBA org/omg/CosNaming/ COM/rsa/
*** Profiler warning (Tue Sep 13 17:29:53 CEST 2005): method start(()V) not
found in class applet.Applet
*** Profiler warning (Tue Sep 13 17:29:53 CEST 2005): method stop(()V) not found
in class applet.Applet
*** Profiler warning (Tue Sep 13 17:29:53 CEST 2005): method destroy(()V) not
found in class applet.Applet
Comment 1 ehucka 2005-09-13 16:36:24 UTC
Created attachment 24755 [details]
applet
Comment 2 ehucka 2005-09-13 16:43:51 UTC
Output window contains this messages:

j2se/nbproject/profiler-build-impl.xml:98: The following error occurred while
executing this line:
j2se/nbproject/profiler-build-impl.xml:44: Class
org.apache.tools.ant.types.Commandline$Argument doesn't support the "classname"
attribute.
Comment 3 iformanek 2005-09-14 11:04:54 UTC
Fixed in M9, the profiler-build-impl target for profiling applets was incorrect.
The correct target shoudl look like this:

    <target name="profile-applet" if="netbeans.home" depends="profile-
init,compile-single">
        <nbprofiledirect>
            <classpath>
                <path path="${run.classpath}"/>
            </classpath>
        </nbprofiledirect>
        <profile classname="sun.applet.AppletViewer">
            <customize>
                <arg value="${applet.url}"/>
            </customize>
        </profile>
    </target>
Comment 4 ehucka 2005-11-11 14:53:49 UTC
v