Turning on Logging in HttpClient

I faced same problem today. And I found out a solution for this problem. It’s pretty simple.
Just add jcl-over-slf4j dependency to forward JCL logging (Apache Commons Logging) to slf4j.


After that you can config log file as Log4j Examples.
If you use logback you can put the following to your logback.xml

<logger name="org.apache.http" level="DEBUG"/>

Or if you use log4j


Leave a Comment