tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: org.apache.catalina.filters.RequestDumperFilter does not log HTTP body: Why not?
Date Fri, 07 Feb 2014 20:01:39 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Blume,

On 2/7/14, 8:16 AM, Blume Wolfgang wrote:
> I noticed that org.apache.catalina.filters.RequestDumperFilter
> does not log HTTP body. Is there any reason for that?

If the RequestDumperFilter were to log the request body, then the
request body would be consumed and the servlet couldn't read it.
Forms, etc. wouldn't work.

Yes, it's possible to buffer everything and re-feed it to the
downstream code, but that's resource-intensive and would be very
surprising to anyone who expects to process data in a streaming fashion.

It's trivial to write a Filter that will just dump the request body to
a log. Feel free to write one yourself.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBCAAGBQJS9TujAAoJEBzwKT+lPKRYpTQP/ihP7j3emqxGhrT+mGI8IshT
X9463s5ZrtIGiwKX6Gjpjrdu1slSUXZ7UPvgojr7GfL9oMhYj+uVxVVXNQg3Y+xJ
Eni5SZkwU8rdmgfOZ42aMQzyGEa8g0mIjOYKuMjiflNjrwb75z8igf37RlPjh89/
EgCsVHC5CCulH7PVkWUYpNeBZda7sve5ZcOSSPKDvD2XSobA7nopx8DYxturVpGU
RnqTolyWkVsMfKwi3zlGie0lx6ObswKM7CbKN6mGWFat04APxgMVn1+VooFcrb46
LnVZE5RyQbWw5gW7tk7PB5ejC7452j1t7d++dM0B4cr6ulPCyCCPY7YZL0OtEI5v
WDHDXnMb4I0Z0mLKR1DqH/Ghv4IBe58xr2NuZwmky8xmIc2+AwRm50nlrgdEaf9H
YfajjBFDaXIhVrs0DKwENhV35GD7e1UawiXPcd6pSRUik6Vxmh8bzN9oaBP6/QYn
wVyIop4GPZ17U4nABnFiS3mxHRwGi+ephz0sRz1BRLFMH58aPhHQzzj1xnBIsT43
lInzAJJn8kdL1BZuDMljICoPn4uP4XNmKTM0CemVFyY4TXZNN0nuHq5zDjF4rmPL
7nme8RWWSzikxMqWBrySX8mMlgwrznVf579lpMx0M+beMVYzfrgJnkUL0HbU/zRb
EvjRayeD0pvKDK8/qyGl
=SOmo
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message