In object orientated programming, there is the observer pattern and there is reactive style.
But how do you group a set of objects and run the equivalent of epoll() or select() on it when the objects state changes?
I kind of want to group a set of objects together and define a relation between them and tell them to maintain some invariant.
For example, if I wanted to implement multithreading and associate a 500 sockets per kernel thread and multiplex 1000 clients to each thread. And recv for receive threads and send for send threads. And have a pipeline of steps to process incoming messages and outgoing messages. This is a lot of code.
If I could just create a thread object and associate it with a list of sockets and tell them to send messages to eachother when to run what. Then I could use OOP to manage files, sockets, containers. Kubernetes is not really OOP but it does manage objects.
I feel the abstraction doesn't exist yet. What comes to mind is the Knuth shell script versus a low level program.
https://matt-rickard.com/instinct-and-culture
A shell pipeline is easily 1000s of lines in C.
I feel the interface to the operating system should help you write less code.
I want the messages sent between objects to be capable of reorganising the arrangement of the relations between objects themselves.