Repository navigation
feat(core): 统一可观测性记录与后端查询 - #178
Merged
Merged
Conversation
This was referenced Nov 4, 2026
xiaoland
force-pushed
the
feat/observability-unification
branch
from
November 4, 2026 13:45
650e1cb to
0b310bf
Compare
xiaoland
force-pushed
the
feat/observability-unification
branch
from
November 4, 2026 13:49
0b310bf to
0867de6
Compare
xiaoland
force-pushed
the
feat/observability-unification
branch
from
November 5, 2026 09:51
0867de6 to
3985de5
Compare
xiaoland
marked this pull request as ready for review
November 5, 2026 09:51
3 of 5 tasks
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
成功执行的 Job 过去只产生可选 OTLP 事件,Web 的 PostgreSQL 日志查询因此可能为空。本 PR 让基础记录和查询使用同一个选定后端,通过 Core 的采集入口协调额外 OTLP 出口。
范围
inkcre.observability.backend缺省 PostgreSQL,Loki 使用服务端私密 URL、headers 和稳定部署身份。配置或外部访问失败会显式报告。core.observability.v1在认证的/observability提供 status/query/ingest,expected_backend保护目标选择。查询在截断前过滤,最大时间窗 31 天,最多 500 条,并返回截断状态。job.<id>关联继续支持查询。持久 Job 事实由 jobs 表承担,诊断查询呈现所选后端的有界历史窗口。切换后重启提供方并重建消费实例,旧数据由原存储保留。部署需协调升级仍使用旧 Logtail writer 的生产者。
发布项目为
inkcre-core,包含服务镜像,Towncrier fragment 已记录。合并基线与验证
父 PR #175 已合并为
4fa74bb。当前候选3985de5直接基于该 main,git range-diff核对观测源码提交与原候选一致。共享引用继承 main 中已合入 Hub 的17fc19e7230187a7a989815e7b8303bbb380f478,原草稿引用提交已在重排时剥除。本轮发布意图、共享引用及差异空白检查通过,最终合并使用当前 head 的云端 required checks。
实施阶段本地非 integration/acceptance 集合为 114 passed、9 skipped、1 deselected,另有 Pyrefly 0 diagnostics、Ruff、wheel 仓库外导入和受控传输验证。这些本地结果取得于最后同步主线之前。本轮端到端验证由云端执行,用户要求的本地边界继续适用。
风险与回滚
外部后端可用性、内容边界和实例生命周期影响诊断记录。status 的 configured/queryable 表示已配置能力,dropped 表示本实例已知损失,持久化和真实部署路由由实际后端响应确认。
可整体撤销本 PR 的源码提交并恢复父 PR 产物。曾选择 Loki 的部署需要同时恢复相应配置,PG 和 Loki 历史数据继续保留。
交付与关联
用户已授权本组 PR 按顺序合并。当前执行者复核了后端选择、生命周期、边界和重排内容,待 required checks 满足后执行普通 squash 合并。整组完成后,指定 Dogfood 聊天按 main 更新正式自部署。
本 PR 直接基于 main,已合并父 PR 为 #175,后续 PR 为 #181。共享观测合同为 InKCre/docs#53、#57,跨仓跟踪为 InKCre/docs#52。