Connect HttpConnectionSettings with WebMachine
Problem
Connection settings configured with the job are not being passed into the HTTP networking code. This prevents client side certs and other job settings from working.
Proposal
Location of settings:
-
Project
class -- Has TLS certificates and also connection settings -
GlobalSettigns
class -- Use these if they are not provided by Project
Tasks:
-
Create a Factory for HttpConnectionSettings that can set defaults that can be changed - We have defaults being set in the code atm. This can be moved into the factory.
-
Pass HttpConnectionSettings to HttpMessageService.Send. - Set DnsService and TlsService in HttpMessageService.Send (these come in through dependency injection)
- Set TlsService.ServerCipherSuites and TlsService.ClientCipherSuites
- Update the code so HttpConnectionSettings is no longer passed via constructors to HttpConnectionPoolService, HttpConnectionPool, and Http11Connection. It should be passed through Send method.
- Add the following to HttpConnectionSettings:
public int[] ServerCipherSuites { get; set; } public int[] ClientCipherSuites { get; set; }
-
Update WebRunnerMachine.SendRequest to pass HttpConnectionSettings - Do not re-create the settings object on each call to sendrequest (for performance).
-
Verify tests are working -
Add new tests if needed
Edited by Herber Madrigal