NETCore下IConfiguration和IOptions的用法
NETCore下IConfiguration和IOptions的用法
https://www.cnblogs.com/RainingNight/p/strongly-typed-options-configure-in-asp-net-core.html
if ("Y" == Configuration.GetSection("AppSettings").GetValue<string>("EnableQueue").ToUpper()) Service.SOService._IsSendQueue = true;
{ "ConnectionStrings": { "coon": "ccc" }, "AppSettings": { "EnableQueue": "Y" }, "Logging": { "LogLevel": { "Default": "Information", "Microsoft": "Warning", "Microsoft.Hosting.Lifetime": "Information" } }, "AllowedHosts": "*" }
public static Boolean _IsSendQueue { get; set; } if (_IsSendQueue == true)
人各有命,上天注定,有人天生为王,有人落草为寇。脚下的路,如果不是你自己的选择,那么旅程的终点在哪,也没人知道。你会走到哪,会遇到谁,都不一定。