You are over complicating things. Start with simple code based on Ian’s.
Still, I think you might be misunderstanding the tug between priority and starvation. It depends on the frequency and latency of events processing. There is no structure/language that can address this. You either drop or you stall - and often only drop is appropriate for safety critical systems. > On May 5, 2021, at 11:59 AM, Øyvind Teig <oyvind.t...@teigfam.net> wrote: > > Thanks, rog! (Blush.. I should have seen it and not nagged about it..) > Sorry. Øyvind > >> tirsdag 4. mai 2021 kl. 13:13:51 UTC+2 skrev rog: >>> On Mon, 3 May 2021 at 20:24, Øyvind Teig <oyvin...@teigfam.net> wrote: >>> I see that, which is great. But I still don't understand why >>> https://go2goplay.golang.org/p/S_5WFkpqMP_H (By rog, 29Apr2021 23:52:05) >>> seems not to print "Client 2". >> >> That's because to try to emphasise the arbitrariness of the producers (and >> to check that the consuming code was working as intended), the producing >> code deliberately doesn't produce any values on channel 2. Instead, it >> sleeps for a second and produces a "late arrival" message. >> >> It's trivial to take out the if statement and show that it works as you'd >> expect: https://go2goplay.golang.org/p/TjgiOmZtQhR > > -- > 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 on the web visit > https://groups.google.com/d/msgid/golang-nuts/47600a6c-6783-4cfc-beca-06be2ae48a3dn%40googlegroups.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 on the web visit https://groups.google.com/d/msgid/golang-nuts/1502F3E6-E35F-40D4-8770-A6809EDB7105%40ix.netcom.com.