const int maxConnections = 1000; ServicePointManager.DefaultConnectionLimit = maxConnections; const int maxIdleTimeout = 5000; ServicePointManager.MaxServicePointIdleTime = maxIdleTimeout; ServicePointManager.SecurityProtocol = SecurityProtocolType.Ssl3; WebClient webClient = new WebClient(); Stream stream = webClient.OpenRead("https://www.googleapis.com/oauth2/v1/userinfo?access_token=[AccessToken]"); string b; using (StreamReader br = new StreamReader(stream)) { b = br.ReadToEnd(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)