From 5afee5d0c7dfdcdb322d642a775ace5e57d4562f Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Tue, 26 Jul 2016 11:39:21 +0100 Subject: [PATCH] Created Design: Concurrent editing handling (markdown) --- Design:-Concurrent-editing-handling.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Design:-Concurrent-editing-handling.md diff --git a/Design:-Concurrent-editing-handling.md b/Design:-Concurrent-editing-handling.md new file mode 100644 index 0000000..2dbb9f6 --- /dev/null +++ b/Design:-Concurrent-editing-handling.md @@ -0,0 +1,17 @@ +Target: 15 + beyond + +If you have the editor open and new flows are deployed from another location (ie a co-worker deploys their changes), when you deploy your changes the previous changes are lost. + +The editor should: + +- warn if the flows are open in another editor (use number of comms connections to determine) +- notify when new flows are deployed (inc when done via the flow add/remove api) +- (longer term) automatically load the new flow into the editor - with a scheme for resolving conflicts + +With the addition of [Version Control](https://github.com/node-red/node-red/wiki/Design%3A-Version-Control) of flows, each version of flow will now have an associated ID. + +The editor will know the ID of flows it loaded. When it does a deploy, it will include that ID in the request. If the ID does not match the ID of the flows in the runtime, the request will be rejected with a well-defined response. The editor can then prompt the user to confirm the deploy. If the user confirms, the http POST is resent with an additional flag set confirm the action. + +**TODO** + - define the changes to the `/flows` api to support this flow + - design UI dialog for the prompt \ No newline at end of file