ranga - 2013-05-17

Environment: Windows 7
Java: 1.7.0_21
Tomcat: 7.0.33
Jensor: 2.2

I am trying to integrate jensor with tomcat to profile a webapp. I made
the following changes:

  1. In catalina.bat I added the following line after :doneSetArgs
    "set
    JAVA_OPTS=-javaagent:"%JENSOR_HOME%\lib\jensorjdk15-v22-win32.jar"=project=newUI=config.file="%JENSOR_HOME%\config\Jensor.properties"
    -Xms1024M -Xmx1536M %JAVA_OPTS%"

  2. In Jensor Analysis Workbench I created a project called newUI and
    open newUI to be the current project

  3. I also added com.mypackage in includelist.txt in config folder of
    jensor home

  4. I started tomcat and after the webapp is running I clicked on Mode >
    Start Session.

  5. In the jensor console the following message is shown:
    D:\work\installs\Jensor\bin>java -Xms256M -Xmx512M -cp
    .;"D:\work\installs\Jenso
    r\lib\jensorjdk15-v22-win32.jar";"D:\work\installs\Jensor\lib\jcommon-1.0.13.j
    ar";"D:\work\installs\Jensor\lib\jfreechart-1.0.10.jar";"D:\work\installs\Jenso
    r\lib\glazedlists-1.7.0_java14.jar" com.tcs.perc.jensor.UI.JensorProjectUI
    Finding Platform info ...
    Current platform is Windows 7
    JC-006: JENSOR_HOME : D:\work\installs\Jensor\ Project is not selected.
    Signal for Collection of Data sent

  6. I used the webapp for a while and then clicked on Mode > Collate Records

  7. I got a popup message saying "Output not related to this project"

  8. In the backend jensor console I got the following logs:
    Socket is connected : true
    String sent : colloc,Administrator,perf123
    Local machine no need for transfer.
    PROJECT HOME : D:\work\installs\Jensor\projects\newUI
    Reader/Writer for file D:\work\installs\Jensor\output\JensorProfile.txt
    closed.
    The key value is - 1368537615927
    Reader/Writer for file D:\work\installs\Jensor\output\memusage.csv closed.
    JensorProfile.txt was not written to....
    Memusage.csv was not written to....

What to do to make jensor work with tomcat so that I can profile my webapp?

Thank you,
Ranga