From d57c88e76b5ebf1ee477286345cdda5cbcab83ee Mon Sep 17 00:00:00 2001 From: Savorboard Date: Fri, 3 Aug 2018 15:46:50 +0800 Subject: [PATCH 1/5] upgrade nuget packages --- samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj | 2 +- .../Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj | 7 +------ samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj | 2 +- src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj | 2 +- src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj | 2 +- .../DotNetCore.CAP.PostgreSql.csproj | 2 +- src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj | 2 +- src/DotNetCore.CAP/DotNetCore.CAP.csproj | 2 +- .../DotNetCore.CAP.MongoDB.Test.csproj | 6 +++--- .../DotNetCore.CAP.MySql.Test.csproj | 4 ++-- .../DotNetCore.CAP.PostgreSql.Test.csproj | 2 +- .../DotNetCore.CAP.SqlServer.Test.csproj | 2 +- test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj | 2 +- 13 files changed, 16 insertions(+), 21 deletions(-) diff --git a/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj b/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj index 27a8c6e..191ad86 100644 --- a/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj +++ b/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj @@ -9,7 +9,7 @@ - + diff --git a/samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj b/samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj index fdaa849..b693e95 100644 --- a/samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj +++ b/samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj @@ -1,13 +1,8 @@ - + netcoreapp2.1 - - - - - diff --git a/samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj b/samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj index 5faf15f..4ebfbda 100644 --- a/samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj +++ b/samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj @@ -6,7 +6,7 @@ - + diff --git a/src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj b/src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj index 8c8d5e7..13388ea 100644 --- a/src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj +++ b/src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj @@ -13,7 +13,7 @@ - + diff --git a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj index 14734ad..002ebeb 100644 --- a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj +++ b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj @@ -15,7 +15,7 @@ - + diff --git a/src/DotNetCore.CAP.PostgreSql/DotNetCore.CAP.PostgreSql.csproj b/src/DotNetCore.CAP.PostgreSql/DotNetCore.CAP.PostgreSql.csproj index 0e3698f..fc76e6c 100644 --- a/src/DotNetCore.CAP.PostgreSql/DotNetCore.CAP.PostgreSql.csproj +++ b/src/DotNetCore.CAP.PostgreSql/DotNetCore.CAP.PostgreSql.csproj @@ -15,7 +15,7 @@ - + diff --git a/src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj b/src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj index deccfb7..f35dd38 100644 --- a/src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj +++ b/src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj @@ -12,7 +12,7 @@ - + diff --git a/src/DotNetCore.CAP/DotNetCore.CAP.csproj b/src/DotNetCore.CAP/DotNetCore.CAP.csproj index cc1a94d..2f571df 100644 --- a/src/DotNetCore.CAP/DotNetCore.CAP.csproj +++ b/src/DotNetCore.CAP/DotNetCore.CAP.csproj @@ -31,7 +31,7 @@ - + diff --git a/test/DotNetCore.CAP.MongoDB.Test/DotNetCore.CAP.MongoDB.Test.csproj b/test/DotNetCore.CAP.MongoDB.Test/DotNetCore.CAP.MongoDB.Test.csproj index 9fb481e..b04ca28 100644 --- a/test/DotNetCore.CAP.MongoDB.Test/DotNetCore.CAP.MongoDB.Test.csproj +++ b/test/DotNetCore.CAP.MongoDB.Test/DotNetCore.CAP.MongoDB.Test.csproj @@ -6,10 +6,10 @@ - - + + - + diff --git a/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj b/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj index 8678e45..99f246c 100644 --- a/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj +++ b/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj @@ -13,12 +13,12 @@ - + - + diff --git a/test/DotNetCore.CAP.PostgreSql.Test/DotNetCore.CAP.PostgreSql.Test.csproj b/test/DotNetCore.CAP.PostgreSql.Test/DotNetCore.CAP.PostgreSql.Test.csproj index 335f851..3177749 100644 --- a/test/DotNetCore.CAP.PostgreSql.Test/DotNetCore.CAP.PostgreSql.Test.csproj +++ b/test/DotNetCore.CAP.PostgreSql.Test/DotNetCore.CAP.PostgreSql.Test.csproj @@ -8,7 +8,7 @@ - + diff --git a/test/DotNetCore.CAP.SqlServer.Test/DotNetCore.CAP.SqlServer.Test.csproj b/test/DotNetCore.CAP.SqlServer.Test/DotNetCore.CAP.SqlServer.Test.csproj index 9375d31..7df0282 100644 --- a/test/DotNetCore.CAP.SqlServer.Test/DotNetCore.CAP.SqlServer.Test.csproj +++ b/test/DotNetCore.CAP.SqlServer.Test/DotNetCore.CAP.SqlServer.Test.csproj @@ -18,7 +18,7 @@ - + diff --git a/test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj b/test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj index 7216569..bdab81c 100644 --- a/test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj +++ b/test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj @@ -12,7 +12,7 @@ - + From c1bbb9fa742663af633ac287bcbd51351146255f Mon Sep 17 00:00:00 2001 From: Savorboard Date: Fri, 3 Aug 2018 15:54:57 +0800 Subject: [PATCH 2/5] remove unused code. --- src/DotNetCore.CAP/Abstractions/CapPublisherBase.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/DotNetCore.CAP/Abstractions/CapPublisherBase.cs b/src/DotNetCore.CAP/Abstractions/CapPublisherBase.cs index d585406..7589aad 100644 --- a/src/DotNetCore.CAP/Abstractions/CapPublisherBase.cs +++ b/src/DotNetCore.CAP/Abstractions/CapPublisherBase.cs @@ -214,11 +214,10 @@ namespace DotNetCore.CAP.Abstractions try { - Console.WriteLine("================22222222222222====================="); operationId = s_diagnosticListener.WritePublishMessageStoreBefore(message); var id = Execute(DbConnection, DbTransaction, message); - Console.WriteLine("================777777777777777777777====================="); + ClosedCap(); if (id > 0) From d20605d8d54c9ebcccf3926528b4438cc4bc5380 Mon Sep 17 00:00:00 2001 From: Savorboard Date: Fri, 3 Aug 2018 16:40:00 +0800 Subject: [PATCH 3/5] switch mysql driver to mysql.data --- samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj | 1 - src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj | 2 +- test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj | 1 - 3 files changed, 1 insertion(+), 3 deletions(-) diff --git a/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj b/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj index 191ad86..e64e18b 100644 --- a/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj +++ b/samples/Sample.Kafka.MySql/Sample.Kafka.MySql.csproj @@ -9,7 +9,6 @@ - diff --git a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj index 002ebeb..2d71cf8 100644 --- a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj +++ b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj @@ -15,7 +15,7 @@ - + diff --git a/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj b/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj index 99f246c..1b98a58 100644 --- a/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj +++ b/test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj @@ -13,7 +13,6 @@ - From 6abf92c2b80f241a5827e294f3e4665e763f3863 Mon Sep 17 00:00:00 2001 From: Savorboard Date: Fri, 3 Aug 2018 16:45:06 +0800 Subject: [PATCH 4/5] add SslMode=none to mysql connection string --- appveyor.yml | 2 +- test/DotNetCore.CAP.MySql.Test/ConnectionUtil.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index e80f7ce..8a571f4 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -4,7 +4,7 @@ environment: BUILDING_ON_PLATFORM: win BuildEnvironment: appveyor Cap_SqlServer_ConnectionStringTemplate: Server=(local)\SQL2014;Database={0};User ID=sa;Password=Password12! - Cap_MySql_ConnectionStringTemplate: Server=localhost;Database={0};Uid=root;Pwd=Password12!;Allow User Variables=True + Cap_MySql_ConnectionStringTemplate: Server=localhost;Database={0};Uid=root;Pwd=Password12!;Allow User Variables=True;SslMode=none Cap_PostgreSql_ConnectionStringTemplate: Server=localhost;Database={0};UserId=postgres;Password=Password12! services: - mssql2014 diff --git a/test/DotNetCore.CAP.MySql.Test/ConnectionUtil.cs b/test/DotNetCore.CAP.MySql.Test/ConnectionUtil.cs index 9d79882..fec2706 100644 --- a/test/DotNetCore.CAP.MySql.Test/ConnectionUtil.cs +++ b/test/DotNetCore.CAP.MySql.Test/ConnectionUtil.cs @@ -12,7 +12,7 @@ namespace DotNetCore.CAP.MySql.Test private const string DefaultDatabaseName = @"DotNetCore.CAP.MySql.Test"; private const string DefaultConnectionStringTemplate = - @"Server=localhost;Database={0};Uid=root;Pwd=123123;Allow User Variables=True;"; + @"Server=localhost;Database={0};Uid=root;Pwd=123123;Allow User Variables=True;SslMode=none;"; public static string GetDatabaseName() { From a51bd4ebc77a537944534b209de02a6d5dae11cd Mon Sep 17 00:00:00 2001 From: Savorboard Date: Sat, 4 Aug 2018 10:57:12 +0800 Subject: [PATCH 5/5] reduction driven to mysqlconnector --- src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj index 2d71cf8..002ebeb 100644 --- a/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj +++ b/src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj @@ -15,7 +15,7 @@ - +