diff --git a/Program.cs b/Program.cs index 25dfe77..cbbd3d5 100644 --- a/Program.cs +++ b/Program.cs @@ -11,12 +11,13 @@ using Npgsql; internal class Plat_integ { - static string PG_CONN_STRING_PROD = "Server = smart-energia-dev-pgsql.cykff7tj7mik.us-east-1.rds.amazonaws.com; Port = 5432; Database = smartenergiaprod; User Id = postgres; Password = VfHml#Z78!%kvvNM; Timeout = 300;CommandTimeout = 300"; - static readonly HttpClient client = new HttpClient(new HttpClientHandler { + static string PG_CONN_STRING_PROD = "Server = smart-energia-dev-pgsql.cykff7tj7mik.us-east-1.rds.amazonaws.com; Port = 5432; Database = smartenergiaprod; Username = postgres; Password = VfHml#Z78!%kvvNM; Timeout = 60; CommandTimeout = 60; ApplicationName = new_med_5_min; Connection Lifetime = 120; Minimum Pool Size = 2; Maximum Pool Size = 2;"; + static readonly HttpClient client = new HttpClient(new HttpClientHandler + { ClientCertificateOptions = ClientCertificateOption.Automatic, - Proxy = new WebProxy("127.0.0.1", 8888), - UseProxy = true, - ServerCertificateCustomValidationCallback = (HttpRequestMessage req, X509Certificate2? cert, X509Chain? chain, SslPolicyErrors errors) => true + //Proxy = new WebProxy("127.0.0.1", 8888), + //UseProxy = true, + //ServerCertificateCustomValidationCallback = (HttpRequestMessage req, X509Certificate2? cert, X509Chain? chain, SslPolicyErrors errors) => true }); static async Task Main()