Skip to content

fix(storages): properly close connections and cleanup instance cache in Reset#53

Merged
darkweak merged 1 commit intodarkweak:mainfrom
everyx:fix/persistent-caching
Mar 13, 2026
Merged

fix(storages): properly close connections and cleanup instance cache in Reset#53
darkweak merged 1 commit intodarkweak:mainfrom
everyx:fix/persistent-caching

Conversation

@everyx
Copy link
Contributor

@everyx everyx commented Mar 4, 2026

  • Badger, Nuts, Otter: delete only current instance from cache instead of all
  • Badger, Nuts: close DB connection before removing from cache
  • Redis: call close() instead of Flushdb()
  • Add instanceKey field to Nuts and Otter for precise cache cleanup

This ensures proper cleanup on Caddy reload without data loss.

Relates:

@darkweak
Copy link
Owner

Hello @everyx can you fix the lint issues?

@everyx everyx force-pushed the fix/persistent-caching branch from 7bc2d2c to 2d75bd8 Compare March 13, 2026 00:40
…in Reset

- Badger, Nuts, Otter: delete only current instance from cache instead of all
- Badger, Nuts: close DB connection before removing from cache
- Redis: call close() instead of Flushdb()
- Add instanceKey field to Nuts and Otter for precise cache cleanup

This ensures proper cleanup on Caddy reload without data loss.

Relates:
- darkweak/souin#723
- darkweak/souin#722
@everyx
Copy link
Contributor Author

everyx commented Mar 13, 2026

@darkweak Done.

@everyx everyx force-pushed the fix/persistent-caching branch from 2d75bd8 to f4a2e22 Compare March 13, 2026 00:49
@darkweak darkweak merged commit 5236c8e into darkweak:main Mar 13, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants