News for hackers. Stuff that matters.
Re:Another go at Go failed by ansible on Wednesday January 08, 2014 @09:53AM (#7023787)
With Go, the programmer will typically not be using data structures that are concurrently accessed from multiple goroutines. It is considered more idiomatic to have one goroutine controlling a given data structure, and have the others communicate with it via channels.
Re:Another go at Go failed by jamra on Wednesday January 08, 2014 @12:17PM (#7024826)
That is only one way of doing things. Even though channels facilitate that method, it is not unidiomatic to not use them.

Channels are a way of queueing work, which is great for many use cases.

You can use mutexes and shared memory if your situation calls for it. For example, if I am doing a graph traversal concurrently, I can use channels to send the work to many listening threads as I traverse that graph synchronously.

If for some reason, I need to update that graph's representation asynchronously, I may need to use mutexes to lock the graph since the graph is now shared memory.

Re:Another go at Go failed by pron on Wednesday January 08, 2014 @11:07AM (#7024325)
That approach has vastly different performance characteristics.