IssueRaiser

Rework engine to a process based architecture

### Is your feature request related to a problem? Please describe. At the moment, most of the worlds, UI, rendering and everything runs within a single process. While this keeps things simpler, it presents major issues: - A single world crashing or freezing takes down the entire process with it, requiring user to restart the whole app and lose app - Resources are shared across all open worlds. If a world is using a lot of RAM or CPU, it is difficult to stop it without losing other worlds and restarting the whole app - A security exploit in a single world can potentially gain access to the entire app - including more sensitive data in the userspace ### Describe the solution you'd like Our goal is to switch to a process based architecture similar to the one used in web browsers like Chrome or Firefox. Instead of a single process, there will be one main "broker" process, which has privileged access to system resources. The actual simulation (and possibly rendering) will be handled through additional processes. Opening a new world/session will spin up a separate process, that will be responsible for simulating and calculating that world and communicating with the broker process through an IPC system. These processes can also be sandboxed using OS primitives, which will restrict how much can be accessed in case of an exploit in a world. Similarly if particular world freezes/crashes, only the particular world will stop moving/updating for the user. However their userspace (

Posted by Frooxius on Nov 15, 2023, 8:23 PM

Tags

Related issues

Raise real-world problems, find people facing the same issue, and discuss solutions.2,000 issues0 comments

reliability (SaaS)

Rework engine to a process based architecture

FrooxiusNov 15, 2023, 8:23 PM

### Is your feature request related to a problem? Please describe. At the moment, most of the worlds, UI, rendering and everything runs within a single process. While this keeps things simpler, it presents major issues: - A single world crashing or freezing takes down the entire process with it, requiring user to restart the whole app and lose app - Resources are shared across all open worlds. If a world is using a lot of RAM or CPU, it is difficult to stop it without losing other worlds and restarting the whole app - A security exploit in a single world can potentially gain access to the entire app - including more sensitive data in the userspace ### Describe the solution you'd like Our goal is to switch to a process based architecture similar to the one used in web browsers like Chrome or Firefox. Instead of a single process, there will be one main "broker" process, which has privileged access to system resources. The actual simulation (and possibly rendering) will be handled through additional processes. Opening a new world/session will spin up a separate process, that will be responsible for simulating and calculating that world and communicating with the broker process through an IPC system. These processes can also be sandboxed using OS primitives, which will restrict how much can be accessed in case of an exploit in a world. Similarly if particular world freezes/crashes, only the particular world will stop moving/updating for the user. However their userspace (

Comments (0)

No comments yet. Start the discussion.

Comment on this issue