`gen_server` is an abstraction over the a client sending a `request` that a server services to produce a `response` to be sent to the client.
The `gen_server` implementation takes care of things like timeouts, servers terminating before a response is produced as well as maintaining the server state.
I'll add to this that the "abstraction" component of this description is key and the use-case for a gen_server is far more broad than what you might expect in say a networking or web context.
You would use them for instance when you need to group behavioral units with a defined interface, even if you don't require any explicit networking.
This is a bit reductive and wrong in some ways but think of gen_server modules and instances as "sort of" like classes/objects. You "send messages/requests" instead of "calling methods," but the spirit is essentially the same -- it's a way of modeling the world with code
The most dangerous thing about Capitalism is imho its universal equivalence, its ability to make us covert everything into a monetary value.
In other words, it’s just like a programming language where everything can be implicitly converted to a given top type.
In the progress we certainly made over the last century or so, we certainly also lost other things whose value is not representable in our modern value system.
Yes, but you don’t end up with different glyphs. Arabic script has letter shaping, that means a letter can have up to 4 shapes based on its position within the word. If you chop off the last letter, the previous one which used to have a “middle” position shape suddenly changes into “terminal” position shape.
I'm thinking even bog-standard European umlauts, cedillas, etc go multi-byte in Unicode? (Take a string of ÅÄÖåäöÜü and chop it off at various byte limits and see.)
The underlying problem is lack of isolation, and this is an area where the Erlang process model shines: processes are fully isolated and you can send a signal externally to terminate any process you want.
No global GC. Each erlang process does its own GC, and the GC only happens when the process runs out of space (ie. the heap and stack meet).
You can for example configure a process to have enough initial memory so as not to ever run into GC, this is especially useful if you have a process that does a specific task before terminating. Once terminated the entire process memory is reclaimed.
There is no free lunch in software - the tradeoff is binary serialization and/or data copying over simple function calls. The same goes for GC - for efficient GC, it has to come with quite involved state which has additional cost of spawning. At this point, might use bump allocator, or an arena. Either way, Gen0 (it's a generational GC) in .NET acts like one, STW pauses can be sub-millisecond and are pretty much non-issue, given that you don't even need to allocate that often compared to many other high-level languages.
Vala is very much used among other things by Frida.
I have been involved with Vala in it’s early day and some hardcore GObject/C users never quite liked the C code that Vala generated although it was perfectly valid and exposed a very clean C header to interface with it.
I think that Vala is a really great tool for building applications that make use of Glib/GObject. For example Gtk applications, but also GStreamer and DBus applications.