Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Servlet Status

 
visu Nekk
Ranch Hand
Posts: 122
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

How to figure out the status of a servlet in Tomcat/JBoss; i.e. whether it is running or not? The scenario is such that the service method in the servlet runs in an infinite loop. i need to figure out the status.

Thanks in advance,
Visu
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by visu Nekk:
Hi,

How to figure out the status of a servlet in Tomcat/JBoss; i.e. whether it is running or not? The scenario is such that the service method in the servlet runs in an infinite loop. i need to figure out the status.

Thanks in advance,
Visu


I do not think there is any management console available in Tomcat which would give you servlet level information , but tomcat's manager gives you the ability to start / stop web application , no of active sessions.

Ideally you should have the service in a independent set of classes and then probably you can use MBeans to monitor the services.
The servlet should only delegate the calls.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Tomcat manager application has very detailed information about every servlet.
Open it up with http://localhost:8080/manager/html
Click on Server Status and then Complete Server Status.

You will see a list of every servlet running under Tomcat, complete with start times, etc.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic