we are developing a application that will find the application dependiecies in distributed environment. for that we are tracing the requests that are made to servlets and in turn which serlet calls which ejb. for that we are hacking into tomcat 5 and jboss's code, now we are not able to make out how to track which servlet called which ejb, as servlet call is just a method call, we can get the request parameters like servlet's name etc in jboss's any class.
can someone tell which what can be done regarding that.
-
how to track which servlet called which ejb (1 messages)
- Posted by: anant agarwal
- Posted on: April 17 2004 05:10 EDT
Threaded Messages (1)
- how to track which servlet called which ejb by Paul Strack on April 18 2004 17:16 EDT
-
how to track which servlet called which ejb[ Go to top ]
- Posted by: Paul Strack
- Posted on: April 18 2004 17:16 EDT
- in response to anant agarwal
How about this:
Use the Service Locator pattern to do you EJB lookup (a good idea in its own right), and pass an additional parameter: the calling class. You can then log caller + EJB being used. Of course, this means rewriting your servlet code.
If you want to do it without rewriting your servlet code, I have no idea how to accomplish this. It would probably involve some very ugly hacks of the JNDI service of Tomcat and JBoss, and you would risk breaking the server.