Comment by zzo38computer
1 month ago
I had thought of some similar ideas, including the similar working of proxies, and I also had the same idea of how proxies could be used (although proxies have many other uses as well, not all of which are related to security), and also network transparency (which is also implemented by using proxies; it is not a feature that the kernel knows about). A program that receives a proxy does not know if it is a proxy or not (or what it is a proxy of); it can only send/receive messages.
I also had similar idea like calling programs in the command shell, although in mine, a program cannot even return a value without being given a capability to send the result to (although there may be syntactic sugar to handle this without needing to write that explicitly), and the result will always be the same if any input it receives is the same (and in the same order); a capability is even required to determine the current date/time, etc. (One of the forks of a program file would specify the expected type of the initial message, which the command shell can use for type checking and related stuff like that.)
Their "vats" are similar to my idea of how processes might be made, but different in many ways. A process consists of memory, which may include references to capabilities, and also includes the processing state. It does not necessarily use a event loop, although it can be implemented in that way. I did not consider using promises; I am unsure if it is necessary, which it might not be.
However, my idea uses native code (with its own instruction set) rather than Guile or Scheme or Lisp, and system calls will be used for doing I/O with capabilities (and there aren't many system calls for doing other things than that). (Emulation would probably be possible (directly of the instruction set, or of the command shell and other higher-level stuff, or a combination), although I also have a different keyboard layout and other things different from existing systems.)
Also, there are more things to be considered than related there. For example, nested transactions of multiple objects at once (even if they do not necessarily know each other), multiple locking, the hypertext file system model, etc.
I also would not use JSON and would not use Unicode.
No comments yet
Contribute on Hacker News ↗