Now that we have the WatchedFile class to track the state of a file as we know it, I propose to create a WatchedFileStore class in place of the @files hash.
The WatchedFileStore
- should be the responsibility of Watch not Tail.
- should replace the sincedb Hash
- should be loaded from an existing sincedb file with backward compatibility.
- should, when loading, verify that the file can be stated before adding a new watched_file instance.
- should saved in place of the sincedb file
- should be backed by a Hash
- have entries keyed on path and inode but not device
- should find all entries with the same path
- should find all entries with the same inode
Now that we have the WatchedFile class to track the state of a file as we know it, I propose to create a WatchedFileStore class in place of the
@fileshash.The WatchedFileStore