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

Tracking Requests and Responses

 
Janaki Raju
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I hope I am posting this question in the right forum.

I have a web application running on tomcat. I want to take a look at the HTTP requests and responses (both header and data). How do I do this ? Is there any add-ons that I can add to the browser that will enable me to do this ? Or is there a way that I can tell tomcat to dump the requests and responses ? I am interested in the data being sent and received, not just the headers.

Any help is appreciated.

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65225
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Would servlet filters fit the bill to do this programmatically?

Or, Firefox plugins such as TamperData and Live HTTP Headers might be helpful for hand inspections.
[ June 24, 2008: Message edited by: Bear Bibeault ]
 
Janaki Raju
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Thanks so much for responding back. TamperData and LiveHTTPHeaders seem to display only the headers, not the data portion.

What I need is:

If I use PostMethod in my java program to post a request, I want to see this request that I am sending and also the response that I am getting back (both header and data). Is there any way to add a sniffer like tool and bind it to a port to do this job ?

I am unfamiliar with how servlet filters work . Do you think they will do the above job that I need ?

Thanks much.
 
Abhinav Srivastava
Ranch Hand
Posts: 354
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
tcpmon
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Uncomment the requestDumperValve in tomcat/conf/server.xml.
There is a comment just above it that describes what it will send to the logs.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic