hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Olaf Sebelin ...@bos-bremen.de>
Subject Original method parameters not copied in HttpMethodDirector.executeConnect()
Date Wed, 21 Jun 2006 08:18:03 GMT
Hi,


in HttpMethodDirector.executeConnect() the parameters of the
hostConfiguration are applied as default parameters to the new
ConnnectMethod:

 this.connectMethod = new ConnectMethod();
 this.connectMethod.getParams().setDefaults(this.hostConfiguration.getParams());

This way, the parameters of the underlying original Method are not
copied to the ConnectMethod. 

So, if I set a method specific CredentialsProvider, like 

  GetMethod get = new GetMethod("https://somewhere.org"); //HTTPS!
  get.getParams().setParameter(CredentialsProvider.PROVIDER, this);

it won't get applied to the ConnnectMethods parameters.

Is this desired behaviour, thus it is not correct to set the
CredentialsProvider in a method-specific way?

Or should  HttpMethodDirector.executeConnect() be changed to something
like this (and I should file a bug report :)

 private boolean executeConnect(HttpMethod method) throws IOException, HttpException
 {
   this.connectMethod = new ConnectMethod();
   this.connectMethod.setParams(method.getParams());
   this.connectMethod.getParams().setDefaults(this.hostConfiguration.getParams());
  //...
 }


Thanks for your help && Kind regards
Olaf Sebelin

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org


Mime
View raw message