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

Summary

By now, I hope I have proved to you that you can write reactive applications using core.async. It's an extremely powerful and flexible concurrency model with a rich API. If you can design your solution in terms of queues, it is more than likely that core.async is the tool you want to reach for.

This version of the stock market application is shorter and simpler than the version that uses only the standard Java API we developed earlier in this book in Chapter 3, Asynchronous Programming and Networking. For instance, we didn't have to worry about thread pools. On the other hand, it feels like it is a little more complex than the version we implemented using Reactive Extensions in Chapter 3, Asynchronous Programming and Networking.

This is because core.async operates at a lower level of abstraction when compared to other frameworks. This became especially obvious in our application, as we had to worry about creating broadcasting channels, go loops, and so on—all of which can be considered incidental complexity, and not directly related to the problem at hand.

core.async does, however, provide an excellent foundation for building our own CES abstractions. This is what we will be exploring in the next chapter, when we create our own framework using core.async as a foundation.

主站蜘蛛池模板: 沙雅县| 华亭县| 南陵县| 云和县| 大兴区| 文昌市| 格尔木市| 邻水| 景谷| 梅州市| 襄汾县| 平阴县| 宜君县| 台北县| 乌拉特前旗| 贵州省| 汽车| 辽阳县| 阜宁县| 山东省| 满城县| 桦川县| 永安市| 喜德县| 花垣县| 嘉祥县| 商河县| 佛学| 凤翔县| 济源市| 虎林市| 乌海市| 中西区| 甘泉县| 五莲县| 历史| 汉源县| 金湖县| 横峰县| 娄烦县| 宜君县|