diff --git a/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/Program.cs b/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/Program.cs
index 87abaf09..a2623cf8 100644
--- a/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/Program.cs
+++ b/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/Program.cs
@@ -57,6 +57,10 @@ builder.Services.AddSqlsugarServer();
#endregion
builder.Services.AddQuartzService();
#region
+//AutoMapper注入
+#endregion
+builder.Services.AddAutoMapperService();
+#region
//控制器+过滤器配置
#endregion
builder.Services.AddControllers(optios => {
@@ -150,7 +154,7 @@ app.UseCorsService();
#region
//健康检查注入
#endregion
-app.UseHealthCheckMiddleware();
+app.UseHealthCheckService();
#region
//鉴权注入
#endregion
diff --git a/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/configuration.json b/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/configuration.json
index a8d7b639..4431edcd 100644
--- a/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/configuration.json
+++ b/Yi.Framework.Net6/Yi.Framework.ApiMicroservice/configuration.json
@@ -2,7 +2,7 @@
"apollo": {
"AppId": "ApiMicroservice",
"Env": "DEV",
- "MetaServer": "http://119.91.207.67:18080",
- "ConfigServer": [ "http://119.91.207.67:18080" ]
+ "MetaServer": "http://[xxxx]:18080",
+ "ConfigServer": [ "http://[xxxx]:18080" ]
}
}
\ No newline at end of file
diff --git a/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/AutoMapperExtension.cs b/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/AutoMapperExtension.cs
index daefb162..f8f34417 100644
--- a/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/AutoMapperExtension.cs
+++ b/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/AutoMapperExtension.cs
@@ -2,6 +2,7 @@
using Microsoft.Extensions.DependencyInjection;
using System;
using System.IO;
+using Yi.Framework.WebCore.Mapper;
namespace Yi.Framework.WebCore.MiddlewareExtend
{
@@ -10,9 +11,9 @@ namespace Yi.Framework.WebCore.MiddlewareExtend
///
public static class AutoMapperExtension
{
- public static IServiceCollection AddAutoMapperExtensionService(this IServiceCollection services,Type type)
+ public static IServiceCollection AddAutoMapperService(this IServiceCollection services)
{
- services.AddAutoMapper(type);
+ services.AddAutoMapper(typeof(AutoMapperProfile));
return services;
}
}
diff --git a/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/HealthCheckExtension.cs b/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/HealthCheckExtension.cs
index 0a489f8a..a8658784 100644
--- a/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/HealthCheckExtension.cs
+++ b/Yi.Framework.Net6/Yi.Framework.WebCore/MiddlewareExtend/HealthCheckExtension.cs
@@ -20,7 +20,7 @@ namespace Yi.Framework.WebCore.MiddlewareExtend
///
/// 榛樿鏄/Health
///
- public static void UseHealthCheckMiddleware(this IApplicationBuilder app, string checkPath = "/Health")
+ public static void UseHealthCheckService(this IApplicationBuilder app, string checkPath = "/Health")
{
if (Appsettings.appBool("HealthCheck_Enabled"))
{
diff --git a/Yi.Framework.Net6/Yi.Framework.WebCore/Utility/CustomHostingStartup.cs b/Yi.Framework.Net6/Yi.Framework.WebCore/Utility/CustomHostingStartup.cs
index 58fcabb7..02400da8 100644
--- a/Yi.Framework.Net6/Yi.Framework.WebCore/Utility/CustomHostingStartup.cs
+++ b/Yi.Framework.Net6/Yi.Framework.WebCore/Utility/CustomHostingStartup.cs
@@ -8,13 +8,17 @@ using System.Linq;
using System.Threading.Tasks;
[assembly: HostingStartup(typeof(Yi.Framework.WebCore.Utility.CustomHostingStartup))]
+//杩欓噷鏀句笂鍚姩绫讳笅鐨刣ll锛屽嵆鑷姩渚靛叆浜嗭紝褰撶劧鎴戜滑鐜板湪涓嶄細杩欐牱鍋氥
namespace Yi.Framework.WebCore.Utility
{
///
/// 蹇呴』瀹炵幇IHostingStartup鎺ュ彛
/// 蹇呴』鏍囪HostingStartup鐗规
///
- /// 灏卞儚鏈ㄩ┈涓鏍
+ /// 浣犲皬瀛愶紒杩樻槸琚綘鍙戠幇浜嗗晩锛屾暀浣犱竴鎷涢獨鎿嶄綔锛佽繖鏄竴涓睂鐨勪笢瑗匡紒
+ ///
+ /// 鎴戜滑绉板畠涓猴細 鏃犱镜娉ㄥ叆锛 瀹冨交澶村交灏惧氨鏄竴涓湪椹梾姣掞紒
+ ///
///
public class CustomHostingStartup : IHostingStartup
{