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 250936 - Automatic calibration does not work for Maven project
Summary: Automatic calibration does not work for Maven project
Status: RESOLVED FIXED
Alias: None
Product: profiler
Classification: Unclassified
Component: Ide (show other bugs)
Version: 7.0
Hardware: All All
: P2 normal (vote)
Assignee: Tomas Hurka
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-03-05 16:10 UTC by _ gtzabari
Modified: 2015-06-26 04:51 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2015-03-05 16:10:50 UTC
Product Version: NetBeans IDE Dev (Build 201503050001)
Java: 1.8.0_31; Java HotSpot(TM) 64-Bit Server VM 25.31-b07
Runtime: Java(TM) SE Runtime Environment 1.8.0_31-b13
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
User directory: C:\dev\Netbeans\user\dev
Cache directory: C:\dev\Netbeans\cache\dev

The Profile -> Advanced Options item is missing for some reason. This means that it is impossible to calibrate profiling for the JDK, which means it is impossible to calibrate.

Furthermore, when a user runs against a JDK that not calibrated, why not provide a "Calibrate Now" button inside the warning dialog instead of making the user go fishing for where this functionality is found?
Comment 1 Jiri Sedlacek 2015-03-05 16:20:33 UTC
The profiler is being reimplemented for the next NB release. Calibration is now available in Tools | Options | Java | Profiler - Manage calibration data.

For Profile action the JDK is calibrated automatically when needed. For Attach actions the calibration cannot be performed automatically as the profiled application is already running in its JVM which would bias the calibration data.
Comment 2 _ gtzabari 2015-03-05 20:17:44 UTC
Jiri,

Reopening because I still have some outstanding issues:

1. I hit ALT+F2 in dev build 201503050001 then click "Profile" and I get a warning dialog that reads: "Calibration data missing.\n\nProfiling cannot be started on this JDK. Please perform profiler calibration first and start profiling again." The dialog contains two buttons: "Show Details" and "OK". Didn't you say that Netbeans was supposed to run calibration automatically? Or hasn't this been implemented yet?

2. If I click Show Details, the warning dialog tells me to run "Manage Calibration Data" but doesn't tell me where to find it. I tried searching using CTRL+I but the documentation is outdated (still pointing to the old location). I suggest updating the "Show Details" message to explain exactly where to find "Manage Calibration Data". Or even better, take the user directly to this dialog (open it on his/her behalf).
Comment 3 Jiri Sedlacek 2015-03-05 20:38:15 UTC
You're right with 2., I've missed the point. The dialog should be improved - filed Bug 250945.

Trying to reproduce 1., so far works fine on my side. Which project type do you profile? Does profiling work correctly after you invoke the calibration manually?
Comment 4 _ gtzabari 2015-03-05 20:50:50 UTC
Yes, profiling works after I calibrate manually.

The project type is Maven -> Java Application.
Comment 5 Jiri Sedlacek 2015-03-05 21:01:13 UTC
That's the key information - the calibration doesn't execute automatically when starting a Maven/Java Application. Works fine for other project types.

The workaround until fixed is to execute the calibration manually using Tools | Options | Java | Profiler | Manage calibration data.

Thanks for the bugreport!
Comment 6 _ gtzabari 2015-03-06 00:54:02 UTC
Excellent. Glad I could help! :)
Comment 7 Tomas Hurka 2015-06-17 07:40:28 UTC
Fixed in profiler-main

changeset:   288340:71de40c6c9ce
user:        Tomas Hurka <thurka@netbeans.org>
date:        Wed Jun 17 09:39:35 2015 +0200
summary:     bugfix #250936, enable automatic calibration for Maven
Comment 8 Quality Engineering 2015-06-26 04:51:35 UTC
Integrated into 'main-silver', will be available in build *201506260309* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/71de40c6c9ce
User: Tomas Hurka <thurka@netbeans.org>
Log: bugfix #250936, enable automatic calibration for Maven