Flagsmith / flagsmith-dotnet-client

.NET Standard Client for Flagsmith. Ship features with confidence using feature flags and remote config. Host yourself or use our hosted version at https://www.flagsmith.com/
https://www.flagsmith.com/
BSD 3-Clause "New" or "Revised" License
19 stars 15 forks source link

Caching does not implement a max size #101

Open matthewelwell opened 5 months ago

matthewelwell commented 5 months ago

Currently the caching implementation does not implement a max size. We should add a configurable limit to the size of the cache to ensure that there are no memory concerns when using the cache implementation in the client.

matthewelwell commented 5 months ago

@JFCote @vpetrusevici - mentioning you both here as I know you both worked on the caching implementation. I'm keen to get your thoughts here on whether there's a reason that a max size was not implemented originally.

JFCote commented 5 months ago

@matthewelwell As far as I remember, I think I didn't add this kind of limitation as it was a "first draft" and "best effort" kind of thing.

I definitely think it would be a great improvement to prevent very big users to bust the memory of their applications.

matthewelwell commented 5 months ago

Understood - thanks @JFCote.