fix(sync): buildings 流补 ChangesTools import 与 ChangesToolsTest 断言
This commit is contained in:
@@ -5,6 +5,7 @@ import me.iiv.agent.mcp.McpErrorCode;
|
|||||||
import me.iiv.agent.mcp.ToolCallException;
|
import me.iiv.agent.mcp.ToolCallException;
|
||||||
import me.iiv.agent.mcp.XqTool;
|
import me.iiv.agent.mcp.XqTool;
|
||||||
import me.iiv.agent.mcp.sync.BatteryFaultsSyncEntity;
|
import me.iiv.agent.mcp.sync.BatteryFaultsSyncEntity;
|
||||||
|
import me.iiv.agent.mcp.sync.BuildingsSyncEntity;
|
||||||
import me.iiv.agent.mcp.sync.ChangesEngine;
|
import me.iiv.agent.mcp.sync.ChangesEngine;
|
||||||
import me.iiv.agent.mcp.sync.ContractsSyncEntity;
|
import me.iiv.agent.mcp.sync.ContractsSyncEntity;
|
||||||
import me.iiv.agent.mcp.sync.DeviceLifecyclesSyncEntity;
|
import me.iiv.agent.mcp.sync.DeviceLifecyclesSyncEntity;
|
||||||
@@ -34,9 +35,9 @@ import java.util.Map;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 增量同步工具(REQ-20260911-0013;P2 域扩展于 REQ-20260902-0002):
|
* 增量同步工具(REQ-20260911-0013;P2 域扩展于 REQ-20260902-0002):
|
||||||
* users/properties/contracts/repayment-targets/repayment-details/mall-orders/
|
* users/properties/buildings/contracts/repayment-targets/repayment-details/mall-orders/
|
||||||
* device-lifecycles/battery-faults/devices/withdraw-orders/relocation-orders/
|
* device-lifecycles/battery-faults/devices/withdraw-orders/relocation-orders/
|
||||||
* install-orders 十二个 changes 工具,
|
* install-orders 十三个 changes 工具,
|
||||||
* 协议(snapshot/cursor/tombstone/sync_token)由 ChangesEngine 统一实现。
|
* 协议(snapshot/cursor/tombstone/sync_token)由 ChangesEngine 统一实现。
|
||||||
* 数据域硬约束:本类不声明 tenant_id/scope 入参,数据域只能从 Token 推导;
|
* 数据域硬约束:本类不声明 tenant_id/scope 入参,数据域只能从 Token 推导;
|
||||||
* GuardedToolCallback 对 *.changes.list 工具的原始入参做二次拦截,传 tenant_id/scope 一律拒绝。
|
* GuardedToolCallback 对 *.changes.list 工具的原始入参做二次拦截,传 tenant_id/scope 一律拒绝。
|
||||||
|
|||||||
@@ -41,8 +41,9 @@ class ChangesToolsTest {
|
|||||||
callback -> callback.getToolDefinition().name(),
|
callback -> callback.getToolDefinition().name(),
|
||||||
callback -> callback.getToolDefinition().inputSchema()));
|
callback -> callback.getToolDefinition().inputSchema()));
|
||||||
|
|
||||||
assertEquals(14, schemas.size());
|
assertEquals(15, schemas.size());
|
||||||
for (String name : new String[]{"users.changes.list", "properties.changes.list", "contracts.changes.list",
|
for (String name : new String[]{"users.changes.list", "properties.changes.list", "buildings.changes.list",
|
||||||
|
"contracts.changes.list",
|
||||||
"repayment-targets.changes.list", "repayment-details.changes.list",
|
"repayment-targets.changes.list", "repayment-details.changes.list",
|
||||||
"mall-orders.changes.list", "device-lifecycles.changes.list", "battery-faults.changes.list",
|
"mall-orders.changes.list", "device-lifecycles.changes.list", "battery-faults.changes.list",
|
||||||
"devices.changes.list", "withdraw-orders.changes.list", "relocation-orders.changes.list",
|
"devices.changes.list", "withdraw-orders.changes.list", "relocation-orders.changes.list",
|
||||||
|
|||||||
Reference in New Issue
Block a user