-
Notifications
You must be signed in to change notification settings - Fork 82
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
add the NFS3 protocol #155
Conversation
e8c99a1
to
ab005f1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left a bunch of comments inline. I have no doubt that I missed things too.
A few general notes:
- There are a bunch of message types which are only
Equatable
-- these should probably beHashable
andSendable
too. - The
ByteBuffer
read helpers don't follow the normal pattern of returningnil
if there aren't enough bytes and the write helpers don't return the number of bytes written. - The Mount* types seem to be duplicated as NFS* types. The latter don't appear to be used?
@@ -108,7 +108,20 @@ var targets: [PackageDescription.Target] = [ | |||
"NIOSOCKS", | |||
.product(name: "NIOCore", package: "swift-nio"), | |||
.product(name: "NIOEmbedded", package: "swift-nio"), | |||
]) | |||
]), | |||
.target( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we intentionally not defining a product here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Lukasa for now, yes. In a follow-up I might either add a product (either NIONFS3
or _NIONFS3Preview
) but we can discuss then. I want to first land the bulk of the code
Motivation:
NFS can be a very useful protocol.
Modifications:
Add the (read side, for now) of the NFS3 protocol.
This adds (partial) implementations of the following RFCs:
Essentially, NFS3 is a protocol which sends metadata & does framing via the (SUN) RPC protocol. The data is encoded using XDR. If you're familiar with gRPC, then XDR is NFS's protobuf, HTTP is NFS's RPC and NFS3 is the application protocol.
Result:
Left to do before merging:
_NIONFS3Preview
?https://github.com/apple/swift-distributed-tracing-baggage.git
is acceptable