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

Update bitrotten method name in comments. #518

Merged
merged 1 commit into from
May 24, 2023
Merged
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
6 changes: 3 additions & 3 deletions rpc/import.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,19 @@ type impent struct {
// 1) An import given to application code.
// 2) A new reference to the import is received over the wire, while
// the application concurrently closes the import.
// importClient.Close is called, but the receive has the lock
// importClient.Shutdown is called, but the receive has the lock
// first.
// 3) Conn.addImport attempts to return a weak client reference, but
// can't because it has been closed. It creates a new client
// with a new importClient.
// 4) importClient.Close attempts to remove the import from the import
// 4) importClient.Shutdown attempts to remove the import from the import
// table. This is the critical step: it needs to be informed that
// it should not do this because another client has been created.
// No release message should be sent.
//
// The generation counter solves this by amending steps 3 and 4. When
// a new importClient is created, generation is incremented.
// When importClient.Close is called, then it must check that the
// When importClient.Shutdown is called, then it must check that the
// importClient's generation matches the entry's generation before
// removing the entry from the table and sending a release message.
generation uint64
Expand Down