world_sync/wwwroot/api/execute_sync.dspy

11 lines
533 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# -*- coding: utf-8 -*-
"""同步任务执行W-05POST /api/execute_sync.dspy —— 批量事务+失败回滚无脏数据"""
# 说明:本文件被 ahserver 包装为 async def handler(request, **ns) 执行,
# 直接调用 load_world_sync 注册的全局函数 execute_sync。
# 参数sync_code, sync_name, sync_type(full/incremental), source_type(world/scene/entity),
# target_type(world/scene/entity), source_ids(可选,逗号分隔), limit(可选)
result = await execute_sync(dict(params_kw))
return result