From 5fe7e5b226aecb358c4a2ff7647bc96005e654a0 Mon Sep 17 00:00:00 2001 From: Savorboard Date: Sat, 18 Aug 2018 09:58:58 +0800 Subject: [PATCH] Rename the file to conform to the specification --- src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs | 4 ++-- .../{CapPublisher.cs => ICapPublisher.MySql.cs} | 6 +++--- .../{MySqlStorage.cs => IStorage.MySql.cs} | 0 ...ySqlStorageConnection.cs => IStorageConnection.MySql.cs} | 0 ...qlStorageTransaction.cs => IStorageTransaction.MySql.cs} | 0 5 files changed, 5 insertions(+), 5 deletions(-) rename src/DotNetCore.CAP.MySql/{CapPublisher.cs => ICapPublisher.MySql.cs} (91%) rename src/DotNetCore.CAP.MySql/{MySqlStorage.cs => IStorage.MySql.cs} (100%) rename src/DotNetCore.CAP.MySql/{MySqlStorageConnection.cs => IStorageConnection.MySql.cs} (100%) rename src/DotNetCore.CAP.MySql/{MySqlStorageTransaction.cs => IStorageTransaction.MySql.cs} (100%) diff --git a/src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs b/src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs index 7ba01c5..9319ca1 100644 --- a/src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs +++ b/src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs @@ -25,8 +25,8 @@ namespace DotNetCore.CAP services.AddSingleton(); services.AddSingleton(); - services.AddScoped(); - services.AddScoped(); + services.AddScoped(); + services.AddScoped(); services.AddTransient(); services.AddTransient(); diff --git a/src/DotNetCore.CAP.MySql/CapPublisher.cs b/src/DotNetCore.CAP.MySql/ICapPublisher.MySql.cs similarity index 91% rename from src/DotNetCore.CAP.MySql/CapPublisher.cs rename to src/DotNetCore.CAP.MySql/ICapPublisher.MySql.cs index 8ce9b8d..fe83676 100644 --- a/src/DotNetCore.CAP.MySql/CapPublisher.cs +++ b/src/DotNetCore.CAP.MySql/ICapPublisher.MySql.cs @@ -14,7 +14,7 @@ using MySql.Data.MySqlClient; namespace DotNetCore.CAP.MySql { - public class CapPublisher : CapPublisherBase, ICallbackPublisher, IDisposable + public class MySqlPublisher : CapPublisherBase, ICallbackPublisher, IDisposable { private readonly DbContext _dbContext; private readonly MySqlOptions _options; @@ -22,7 +22,7 @@ namespace DotNetCore.CAP.MySql private MySqlConnection _connection; - public CapPublisher(IServiceProvider provider, MySqlOptions options) : base(provider) + public MySqlPublisher(IServiceProvider provider, MySqlOptions options) : base(provider) { _options = options; @@ -49,7 +49,7 @@ namespace DotNetCore.CAP.MySql dbTrans = dbContextTrans.GetDbTransaction(); } var conn = dbTrans?.Connection; - return conn.ExecuteScalarAsync(PrepareSql(), message, dbTrans); + return conn.ExecuteAsync(PrepareSql(), message, dbTrans); } protected override object GetDbTransaction() diff --git a/src/DotNetCore.CAP.MySql/MySqlStorage.cs b/src/DotNetCore.CAP.MySql/IStorage.MySql.cs similarity index 100% rename from src/DotNetCore.CAP.MySql/MySqlStorage.cs rename to src/DotNetCore.CAP.MySql/IStorage.MySql.cs diff --git a/src/DotNetCore.CAP.MySql/MySqlStorageConnection.cs b/src/DotNetCore.CAP.MySql/IStorageConnection.MySql.cs similarity index 100% rename from src/DotNetCore.CAP.MySql/MySqlStorageConnection.cs rename to src/DotNetCore.CAP.MySql/IStorageConnection.MySql.cs diff --git a/src/DotNetCore.CAP.MySql/MySqlStorageTransaction.cs b/src/DotNetCore.CAP.MySql/IStorageTransaction.MySql.cs similarity index 100% rename from src/DotNetCore.CAP.MySql/MySqlStorageTransaction.cs rename to src/DotNetCore.CAP.MySql/IStorageTransaction.MySql.cs