feat(monit): add typed datasource tools and preserve configuration intent - #68
Merged
Conversation
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.
新增 DataSources.ToolsInvoke,消费正式 OpenAPI 契约。请求 params 与结果 data 使用 json.RawMessage,保留整数和小数精度;错误携带并显示 reason 与 request ID,不自动重放。
补齐数据源新类型与配置。Enabled/AlertingEnabled 使用 *bool,区分遗漏与显式 false;相关秘密字段同样保留遗漏与清空语义。兼容提示:手写 DataSourceUpsertRequest.Enabled 赋值需要改为指针。旧 diagnose 方法保留并标记弃用,Agent 说明限定 host。
只同步本次 Monitors 契约增量,未捎带上游既有 RUM/Schedules 漂移或全量排序变化。
验证:go test ./...、go test -race ./...、生成无漂移、focused HTTP roundtrip(JSON精度、错误不重放、false/遗漏/秘密字段)。
配套 PR: