pkg icon indicating copy to clipboard operation
pkg copied to clipboard

feat: use sync.Map instead of custom lock

Open crenshaw-dev opened this issue 11 months ago • 1 comments

keyLock just happens to fit one of the two recommended use cases for sync.Map: one where the map only grows.

I understand this trades memory for less lock contention. I expect our current use cases will see virtually no difference.

crenshaw-dev avatar Mar 04 '25 18:03 crenshaw-dev

Gonna close this for now, because I haven't analyzed the different projects' different uses of this package. It's possible some of the use cases aren't appropriate for a sync map. Can revisit later.

crenshaw-dev avatar Mar 28 '25 14:03 crenshaw-dev