Mono. just(value) is the most primitive – once you have a value you can wrap it into a Mono and subscribers down the line will get it. Mono. defer(monoSupplier) lets you provide the whole expression that supplies the resulting Mono instance. The evaluation of this expression is deferred until somebody subscribes.
What is just method?
The just() method emits its parameter(s) as OnNext notifications, and after that, it emits an OnCompleted notification. The method allows up to nine arbitrary values (objects of the same type) to be observed through reactive means. …
What is Mono then?
thenEmpty not only returns a Mono<Void> , but it takes a Mono<Void> as a parameter. It represents a concatenation of the source completion signal then the second, empty Mono completion signal. In other words, it completes when A then B have both completed sequentially, and doesn’t emit data.