Can you make an update from svn and check again? A patch was commited recently.
Alin Vasile În data de 11.10.2011 00:35, "Craig Gambino" <[email protected]> a scris: > > This code doesn't seem to work with the latest on trunk. I looked at the > latest code on trunk, and found the following on line 117 of > PoolingClientConnectionManager: > > this.dnsResolver = new SystemDefaultDnsResolver(); > > Seems like the dnsResolver passed into the constructor is just ignored. > > > On Mon, Oct 10, 2011 at 1:05 PM, Oleg Kalnichevski <[email protected]> wrote: > > > On Mon, 2011-10-10 at 22:56 +0300, Vasile Alin wrote: > > > > > > > > On Mon, Oct 10, 2011 at 2:13 PM, Craig Gambino <[email protected]> > > wrote: > > > >> If I were to write my own DNS resolver, what is the best way to > > utilize it? > > > >> I see that there is a chain of injection that I can do if I override > > the > > > >> DefaultClientConnectionOperator, but I wasn't sure if there was a > > cleaner / > > > >> easier way. > > > >> > > > > > > A code snippet: > > > > > > DnsResolver myResolver = new MyDnsResolver(); > > > > > > DefaultHttpClient httpclient = new DefaultHttpClient(new > > > PoolingClientConnectionManager( > > > SchemeRegistryFactory.createDefault(), > > myResolver)); > > > HttpGet httpget = new HttpGet("http://www.google.com/"); > > > HttpResponse response = httpclient.execute(httpget); > > > > > > > > > One important remark: this works with SVN trunk (4.2) only. > > > > Oleg > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [email protected] > > For additional commands, e-mail: [email protected] > > > >
