Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Test and Performance Tools Platform (TPTP) » Turning profiling on and off from within the application
Turning profiling on and off from within the application [message #41613] Mon, 21 November 2005 18:16 Go to next message
Carl Rosenberger is currently offline Carl RosenbergerFriend
Messages: 6
Registered: July 2009
Junior Member
Hi all,

thanks a lot for providing TPTP, we just found it, it
looks great!

Coming from JProbe, I am looking for API calls to turn
profiling on and off from within my running application.

My usecase:
I want to find out why a specific single call of a
method is slow. Filters won't work for me in this case.
I also want to time all underlying calls into our core
code, but only for this specific single call.

Thans in advance for any help!

Best,
Carl
Re: Turning profiling on and off from within the application [message #42806 is a reply to message #41613] Thu, 24 November 2005 18:24 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: Navid_Mehregani_nmehrega.ca.ibm.com

This is a multipart message in MIME format.
--=_alternative 00651B6E852570C3_=
Content-Type: text/plain; charset="US-ASCII"

Hi Carl,

You don't have to turn on/off profiling programmatically, you can do it
within the workbench, by either pausing/resuming monitoring or
detaching/reattaching to the agent. To do any of these, simply right
click on your agent. If you do have to do it programmatically, then
extract the org.eclipse.hyades.execution module from CVS and take a look
at Agent and AgentImpl in the
org.eclipse.hyades.internal.execution.local.control package. You can
either call startMontiroing() / stopMonitoring() from here or call
detach() / attach() depending on how you want to collect profiling data.

Navid Mehregani
IBM Canada
--=_alternative 00651B6E852570C3_=
Content-Type: text/html; charset="US-ASCII"


<br><font size=2 face="sans-serif">Hi Carl,</font>
<br>
<br><font size=2 face="sans-serif">You don't have to turn on/off profiling
programmatically, you can do it within the workbench, by either pausing/resuming
monitoring or detaching/reattaching to the agent. &nbsp;To do any of these,
simply right click on your agent. &nbsp;If you do have to do it programmatically,
then extract the org.eclipse.hyades.execution module from CVS and take
a look at Agent and AgentImpl in the org.eclipse.hyades.internal.execution.local.control
package. &nbsp;You can either call startMontiroing() / stopMonitoring()
from here or call detach() / attach() &nbsp;depending on how you want to
collect profiling data.</font>
<br>
<br><font size=2 face="sans-serif">Navid Mehregani</font>
<br><font size=2 face="sans-serif">IBM Canada</font>
--=_alternative 00651B6E852570C3_=--
Re: Turning profiling on and off from within the application [message #43220 is a reply to message #42806] Mon, 28 November 2005 17:53 Go to previous messageGo to next message
Andy Kaylor is currently offline Andy KaylorFriend
Messages: 23
Registered: July 2009
Junior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0011_01C5F401.9DDCB900
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Navid,

I think Carl wants to turn profiling on or off from within the =
application being profiled, not from within the Eclipse workbench, so I =
don't believe stopMonitoring() will help, will it?

And the UI approach doesn't allow fine enough control for what he is =
asking for.

I talked to Guru about this, and he doesn't think it's possible.

-Andy

------=_NextPart_000_0011_01C5F401.9DDCB900
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1523" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Navid,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I think Carl wants to turn profiling on =
or off from=20
within the application being profiled, not from within the Eclipse =
workbench, so=20
I don't believe stopMonitoring() will help, will it?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>And the UI approach doesn't allow fine =
enough=20
control for what he is asking for.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I talked to Guru about this, and he =
doesn't think=20
it's possible.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>-Andy</FONT></DIV>
<DIV><FONT face=3Dsans-serif size=3D2></FONT>&nbsp;</DIV></BODY></HTML>

------=_NextPart_000_0011_01C5F401.9DDCB900--
Re: Turning profiling on and off from within the application [message #43276 is a reply to message #43220] Mon, 28 November 2005 22:22 Go to previous message
Carl Rosenberger is currently offline Carl RosenbergerFriend
Messages: 6
Registered: July 2009
Junior Member
Andy Kaylor wrote:
> I think Carl wants to turn profiling on or off from
> within the application being profiled

Exactly.

I can give you an exact description of the usecase:

There is a test suite that runs a couple of dozen queries
against our database engine. I only want to profile the
time spent in our index optimizer and I want to see the
hotspots in there.

If I can't focus the profiler on running in the index
optimizer only, file access will dominate the results
and I won't be able to see anything useful.


> I talked to Guru about this, and he doesn't think it's
> possible.

You're kidding. :-)

You are collecting results about which methods are being
called. If you can't trap two simple static calls...

Profiler.start()
Profiler.stop()

....something about result collection must be going wrong. :-)


I am just sharing my thoughts that I need this feature for
a Profiler to be useful. I would love to help out with TPTP
myself but my schedule is just too packed.


Thanks in advance for considering to add the feature.


Best,
Carl
--
Carl Rosenberger
Chief Software Architect
db4objects Inc.
http://www.db4o.com
Previous Topic:Problems with the RAServer
Next Topic:EXCEPTION_ACCESS_VIOLATION
Goto Forum:
  


Current Time: Sat Dec 20 08:10:43 GMT 2014

Powered by FUDForum. Page generated in 0.01807 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software