Verify Target-Ref working with SplitGroup with AppSettings.json
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 25/100
- Issue 类型
- 功能
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- csharp
调研方向
首先复现带有 SplitGroup target 及其对 logconsole 和 email 的引用的 AppSettings.json 配置,然后将其行为与 XML target-ref 示例进行比较。确定声明顺序或字典排序是否会影响 target 解析;当行为得到验证并确定了任何所需的更改后,即视为完成。
由索引模型根据 Issue 内容生成。
描述
Could be nice if one could do this:
{
"NLog": {
"throwConfigExceptions": true,
"targets": {
"logconsole": {
"type": "Console"
},
"email": {
"type": "mail"
},
"bothTargets": {
"type": "SplitGroup",
"targets": {
"logconsole": null,
"email": null
}
}
},
"rules": [
{
"logger": "*",
"minLevel": "Info",
"writeTo": "bothTargets"
}
]
}
}
Maybe one will get "cheated" by the automatic sorting of dictionary-items, so the splitgroup must be named so it comes "last", after the other target-names to ensure they have been parsed/declared.
Similar to this:
<targets>
<target name='email' xsi:type='mail' />
<target name='logconsole' xsi:type='console' />
<target name="bothTargets" xsi:type="SplitGroup">
<target-ref name="logconsole" />
<target-ref name="email" />
</target>
</targets>
See also: https://github.com/NLog/NLog.Extensions.Logging/issues/568#issuecomment-1030264661
- 主要语言
- C#
- 星标
- 404
- 派生
- 149
- 平均合并
- 10 小时 59 分钟
- 30 天内合并 PR
- 18
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
NLog/NLog.Extensions.Logging 的其他 Issue
-
feature
难度 4/5 3-5 天 新手友好度 45/100
NLog/NLog.Extensions.Logging#865 ·
维护者通常 1 天内回复
-
feature up-for-grabs
难度 3/5 1-2 天 新手友好度 35/100
NLog/NLog.Extensions.Logging#729 · 1 条评论 ·
维护者通常 1 天内回复
查看 NLog/NLog.Extensions.Logging 的全部 Issue
相似的 Issue
-
[中] 更新器下载缓存从不清理未关闭
难度 2/5 1-3 小时 新手友好度 72/100
-
Remove duplicate Vimeo DI registration; use NimblePros.Vimeo AddVimeoServices and upgrade package未关闭
难度 2/5 1-3 小时 新手友好度 72/100
DevBetterCom/DevBetterWeb#1486 · 1 条评论 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
NimblePros/eShopOnWeb#333 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
Natvs/Nt.Automaton#33 ·
-
enhancement
难度 2/5 1-3 小时 新手友好度 68/100