Interface FlowDefinitionService
- All Known Implementing Classes:
DefaultFlowDefinitionService
public interface FlowDefinitionService
Flow-definition facade: deploy, list, deprecate.
流程定义门面:部署、查询、弃用。
- Since:
- JDK 25, opencode-base-flow V1.0.5
- Author:
- Leon Soo
-
Method Summary
Modifier and TypeMethodDescriptionDeploy a new flow definition from the given JSON DSL.voidDeprecate a specific (flowKey, version) definition.findActive(String flowKey) Returns the currently active definition for the given business key.listVersions(String flowKey) Lists every version of the given business key (asc by version).
-
Method Details
-
deploy
Deploy a new flow definition from the given JSON DSL. Allocates an id (snowflake) and persists it as ACTIVE. 部署新的流程定义(从 JSON DSL)。分配 id(snowflake)并以 ACTIVE 持久化。- Parameters:
dslJson- DSL JSON string — DSL JSON 串- Returns:
- persisted definition — 已持久化的定义
- Since:
- JDK 25, opencode-base-flow V1.0.5
-
findActive
Returns the currently active definition for the given business key. 返回业务 key 当前 ACTIVE 的定义。- Parameters:
flowKey- business key — 业务 key- Returns:
- active definition (Optional) — 当前定义(Optional)
- Since:
- JDK 25, opencode-base-flow V1.0.5
-
listVersions
Lists every version of the given business key (asc by version). 列出业务 key 的所有版本(按 version 升序)。- Parameters:
flowKey- business key — 业务 key- Returns:
- all versions — 全部版本
- Since:
- JDK 25, opencode-base-flow V1.0.5
-
deprecate
Deprecate a specific (flowKey, version) definition. 弃用指定 (flowKey, version) 的定义。- Parameters:
flowKey- business key — 业务 keyversion- definition version — 定义版本号- Since:
- JDK 25, opencode-base-flow V1.0.5
-