Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-13 Thread James Abley
On Thursday, 13 July 2017 04:56:25 UTC+1, Ian Lance Taylor wrote: > > On Wed, Jul 12, 2017 at 8:56 AM, James Abley > wrote: > > > > Labels for clarity: > > > > 1. goroutine 1 spawns goroutine 2 to read from Oregon, and spawns > goroutine > > 3 to read from Virginia. > > 2. goroutine 1 cal

Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-12 Thread Ian Lance Taylor
On Wed, Jul 12, 2017 at 8:56 AM, James Abley wrote: > > Labels for clarity: > > 1. goroutine 1 spawns goroutine 2 to read from Oregon, and spawns goroutine > 3 to read from Virginia. > 2. goroutine 1 calls waitForSearchCompletion and enters the select. Nothing > can proceed, so that select blocks.

Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-12 Thread James Abley
On Wednesday, 12 July 2017 13:57:16 UTC+1, Ian Lance Taylor wrote: > > On Wed, Jul 12, 2017 at 12:28 AM, > > wrote: > > > > On Wednesday, 12 July 2017 04:44:43 UTC+1, Ian Lance Taylor wrote: > >> > >> On Tue, Jul 11, 2017 at 12:27 PM, wrote: > >> > > >> > This caught me out recently; th

Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-12 Thread Ian Lance Taylor
On Wed, Jul 12, 2017 at 12:28 AM, wrote: > > On Wednesday, 12 July 2017 04:44:43 UTC+1, Ian Lance Taylor wrote: >> >> On Tue, Jul 11, 2017 at 12:27 PM, wrote: >> > >> > This caught me out recently; there's definitely a gap in my >> > understanding as >> > to how select works. Maybe it's caught

Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-12 Thread james . abley
On Wednesday, 12 July 2017 04:44:43 UTC+1, Ian Lance Taylor wrote: > > On Tue, Jul 11, 2017 at 12:27 PM, > > wrote: > > > > This caught me out recently; there's definitely a gap in my > understanding as > > to how select works. Maybe it's caught other people out too? > > > > For one of my

Re: [go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-11 Thread Ian Lance Taylor
On Tue, Jul 11, 2017 at 12:27 PM, wrote: > > This caught me out recently; there's definitely a gap in my understanding as > to how select works. Maybe it's caught other people out too? > > For one of my clients, I'd written an application that would try to read > data from a backend. There were m

[go-nuts] Different behaviour in select when using SendStmt versus default CommCase

2017-07-11 Thread james . abley
This caught me out recently; there's definitely a gap in my understanding as to how select works. Maybe it's caught other people out too? For one of my clients, I'd written an application that would try to read data from a backend. There were multiple instances of this backend (say one in Orego