Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Jordan West
I lean towards the documentation approach vs complicating the implementation. For me personally: I regularly use shell commands to operate on snapshots. That includes listing them. I probably should use nodetool for it all instead though. Jordan On Fri, Aug 9, 2024 at 08:09 Štefan Miklošovič wr

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Štefan Miklošovič
I understand and agree. It is just that it would be cool if we avoided the situation when there is a figurative ABC company which has these "bash scripts removing snapshots from cron by rm -rf every second Sunday at 3:00 am" because "that was their workflow for ages". I am particularly sensitive t

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Bowen Song via dev
If we have the documentation in place, we can then consider the cache to be the master copy of metadata, and rely on it to be always accurate and up to date. If someone deletes the snapshot files from filesystem, they can't complain about Cassandra stopped working correctly - which is the same

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Štefan Miklošovič
It is also worth to say that there are plans to include more snapshot metadata in the future, for example, it would be nice if we had a way to verify the consistency of a snapshot. That leads to a manifest.json file which would contain checksums to each file of a snapshot and similar. The result of

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Štefan Miklošovič
We could indeed do that. Does your suggestion mean that there should not be a problem with caching it all once explicitly stated like that? On Fri, Aug 9, 2024 at 12:01 PM Bowen Song via dev wrote: > Has anyone considered simply updating the documentation saying this? > > "Removing the snapshot

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Bowen Song via dev
Has anyone considered simply updating the documentation saying this? "Removing the snapshot files directly from the filesystem may break things. Always use the `nodetool` command or JMX to remove snapshots." On 09/08/2024 09:18, Štefan Miklošovič wrote: If we consider caching it all to be too

Re: [DISCUSS] inotify for detection of manually removed snapshots

2024-08-09 Thread Štefan Miklošovič
If we consider caching it all to be too much, we might probably make caching an option an admin would need to opt-in into? There might be a flag in cassandra.yaml, once enabled, it would be in memory, otherwise it would just load it as it was so people can decide if caching is enough for them or th