Draft: proposal: generator(all): Introduce the model struct diff mechanism , the ormDiffTag
, and the generator
#314
Labels
v2
ezorm v2
ormDiffTag
, and the generator
#314
背景
在一些特定的业务场景(审计日志)下,往往会需要在 model 层 (不管是 M1 -> M 还是 P2 ->(C3) -> M ) 记录一些 changelog(auditlog) 变化
Proposal
The Generator (diff模板生成)
在 (YAML)model struct 上生成 diff 方法,diff 方法接受另一个 M (提供 option , 可以带入一个 P -> C -> M 的转换过程)。
The Differ
Differ 用来描述一次具体的DIFF结果,DIFF 结果可以按照不同业务场景组装:
Key
的层级聚合Footnotes
M: Model Struct ↩
P: (API)Protocol(ProtoBuffer/Thrift/Json-To-Go) Struct ↩
C: The Converter between P <-> M ↩
The text was updated successfully, but these errors were encountered: