Skip to content

Phases management: state machines of DisputeKitClassic and KlerosCore #26

@jaybuidl

Description

@jaybuidl

Previously in v1, the state machine would go through: Staking->Generating->Drawing->Staking.

In v2 things are different because:

  • Staking is the Core's responsibility
  • Generating and Drawing is the DisputeKit's responsibility

Future dispute kits may even have totally different state machines, but they will always including some form of drawing stage.

In addition different DisputeKit implementations may use totally different RNGs with longer or shorter durations in Generating phase. Therefore different DisputeKits can proceed from Generating to Drawing phases in parallel as long as they all join at the end of their Drawing phase.

Some kind of coordination is needed:

  1. For Core to notify a particular DisputeKit that a dispute is in need of jurors
  2. For Core to notify all the DisputeKits that the maxDrawingTime has passed
  3. For a DisputeKit to notify Core that it has completed its drawing of jurors for the disputes notified by 1.

Possible state machines for v2

  • KlerosCore: Staking->Freezing->Staking
  • DisputeKitClassic: Generating->Drawing->Resolving->Generating

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions