What is the difference between state machine and workflow?
Asked Answered
E

4

32

I want to learn what is the difference between "State machine" and "workflow", and how is it any different from "State machine workflow"?

Ebarta answered 12/1, 2012 at 18:43 Comment(3)
The meaning of "workflow" is highly dependent on context. And "state machine workflow" is somewhat nonsensical.Loach
(But I see that this is a term invented by Microsoft, so the nonsense is to be expected, I guess.)Loach
Basically, in the context of .NET, the terms mean whatever Microsoft says they mean.Loach
T
13

Workflow and state machines are defined nicely on wikipedia.

I'm guessing you're getting the term State Machine Workflow from this page. .NET seems to support different ways of modeling workflows (which are just some defined steps in a complex human task). A state machine (which is a map of states with transitions between them) would allow loops as opposed to a sequential workflow, which precedes down different branches until done.

Thun answered 13/1, 2012 at 0:10 Comment(0)
P
8
  • Product Manager draw Workflow Definition Graph and then give it to the Developer/Programmer . After reading the Requirements Document writen by Product Managers, Developer/Programmer design entity ,entity state , then set state of several enities In one WorkFlow Node

  • A WorkFlow has a parallel gateway, inclusive gateway and exclusive gateway, but State Machine only has an exclusive gateway .so WorkFlow can at several workflow Nodes at the same time ,but State Machine can only at one Node

  • The term WorkFlow is highly related with representing how people do their work and how they handle information.

  • A newcomer can easily understand a program by the WorkFlow Definition Graph, and the WorkFlow Definition Graph is bound into the code by WorkFlow engines (e.g. acitivti or jbpm6). It is synchronous with code. Requirements Documents are not synchronous with the code.

Pacification answered 22/5, 2014 at 7:29 Comment(0)
S
7

As Jere mention, State machines can be cyclic graphs and workflows are usually acyclic. Most of the time the WorkFlow term is used to denote some kind of human interaction where probably some information is being modified (for example: a document). The term workflow is highly related with representing how people do their work and how they handle information. A state machine is a more technical concept where different states of an entity or a group of entities needs to be represented. You should also need to ask about Business Process probably :) Cheers

Saxhorn answered 13/1, 2012 at 10:42 Comment(0)
D
2

The major difference between a workflow engine and a state machine lies in focus. In a workflow engine, a transition to the next step occurs when a previous action is completed, whilst a state machine needs an external event that will cause branching to the next activity. In other words, the state machine is event-driven and the workflow engine is not.

I've been searching for a major difference between them until I found this real difference from here, which is true. Please refer to this article that I've quoted this difference from.

Ducharme answered 30/1, 2021 at 19:3 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.