代码改变世界

随笔档案-2023年04月

asp.netcore 获取中间件列表

2023-04-18 22:37 by qgbo, 50 阅读, 收藏, 编辑
摘要: var applicationBuilderInfo = app.GetType().GetProperty("ApplicationBuilder", BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.IgnoreCase) 阅读全文

Httpcontext.signIn() 执行了什么?

2023-04-07 23:41 by qgbo, 113 阅读, 收藏, 编辑
摘要: asp.netcore 登录的时候可以写 Httpcontext.signIn(user) ; 这个方法,如果用cookie 最后会些写cookie信息到Httpcontext.respones 中。 定义 public static Task SignInAsync(this HttpContex 阅读全文

Serilog.Sinks.Elasticsearch 写username到 ES失败

2023-04-07 21:38 by qgbo, 41 阅读, 收藏, 编辑
摘要: Using the lib: Serilog.Sinks.Elasticsearch and ECS-dotnet which provide the ecs format, we can write log into es in ECS format. I have been able to ov 阅读全文
点击右上角即可分享
微信分享提示