- 回收 SQL 占位符改为 $1/$2,消除 pgx 扩展协议 42P18(手动/定时对账 500) - 直接写入 finding 时归一空 confirmation_state,避免 23514 - 修正 R6/overview 同谓词用例夹具,两条台账各自持有 source version - 页面顶部统一服务与队列单行状态条,删除 Embedding/LLM 常量卡 - 平台阶段筛选合并为「WeKnora 处理中」,后端支持 stage=weknora - weknora_url 由测试 WeKnora 源构造,详情与 503 提供跳转链接 - 补 1000/页线上查询、R8 合法收养、weknora 阶段筛选用例
This commit is contained in:
@@ -306,11 +306,10 @@ func (provider *RealProvider) Services(ctx context.Context) []governance.Service
|
||||
health = append(health, provider.weKnoraProbe(ctx, now))
|
||||
health = append(health, provider.productionWeKnoraProbe(ctx, now))
|
||||
health = append(health, provider.httpProbe(ctx, "mineru", "MinerU", provider.minerUBaseURL, now))
|
||||
// Not-applicable dependencies stay explicit (embedding/llm managed by
|
||||
// WeKnora, redis/mq/oss not deployed).
|
||||
// Not-applicable dependencies stay explicit (redis/mq/oss not deployed).
|
||||
// Embedding/LLM are managed inside WeKnora and are not platform services;
|
||||
// listing them here produced two permanent "unknown" cards on the page.
|
||||
health = append(health,
|
||||
provider.track(classify("embedding", "Embedding模型", false, false, ProbeOutcome{ObservedAt: now})),
|
||||
provider.track(classify("llm", "LLM模型", false, false, ProbeOutcome{ObservedAt: now})),
|
||||
provider.track(classify("redis", "Redis / MQ", false, false, ProbeOutcome{ObservedAt: now})),
|
||||
provider.track(classify("oss", "OSS", false, false, ProbeOutcome{ObservedAt: now})),
|
||||
)
|
||||
|
||||
@@ -59,11 +59,18 @@ func TestRealServicesHealthMatrix(t *testing.T) {
|
||||
if byKey["weknora-production/r"] != ReadNotConfigured || byKey["weknora-production/l"] != LiveUnknown {
|
||||
t.Fatalf("unconfigured production endpoint = %v/%v", byKey["weknora-production/l"], byKey["weknora-production/r"])
|
||||
}
|
||||
for _, key := range []string{"redis", "oss", "embedding", "llm"} {
|
||||
for _, key := range []string{"redis", "oss"} {
|
||||
if byKey[key+"/r"] != ReadNotApplicable || byKey[key+"/l"] != LiveUnknown {
|
||||
t.Fatalf("not-deployed %s = %v/%v", key, byKey[key+"/l"], byKey[key+"/r"])
|
||||
}
|
||||
}
|
||||
// Embedding/LLM belong to WeKnora; the platform must not render them as
|
||||
// permanent unknown cards (requirement §8).
|
||||
for _, key := range []string{"embedding", "llm"} {
|
||||
if _, ok := byKey[key+"/r"]; ok {
|
||||
t.Fatalf("platform health still lists %s", key)
|
||||
}
|
||||
}
|
||||
// Readiness must be blocked ONLY by configured+deployed failures: worker.
|
||||
ok, blocked := overallReadiness(health)
|
||||
if ok || len(blocked) != 1 || blocked[0] != "worker" {
|
||||
|
||||
@@ -32,10 +32,13 @@ func TestOverviewRemovalDemandAndSharedViewAgree(t *testing.T) {
|
||||
exec(`INSERT INTO source_items(id,source_connection_id,stable_external_id,canonical_uri_hash,title,item_type,policy_state)
|
||||
VALUES('si-recon-view','conn-recon-view','recon.md',repeat('b',64),'对账视图','file','blocked')`)
|
||||
exec(`INSERT INTO source_item_versions(id,source_item_id,revision,content_state) VALUES('sv-recon-view','si-recon-view','r1','verified')`)
|
||||
// test_publications is unique on (source_item_version_id,test_kb_id): a second
|
||||
// publication in the same KB must point at its own version, not reuse r1.
|
||||
exec(`INSERT INTO source_item_versions(id,source_item_id,revision,content_state) VALUES('sv-recon-removing','si-recon-view','r2','verified')`)
|
||||
exec(`INSERT INTO test_publications(id,source_item_version_id,test_kb_id,knowledge_id,ingest_state,processing_state,retrieval_state)
|
||||
VALUES('pub-recon-view','sv-recon-view','kb-recon-view','doc-recon-view','uploaded','completed','unpublished')`)
|
||||
exec(`INSERT INTO test_publications(id,source_item_version_id,test_kb_id,knowledge_id,ingest_state,processing_state,retrieval_state)
|
||||
VALUES('pub-recon-removing','sv-recon-view','kb-recon-view','doc-recon-removing','uploaded','completed','disabling')`)
|
||||
VALUES('pub-recon-removing','sv-recon-removing','kb-recon-view','doc-recon-removing','uploaded','completed','disabling')`)
|
||||
|
||||
provider, err := NewRealProvider(RealProviderConfig{DB: metricsPool{pool: pool}})
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user