WIP: 3PH#533
Draft
zenhack wants to merge 53 commits into
Draft
Conversation
...and some logic to start the handoff process. Not done yet, but only affects codepaths where the network is non-nil.
i.e. the connection we're sending to.
I want to add a few testing-specific methods.
In particular: - The way we were supplying rpc.Options was clumsy. For now we have a network-specific way of doing this, but it could easily generalize. - The Accept method wasn't really what we wanted either; has been replaced by Serve().
Also, supply a large buffer for connections.
These need to be comparable.
I don't think there's more to do in this section.
...and note some other things to test.
Fails currently; the exception returned is 'failed' rather than 'unimplemented', which suggests that it may not be being forwarded correctly. Need to investigate further. This also factors out a bunch of common logic into a helper function.
This gets rid of a panic("TODO: ...").
The test still fails, but I know why.
Passes!
That is, don't, and clean up. For good measure, move the snapshot.Release() out of the critical section, as I'm not sure this is valid.
...did I really not run the tests after this?
Still fails because of the obvious panic("TODO..."), but caught a couple
unrelated bugs.
The new interface: - Has levels (debug, info, warn, error) - Accepts arguments for structured logging Per the comments, the interface is designed to be used with *slog.Logger, though other implementations are possible (and we already use one in test).
I'm going to punt this off until after the basic 3PH, so let's make sure this is correct after that.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
There is much more to do, but this is the beginning of 3PH.