Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

State transfer #68

Merged
merged 6 commits into from
May 23, 2022
Merged

Conversation

sergefdrv
Copy link
Contributor

@sergefdrv sergefdrv commented May 20, 2022

This pull request resolves #11. Tested on chat demo with the following patch:

diff --git a/pkg/iss/iss.go b/pkg/iss/iss.go
index 68d38ed..ae67d31 100644
--- a/pkg/iss/iss.go
+++ b/pkg/iss/iss.go
@@ -665,6 +665,9 @@ func (iss *ISS) applyMessageReceived(messageReceived *eventpb.MessageReceived) *
 	case *isspb.ISSMessage_StableCheckpoint:
 		return iss.applyStableCheckpointMessage(msg.StableCheckpoint, from)
 	case *isspb.ISSMessage_Sb:
+		if iss.ownID == t.NodeID("1") {
+			return &events.EventList{}
+		}
 		return iss.applySBMessage(msg.Sb, from)
 	case *isspb.ISSMessage_RetransmitRequests:
 		return iss.applyRetransmitRequestsMessage(msg.RetransmitRequests, from)

Closes consensus-shipyard/consensuslab#69
Closes consensus-shipyard/consensuslab#62

@sergefdrv sergefdrv self-assigned this May 20, 2022
Copy link
Contributor

@matejpavlovic matejpavlovic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! Found just a few typos and have one question.

pkg/iss/iss.go Outdated Show resolved Hide resolved
pkg/iss/iss.go Outdated Show resolved Hide resolved
pkg/iss/iss.go Outdated Show resolved Hide resolved
pkg/iss/iss.go Outdated Show resolved Hide resolved
protos/eventpb/eventpb.proto Outdated Show resolved Hide resolved
pkg/iss/iss.go Outdated Show resolved Hide resolved
Sergey Fedorov added 2 commits May 23, 2022 11:36
@sergefdrv
Copy link
Contributor Author

Summary of changes: fixed typos

@sergefdrv
Copy link
Contributor Author

Summary of change: removed deferring of epoch instance activation upon restoring state snapshot

@sergefdrv sergefdrv merged commit e95a41d into consensus-shipyard:main May 23, 2022
@sergefdrv sergefdrv deleted the state-transfer branch May 30, 2022 08:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants