feat: add scoped workflow instance queries and SDK pagination
This commit is contained in:
20
weave/model/version_scope.go
Normal file
20
weave/model/version_scope.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
core "git.yuntuo.hk/k2safe/orbit/model"
|
||||
)
|
||||
|
||||
// VersionScope 是固定流程版本的队列查询索引;不能替代原定义校验或授予执行权限。
|
||||
// 对应weave_version_scopes,不使用外键;发布与本索引在同一事务提交。
|
||||
type VersionScope struct {
|
||||
NamespaceID core.ID `db:"namespace_id"` // NamespaceID 命名空间,与版本共同构成唯一身份及授权边界。
|
||||
DefinitionVersionID core.ID `db:"definition_version_id"` // DefinitionVersionID 固定定义版本标识,包含未执行分支的全部队列。
|
||||
DefinitionID core.ID `db:"definition_id"` // DefinitionID 所属定义,查询必须与版本和实例共同核对。
|
||||
ContentDigest core.Digest `db:"content_digest"` // ContentDigest 原不可变定义摘要,不能用其他版本的范围授权。
|
||||
QueueIDs core.JSON `db:"queue_ids"` // QueueIDs 去重的32位队列标识JSON数组,最多128项;空数组表示流程不执行任务,顺序无语义。
|
||||
CreatedAt time.Time `db:"created_at"` // CreatedAt 索引建立时间,UTC;不改变原版本发布时间或实例截止。
|
||||
}
|
||||
|
||||
func (VersionScope) TableName() string { return "weave_version_scopes" }
|
||||
Reference in New Issue
Block a user