Summary
This chapter covered a lot of new topics. We're going to use all of what we just learned in the next chapter, where we'll use Unix sockets for inter-process communication and WebSocket server for a simple chat application. Most importantly, we're going to use spawning subprocesses with ProcessObservable
, PHP Streams API for Unix socket communication. We are also going to look into event loops, including use cases, where we need to share the same instance of the event loop among Unix socket streams and a WebSocket server. Then we will move on to higher-order Observables to collect statuses from multiple subprocesses, and a WebSocket server and client. PHP Streams API and higher-order Observables are, in principle, a little harder to understand at first glance, so feel free to take your time and experiment by yourself.
In the next chapter, we'll also introduce the concept of backpressure in Rx, which is a common way to avoid overloading the consumer by emitting more values that the...