swithek

Results 9 issues of swithek

It should iterate over all cache items and pass each of them into a func that is provided as a parameter: ```go func (c *Cache[K, V]) Range(fn func(*Item[K, V]) bool)...

enhancement

It should return a `uint64` that determines how many times an item has been updated. This method may be useful in situations when a task's execution depends on whether the...

enhancement

It would be nice to have a method that would accept a function and execute it with a new global transaction mutex locked: ```go func (c *Cache[K, V]) Tx(fn func(*Tx[K,...

enhancement

- [ ] Rename: - [ ] Manager.Defaults() -> Manager.reset() (?) - [ ] Manager.Auth() -> Manager.Authenticate()/Manager.Private() (?) - [ ] Manager.Init(...) -> Manager.Create(...) Session (?) - [ ] Manager.Revoke()...

feature

This problem can be reproduced with the following code: ```go package main import ( "fmt" json "github.com/goccy/go-json" ) type CustomString string type EmbedStruct struct { CustomString1 CustomString `json:"custom_string1,omitempty"` // causes...

bug

https://github.com/jellydator/ttlcache/issues/83#issuecomment-1906428459 > [T]his particular aspect of the library is still less than ideal. Having a separate type for this could be a solution we've been looking, but I'm a bit...

enhancement

It would register a func that would be called when an existing item is overwritten/updated.

enhancement