Summary
Behaviour of fasteners.InterProcessLock is pretty weird: class creates a lockfile by provided path, if it doesn't exist, but not manage to remove it after lock is released.
It may lead to uncontrolled lockfiles spam in /tmp folder just because libcloud local driver is not removing this lockfile either.
Detailed Information
This issue encountered in cassandra-medusa v0.15 and lower, which was using apache-libcloud<3.4.0,>=3.3.0 as a dependency.
Please see thelastpickle/cassandra-medusa#528 for more details.
Seems like the lightweight fix is to run
with contextlib.suppress(FileNotFoundError):
os.remove(filename)
just right in the exit method.
Summary
Behaviour of fasteners.InterProcessLock is pretty weird: class creates a lockfile by provided path, if it doesn't exist, but not manage to remove it after lock is released.
It may lead to uncontrolled lockfiles spam in
/tmpfolder just because libcloud local driver is not removing this lockfile either.Detailed Information
This issue encountered in cassandra-medusa
v0.15and lower, which was usingapache-libcloud<3.4.0,>=3.3.0as a dependency.Please see thelastpickle/cassandra-medusa#528 for more details.
Seems like the lightweight fix is to run
just right in the exit method.