This is less of a feature request for node-red itself since IMO it does not really fit into the core concept of noder-ed. This is more of a thing I would like and would work on, but I would like some feedback on it to know:
How reasonably implementable is the Idea for a singular individual? (I would want to work on it as a side project)
Does the Idea extend the usefulness/ease of use for users / is there already something similar which I just didn't come across?
General feedback on the idea, would you think it's useful or might even use it?
The Problem: node-red only runs on a singular machine, so operating across multiple devices is unintuitive/harder than it has to be.
I've been thinking about modifying node-red to let it function as a distributed system. What I mean by that is probably best described in some sort of a User Story. (node-red+ refers to the modified node-red software)
The user has multiple devices (let's say a phone and a desktop pc), which he wants to automate and potentially work together. The user has the software installed on both pc and phone. Phone and Computer, therefore, form a collection of "clients" (devices that run node-red+ as part of the same distributed system), and Flows are shared between them. To edit the flows, the User can utilize the node-red(+) editor like usual, and changes get propagated to all clients. node-red+ also provides messaging, so the clients can communicate with each other/the backend.
The Main Idea: The User can specify a set of clients for each node so that the node will get executed on the specified clients. (some nodes could even be restricted to certain clients, depending on the device the client runs on)
The coordination needed to pass the messages from one client to the other will be automatically handled.
The Backend provides the messaging for the clients as well as central storage for the flows and settings.
Each Client runs node-red+
- provides access to the editor
- changes to flows made in the editor get committed to the backend/propagated in the distributed system to all other clients
Building upon that Applications for major platforms could be made, that even give access to new device-specific nodes in node-red+.
(App on android could expose a node to change phone settings/wallpaper/run an app etc.)
The impact/use of the Idea:
use node-red to develop distributed event-driven applications with ease.
Flows that include processing in several clients are visible(and editable) in one UI, as a whole.
Would reduce the barrier of entry for people wanting to automate things across devices, control their smart home, etc.
Another Example: User wants to synchronize the clipboard of two devices. Say phone and laptop. So in the node-red+ editor, he takes an event node that triggers every time the clipboard of the device changes (let's say the message payload is the content of the clipboard). He routes that to a node that sets the clipboard. He specifies that the event trigger should run on the first device, while the set clipboard should run on the second. Then he does that again for the other direction and he has set up clipboard sync in a couple of minutes.
The Backend should be adjustable in what kind of messaging it provides and how it stores the data.
Messaging should probably be able to work everywhere, and not only when connected to some Network.