There are two kinds of Single Page Application design: either you build on top of REST resources or you embrace backend-for-frontend style (using GraphQL or not).
The former is very common but has a lot of drawbacks: it may be very chatty and you give a lot of responsibilities to the frontend. The latter solves both of these problems but you lose the nice incremental loading of data and the latency of a request is now the latency of the slowest piece of data.
The slower the resources you need to work with, the worse the situation is. Now, let's say that in addition, you want the application to be reactive and display data as they are available. Adding some polling would just make the problem worse.
So we tried to engineer a solution to have the best of both worlds: short latency, incremental loading, updates without polling, coarse grain resources, and cancellation. We'll show you how to model your backend with ZStream and mapAccumZIO to implement a finite state machine and deliver these promises while keeping a clean and maintainable codebase.
Slides : drive.google.com/file/d/12Com...
#MapAccum
Негізгі бет Ғылым және технология L. Duzan, M. Baechler - When stateless APIs are not enough: deep dive into a reactive backend design
Пікірлер