Skip to content

Conversation

@realrajaryan
Copy link
Contributor

@realrajaryan realrajaryan commented Sep 17, 2025

Addresses apple/container#141, where containers don't receive filesystem events on mounted volumes, preventing incremental rebuilds and other file-watching features. This PR implements the guest-side components for FSNotify. Host-side implementation in the container repo will complete the pipeline.

Summary:

  • Add gRPC protocol definitions for filesystem event notifications
  • Implement guest-side event handler that generates Linux inotify events
  • Add CLI testing tool (cctl fsnotify) and integration test infrastructure

@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch from f89a058 to 128421e Compare September 17, 2025 22:35
@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch from 128421e to 816c698 Compare September 17, 2025 23:14
@dcantah
Copy link
Member

dcantah commented Sep 19, 2025

@realrajaryan Can you take a peek at the CI fail, it's for the new test added

@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch 4 times, most recently from b33caa9 to 07a7db3 Compare October 2, 2025 05:49
Copy link
Contributor

@jglogan jglogan left a comment

Choose a reason for hiding this comment

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

Let's get the concurrency working so that it's not @unchecked. See Danny's suggestion about using NIO for the socket communication.

@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch from 11e1720 to eb651c5 Compare October 9, 2025 00:07
@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch from a99b69b to d7001e6 Compare October 13, 2025 22:45
Copy link
Contributor

@jglogan jglogan left a comment

Choose a reason for hiding this comment

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

Initial comments - need to review about three more files...

responseStream: GRPCAsyncResponseStreamWriter<Com_Apple_Containerization_Sandbox_V3_NotifyFileSystemEventResponse>,
context: GRPC.GRPCAsyncServerCallContext
) async throws {
for try await request in requestStream {
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe an optimization for later - read the stream into an array and send the entire batch to the worker?

Might be best to look at the end-to-end path at that point and work out what's most efficient.

Copy link
Contributor

Choose a reason for hiding this comment

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

(doesn't block merge)

@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch 2 times, most recently from ce1df86 to 5070a02 Compare October 23, 2025 21:54
@realrajaryan realrajaryan force-pushed the users/realrajaryan/fsnotify branch from f51668d to 4c3353f Compare October 27, 2025 21:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants