3 ms·
> The rationale seems to be that users of the data types can choose whether to make them safe for concurrent use or not depending on the use case. Also that fo
by masklinn 7y ago
> The rationale seems to be that users of the data types can choose whether to make them safe for concurrent use or not depending on the use case.
Also that for most uses a concurrent map is way overkill, and a thread-safe one is both costly and basically useless (hence the Java folks not keeping the thread-safety when migrating from Hashtable to HashMap).
On the other hand they're kinda shit given how awful non-builtin data structures are in Go, and how easy it is to "leak" maps between goroutines.
- vips7L 7y agoHashtable used a giant mutex when locking.. it was just slow. Especially when compared to ConcurrentHashMap.