I think it is easier to just hash and shard the data set the lock is protecting - ie a lock per shard. 

On Mar 13, 2025, at 10:52 PM, atomly <ato...@gmail.com> wrote:


On Thu, Mar 13, 2025 at 20:29 Jason E. Aten <j.e.a...@gmail.com> wrote:
Is there a common way to do sharded read-write locks now?
I mean faster than sync.RWMutex.

I tried https://github.com/jonhoo/drwmutex which is from quite a
while back...

Have you read the original thread that spawned this, you might find it pretty informative if not:

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/golang-nuts/CAA_Y42wUOYwnaO0ZDyC2USCMsZqVQXGck9q%2Bfb8inWoxG01brA%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/golang-nuts/3F166893-C69B-40D2-AA5A-1934B7986AD4%40ix.netcom.com.

Reply via email to