eventfs
eventfs copied to clipboard
Per-directory maximum size
Allow the directory owner to write a number to the file op_max_size or the like to limit how many files a directory may contain. Any attempts to create a file in the directory after this threshold has exceeded should fail with EDQUOT. To discover when there's space, senders would open an inotify(2) handle on the directory and watch for files to be removed.
We already have this in the static config file, as of 48a82c49179a0fa459da6fa4b7e1fdb7506ae166.
Actually, don't use a file. Use an xattr, like user.eventfs_max_files, that can be set on the directory.