Updated Filer Change Data Capture (markdown)

Chris Lu 2020-11-13 13:33:53 -08:00
parent caac88274c
commit 8143967624

@ -2,6 +2,8 @@ Is it too much a dream to have something similar to [inotify](https://man7.org/l
Actually SeaweedFS can give you more!
# Example
Here is an example, in Java:
https://github.com/chrislusf/seaweedfs/blob/master/other/java/examples/src/main/java/com/seaweedfs/examples/WatchFiles.java
@ -21,6 +23,18 @@ Basically there are four types of events to handle:
| Delete | exists | null | exists | equal to Directory |
| Rename | exists | exists | exists | not equal to Directory |
# Other Languages
This is based on Filer gRPC API. You should be able to easily implement it in your own language.
https://github.com/chrislusf/seaweedfs/blob/master/weed/pb/filer.proto#L52
https://github.com/chrislusf/seaweedfs/blob/master/weed/pb/filer.proto#L52
# Possible Use Cases
This is event processing for files. The possible use cases are all up to your imagination.
* Detect new image or video files. Add versions with different resolutions.
* A **distributed configuration distribution**: stores configuration files under a folder. Detect the configuration changes and reload.
* A **job queue**: upload files to a folder, and processing new files as soon as possible, and delete the processed files.
* Do-it-yourself **Data Replication or Backup**.