digraph "g" {
	graph [
		fontsize = "12"
		fontname = "Times-Roman"
		fontcolor = "black"
		bb = "0,0,398.922306,478.927856"
		color = "black"
	]
	node [
		fontsize = "12"
		fontname = "Times-Roman"
		fontcolor = "black"
		shape = "ellipse"
		color = "black"
	]
	edge [
		fontsize = "12"
		fontname = "Times-Roman"
		fontcolor = "black"
		color = "black"
	]

// special nodes
	"S_STARTING" 
	[
	 color = "blue"
	 fontcolor = "blue"
	 ]
	"S_TERMINATE" 
	[
	 color = "red"
	 fontcolor = "red"
	 ]

// DC only nodes
	"S_RECOVERY_DC" [ fontcolor = "green" ]
	"S_INTEGRATION" [ fontcolor = "green" ]
	"S_POLICY_ENGINE" [ fontcolor = "green" ]
	"S_TRANSITION_ENGINE" [ fontcolor = "green" ]
	"S_RELEASE_DC" [ fontcolor = "green" ]
	"S_<ANY_DC>" [ fontcolor = "green" ]
	"S_IDLE" [ fontcolor = "green" ]

// state transitions
	"S_<ANY>" -> "S_ELECTION" [ label = "I_DC_TIMEOUT" ]
	"S_<ANY>" -> "S_RECOVERY"  [ label = "I_ERROR" ]
	"S_<ANY>" -> "S_<ANY>" [ label = "I_ROUTER,\nI_REQUEST" ]

	"S_<ANY_DC>" -> "S_RELEASE_DC"  [ label = "I_SHUTDOWN" ]
	"S_<ANY_DC>" -> "S_INTEGRATION"  [ label = "I_NODE_JOIN" ]
	"S_<ANY_DC>" -> "S_POLICY_ENGINE"  [ label = "I_CIB_UPDATE,\nI_NODE_LEFT,\nI_NODE_LEAVING" ]
	"S_<ANY_DC>" -> "S_RECOVERY_DC" [ label = "I_ERROR" ]
	"S_<ANY_DC>" -> "S_<ANY_DC>" [ label = "I_ROUTER,\nI_REQUEST" ]

	"S_ELECTION" -> "S_INTEGRATION"  [ label = "I_ELECTION_DC" ]
	"S_ELECTION" -> "S_NOT_DC"  [ label = "I_NOT_DC" ]
	"S_ELECTION" -> "S_RELEASE_DC"  [ label = "I_ELECTION_RELEASE_DC" ]

	"S_INTEGRATION" -> "S_POLICY_ENGINE"  [ label = "I_SUCCESS" ]

	"S_NOT_DC" -> "S_STOPPING"  [ label = "I_SHUTDOWN" ]

	"S_POLICY_ENGINE" -> "S_TRANSITION_ENGINE"  [ label = "I_SUCCESS" ]
	"S_POLICY_ENGINE" -> "S_POLICY_ENGINE"  [ label = "I_FAIL\nI_RESTART" ]

	"S_RECOVERY_DC" -> "S_INTEGRATION" [ label = "I_RECOVERED" ]
	"S_RECOVERY_DC" -> "S_RELEASE_DC" [ label = "I_NOT_DC,\nI_SHUTDOWN" ]

	"S_RECOVERY" -> "S_STOPPING" [ label = "I_SHUTDOWN" ]
	"S_RECOVERY" -> "S_NOT_DC" [ label = "I_RECOVERED" ]

	"S_RELEASE_DC" -> "S_NOT_DC"  [ label = "I_RELEASE_SUCCESS" ]
	"S_RELEASE_DC" -> "S_STOPPING"  [ label = "I_RELEASE_FAIL" ]

	"S_STARTING" -> "S_STOPPING"  [ label = "I_FAIL" ]
	"S_STARTING" -> "S_NOT_DC"  [ label = "I_SUCCESS" ]

	"S_STOPPING" -> "S_TERMINATE"  [ label = "I_SUCCESS,\nI_FAIL" ]

	"S_TRANSITION_ENGINE" -> "S_POLICY_ENGINE"  [ label = "I_FAIL" ]
	"S_TRANSITION_ENGINE" -> "S_IDLE"  [ label = "I_SUCCESS" ]
}
