This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Soft Skills: The software developer's life manual and have John Sonmez on-line!
See this thread for details.
Win a copy of Soft Skills: The software developer's life manual this week in the Jobs Discussion forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using JAMon

 
Hann-Yu Chang
Greenhorn
Posts: 9
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've been searching around online, have read through the JAMon User's Guide, have looked at the provided example, but can not get my administrative page to return results. (The JAMonAdmin.jsp page renders, but the results table is blank.)
According to the documentation, all that is required in the code is a MontitorFactory and calls to start and stop it:
import com.jamonapi.*;
...
Monitor mon=MonitorFactory.start("myFirstMonitor");
...Code Being Timed...
mon.stop();
I have done this yet my admin page does not display any results. I'm I missing something? Is this a configuration issue, user error, something else? Is it necessary to call mon.getReport()? When and where?
Thanks!
 
steve souza
Ranch Hand
Posts: 862
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are successfully making calls to jamon and have JAMonAdmin.jsp in youre war then you should be able to see the stats. I have seen classpath problems if your calling context jamon.jar is different than the jamon.jar being referenced by JAmonAdmin.jsp. If you put jamon.jar in web-inf\lib this shouldn't be a problem. If you put a monitor in JAMonAdmin.jsp you will definitely see data. i..e at the top of JAMonAdmin.jsp put
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic