Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions entrypoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,13 @@ func RunBlockchain() {
//✅ 4.Start a separate thread to work with voting for blocks in a sync way (for security)
go threads.LeaderRotationThread()

//✅ 5.Logical thread to build the temporary sequence of blocks to execute them (prepare for execution thread)
//✅ 5.Start finalization thread to aggregate leader rotation proofs
go threads.FinalizationThread()

//✅ 6.Logical thread to build the temporary sequence of blocks to execute them (prepare for execution thread)
go threads.SequenceAlignmentThread()

//✅ 6.Start execution process - take blocks and execute transactions
//✅ 7.Start execution process - take blocks and execute transactions
go threads.ExecutionThread()

//___________________ RUN SERVERS - WEBSOCKET AND HTTP __________________
Expand Down
7 changes: 7 additions & 0 deletions handlers/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ var APPROVEMENT_THREAD_METADATA = struct {
},
}

var FINALIZATION_THREAD_CACHE = struct {
RWMutex sync.RWMutex
EpochHandlers map[int]structures.EpochDataHandler
}{
EpochHandlers: make(map[int]structures.EpochDataHandler),
}

var EXECUTION_THREAD_METADATA = struct {
RWMutex sync.RWMutex
Handler structures.ExecutionThreadMetadataHandler
Expand Down
Loading