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

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.

主站蜘蛛池模板: 自贡市| 玛多县| 咸阳市| 随州市| 衡水市| 阳信县| 武义县| 永登县| 家居| 青神县| 信丰县| 兴城市| 湄潭县| 嘉荫县| 永福县| 沙雅县| 罗江县| 安阳市| 清镇市| 青浦区| 基隆市| 武夷山市| 雅安市| 双峰县| 临桂县| 齐河县| 黎川县| 余江县| 茶陵县| 同心县| 客服| 通山县| 延寿县| 隆林| 清水县| 东安县| 万载县| 泽普县| 乐昌市| 荣成市| 丰城市|