从业务对象反序列化工作流基础 [英] Workflow foundation deserialization from business objects

查看:27
本文介绍了从业务对象反序列化工作流基础的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究 Microsoft WF 示例,发现它们序列化/反序列化尚未完成以保持其状态的工作流.我不喜欢它,因为工作流是一个过程,它不需要任何额外的数据就可以从不同的线程或代码部分继续.

I'm studying Microsoft WF samples and have found that they serializing/deserializing workflows that are not finished to hold its state. I don't like it as workflow is a process and it doesn't need any additional data to continue from a different thread or code part.

也许我错过了一些东西.如果可能,您能否分享保存/加载未完成工作流程的示例?也许替代的工作流框架可以不用序列化/反序列化.例如,它可以从业务对象状态恢复.

Maybe I've missed something. Can you share examples of saving/loading unfinished workflows if it's possible? Maybe alternative workflow frameworks can do without serialization/deserialization. For example it could be restored from business object state.

推荐答案

你的想法太小了.有许多超出您现在想象的用途.所有工作流框架(除非它们使用某种类型的对象数据库?)都会序列化工作流状态,以便以后可以继续.Microsoft WF、K2 BlackPerl 和许多其他公司都这样做.K2 这样做是因为您可以让一个项目通过工作流 v1,然后在中间有人会将工作流更新到 v2,但 K2 足够聪明,知道应该继续在 v1 工作流下处理该项目.

You're thinking far too small. There are many uses beyond what you can imagine right now. All workflow frameworks (unless they use some type of object db?) will serialize the workflow state so it can be continued at a later time. Microsoft WF, K2 BlackPerl and many others do this. K2 does it because you can have an item going through workflow v1 and then right in the middle someone will update the workflow to v2 but K2 is smart enough to know that is should continue processing that item under the v1 workflow.

也许我错过了您的问题,但您似乎不喜欢它序列化存储工作流.

Maybe i'm missing your question but it seems like you don't like that it serializes the workflow for storage.

这篇关于从业务对象反序列化工作流基础的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆