c# - How to turn off persistent proxy connections -
this follow on this question on how turn of connection: keep-alive headers on httpwebrequest.
i have disabled connection: keep-alive headers web service call, when use proxy sends connect xxx.xxxxx.xx:443 http/1.1 proxy before call sent server.
with connect call bunch of headers sent:
system.net information: 0 : [5420] connectstream#33166512 - sending headers
{
proxy-authorization: basic xxxxxxxxxxxxxxx==
host: xxx.xxxxx.xx
proxy-connection: keep-alive
}.
i want rid of keep-alive , change close cannot find out how control header. how change or disable proxy-connection header?
edit:
googleing around figured have set webrequest.connection = "close"; or webrequest.connection = null;, results in argument exception.
appareantly not possible change proxy-connection header.
the result trying achieve (close tcp connection proxy before load-balancer between client , proxy kills after 2 minutes of inactivity) realized setting
servicepointmanager.maxservicepointidletime = 100000;
the servicepointmanager closes underlying connection after 100 seconds, before killed load-balancer , creates new 1 when necessary.
Comments
Post a Comment