- Hands-On Reactive Programming in Spring 5
- Oleh Dokuka Igor Lozynskyi
- 209字
- 2021-07-23 16:36:31
Adding Reactor to the project
Here, we assume that the reader is already familiar with the Reactive Streams specification. If not, it is briefly described in the previous chapter. The Reactive Streams specification is essential in the current context, because Project Reactor is built on top of it and org.reactivestreams:reactive-streams is the only mandatory dependency of Project Reactor.
Adding Project Reactor as a dependency to our application is as simple as adding the following dependency to the build.gradle file:
compile("io.projectreactor:reactor-core:3.2.0.RELEASE")
At the time of writing, the latest version of the library is 3.2.0.RELEASE. This version is also used in Spring Framework 5.1.
It is also often worth adding the following dependency, as this provides the necessary toolset for testing reactive code, which, obviously, we also need to cover with unit tests:
testCompile("io.projectreactor:reactor-test:3.2.0.RELEASE")
In this chapter, we are going to use some simple testing techniques for Reactive Streams. Additionally, Chapter 9, Testing the Reactive Application, covers topics regarding reactive code testing in more detail.
Now that we have Reactor in our application classpath, we are ready to experiment with Reactor's reactive types and operators.
- CorelDRAW X6 中文版圖形設計實戰從入門到精通
- EDA技術與VHDL編程
- GPS/GNSS原理與應用(第3版)
- SEO 20日
- Spring Boot 2.0 Projects
- 萬物互聯:蜂窩物聯網組網技術詳解
- Learning QGIS 2.0
- 局域網組建、管理與維護項目教程(Windows Server 2003)
- 物聯網時代
- CCNP TSHOOT(642-832)認證考試指南
- 2小時讀懂物聯網
- Bonita Open Solution 5.x Essentials
- Building Web Applications with ArcGIS
- Learning Windows 8 Game Development
- Dart Cookbook