Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why use Mono? [closed]

What are the main benefits of using Mono over Java (or any other "free" or Linux-friendly language/runtime)?

Mono will always trail behind the latest developments in the .NET framework, why would you want to use Mono over another traditional open-source language/framework (Java)?

EDIT: Like someone mentioned below, I guess the root question is, why would you want to use .NET on the Linux platform?

like image 400
Andy White Avatar asked Feb 22 '09 00:02

Andy White


People also ask

What is the use of mono defer?

when you run Mono. just() it creates immediately an Observable(Mono)and reuses it but when you use defer it doesn't create it immediately it creates a new Observable in every subscribe.

What is the difference between flux and Mono?

A Flux object represents a reactive sequence of 0.. N items, while a Mono object represents a single-value-or-empty (0..1) result. This distinction carries a bit of semantic information into the type, indicating the rough cardinality of the asynchronous processing.

What is flatMapMany?

The flatMapMany is a generic operator on Mono that returns a Publisher. Let's apply flatMapManyto our solution: private <T> Flux<T> monoTofluxUsingFlatMapMany(Mono<List<T>> monoList) { return monoList .flatMapMany(Flux::fromIterable) .log(); }

What is Monoflatmap?

Mono#flatMap takes a Function that transforms a value into another Mono . That Mono could represent some asynchronous processing, like an HTTP request. On the other hand, Mono#map takes a Function that transforms a value of type T into another value, of type R .


1 Answers

The answer is pretty obvious: because you want to use .Net on Linux.

This of course begs the question (which I think is really what you're getting at): why would you want to use .Net on Linux (over Java)?

Lots of reasons:

  • Common code between your server and, say, a WPF or Winforms app;
  • Use of a particular .Net language, like F#;
  • Language features that aren't in Java (closures, operator overloading, partial classes, runtime generics, indexers, delegates, LINQ, var types, etc etc etc);
  • Your skills or those of your team are already in C#;
  • etc.
like image 198
cletus Avatar answered Sep 19 '22 15:09

cletus