hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Smith <ryan.justin.sm...@gmail.com>
Subject Re: How to use logging abilities of HttpClient?
Date Tue, 10 Apr 2012 19:37:39 GMT
I guess I should include the code as part of the email , its only a few
lines.

        ClassLoader cl = ClassLoader.getSystemClassLoader();
        URL[] urls = ((URLClassLoader)cl).getURLs();
        for(URL url: urls){
            System.out.println(url.getFile());
        }

On Tue, Apr 10, 2012 at 3:36 PM, Ryan Smith <ryan.justin.smith@gmail.com>wrote:

> Maybe try running this code:
>
> http://pastebin.com/brCccS3M
>
> It will list all your available classpaths.
>
> Then put your 'log4j.properties' file in one of the listed directories on
> the classpath.
>
> hth, -Ryan
>
>
>
>
> On Tue, Apr 10, 2012 at 3:28 PM, tommmmmm <tommmmmm@gmail.com> wrote:
>
>> I thought that if there is:
>> getClass().getClassLoader().getResource("log4j.properties")
>> there also woulb be:
>> getClass().getClassLoader().setResource("log4j.properties")
>>
>> I was so wrong.
>>
>> How do I point the httpClient to my properties file? I thought that's why
>> the line log4j.logger.org.apache.http=DEBUG was for in the first place...
>>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message