官术网_书友最值得收藏!

Channels and Messages

In Chapter 2, Understanding Goroutines, we looked at how goroutines work, how to use them in a concurrent fashion, and some of the common mistakes that might occur. They were simple to use and reason about, but they were limited because they are able to spawn other goroutines and wait on system calls. In reality, goroutines are more capable than what was shown in the previous chapter, and to uncover their full potential we need to understand how to use channels, which is the aim of the current chapter. Here, we will look at the following topics:

  • Controlling parallelism
  • Channels and data communication
  • Types of channels
  • Closing and multiplexing channels
主站蜘蛛池模板: 屏南县| 湖州市| 北碚区| 淳化县| 壤塘县| 武胜县| 青田县| 阿巴嘎旗| 新郑市| 象山县| 卢龙县| 小金县| 营口市| 新巴尔虎右旗| 如东县| 白银市| 郸城县| 涿州市| 神农架林区| 安达市| 苍溪县| 信丰县| 浦北县| 武山县| 秦安县| 明星| 陈巴尔虎旗| 孟州市| 璧山县| 峨边| 翼城县| 大邑县| 五华县| 利川市| 太康县| 绥滨县| 邢台县| 大竹县| 凤台县| 石景山区| 斗六市|