diff --git a/fl0w-protocol-concept.md b/fl0w-protocol-concept.md deleted file mode 100644 index 2eb1a36..0000000 --- a/fl0w-protocol-concept.md +++ /dev/null @@ -1,81 +0,0 @@ -# fl0w - -Client 1: -
-. -- -Client 2: -
-. -└── test.py (MD5: bbf9a688d7c2447c7c3962a3aae6562e) -- -Client 3: -
-. -- -Server: -
-. -└── test.py (MD5: 354dc351e940ef48b689d4d925532053) -- - - -Client1: **Connect** -Client1: `{"sync" : []}` -Server > Client1: `{"sync" : ["test.py": {"md5" : "354dc351e940ef48b689d4d925532053"}]}` -Client1: `{"sync" : ["test.py"]}` -Server > Client1: **test.py** - - -Client2: **Connect** -Server > Client2: `{"sync" : ["test.py": {"md5" : "354dc351e940ef48b689d4d925532053"}]}` -Client2: `{"sync" : ["test.py"]}` -Client2: **deletes test.py** -Server > Client2: **test.py** - - -Client2: **Changes test.py** -Client2: `{"sync" : ["test.py" : {"md5" : "0cbcc3416544206f8789391dc6805f8e"}]}` -Client2: **test.py** -Server (Broadcast): `{"sync" : ["test.py" : {"md5" : "0cbcc3416544206f8789391dc6805f8e"}]}` -Server (Broadcast): **test.py** - -Client2: **Deletes test.py** -Client2: `{"sync" : ["test.py" : {"md5" : "0"}]}` -Server (Broadcast): `{"sync" : ["test.py" : {"md5" : "0"}]}` - -Client3: **Connect** -Server > Client3: `{"sync" : []}` -Client3: `{"sync" : []}` - -Client3: **Creates test1.py** -Client3: `{"sync" : ["test1.py" : {"md5" : "1cbcc3416544206f8789391dc6805f8e"}]}` -Client3: **test1.py** -Server (Broadcast): `{"sync" : ["test1.py" : {"md5" : "1cbcc3416544206f8789391dc6805f8e"}]}` -Server (Broadcast): **test1.py** - -Client3: **Creates test2.py** -Client3: `{"sync" : ["test2.py" : {"md5" : "2cbcc3416544206f8789391dc6805f8e"}]}` -Client3: **test2.py** -Server (Broadcast): `{"sync" : ["test2.py" : {"md5" : "2cbcc3416544206f8789391dc6805f8e"}]}` -Server (Broadcast): **test2.py** - -Client3: **Creates test3.py** -Client3: `{"sync" : ["test3.py" : {"md5" : "3cbcc3416544206f8789391dc6805f8e"}]}` -Client3: **test3.py** -Server (Broadcast): `{"sync" : ["test3.py" : {"md5" : "3cbcc3416544206f8789391dc6805f8e"}]}` -Server (Broadcast): **test3.py** - -Client1: **Deletes test2.py** -Client1: `{"sync" : ["test2.py" : {"md5" : "0"}]}` -Server (Broadcast): `{"sync" : ["test2.py" : {"md5" : "0"}]}` - -Client2: **Changes test3.py** -Client2: `{"sync" : ["test3.py" : {"md5" : "7cbcc3416544206f8789391dc6805f8e"}]}` -Client2: **test3.py** -Server (Broadcast): `{"sync" : ["test3.py" : {"md5" : "7cbcc3416544206f8789391dc6805f8e"}]}` -Server (Broadcast): **test3.py** diff --git a/sync-protocol-concept.md b/sync-protocol-concept.md new file mode 100644 index 0000000..ba3c6ce --- /dev/null +++ b/sync-protocol-concept.md @@ -0,0 +1,81 @@ +# fl0w + +Client 1: +
+. ++ +Client 2: +
+. +└── test.py (MD5: bbf9a688d7c2447c7c3962a3aae6562e) ++ +Client 3: +
+. ++ +Server: +
+. +└── test.py (MD5: 354dc351e940ef48b689d4d925532053) ++ + + +Client1: **Connect** +Client1: `{"sync" : []}` +Server > Client1: `{"sync" : {"test.py" : "354dc351e940ef48b689d4d925532053"}}` +Client1: `{"sync" : ["test.py"]}` +Server > Client1: **test.py** + + +Client2: **Connect** +Server > Client2: `{"sync" : {"test.py": "354dc351e940ef48b689d4d925532053"}}` +Client2: `{"sync" : ["test.py"]}` +Client2: **deletes test.py** +Server > Client2: **test.py** + + +Client2: **Changes test.py** +Client2: `{"sync" : {"test.py" : "0cbcc3416544206f8789391dc6805f8e"}}` +Client2: **test.py** +Server (Broadcast): `{"sync" : {"test.py" : "0cbcc3416544206f8789391dc6805f8e"}}` +Server (Broadcast): **test.py** + +Client2: **Deletes test.py** +Client2: `{"sync" : {"test.py" : "0"}}` +Server (Broadcast): `{"sync" : {"test.py" : "0"}}` + +Client3: **Connect** +Server > Client3: `{"sync" : {}}` +Client3: `{"sync" : []}` + +Client3: **Creates test1.py** +Client3: `{"sync" : {"test1.py" : "1cbcc3416544206f8789391dc6805f8e"}}` +Client3: **test1.py** +Server (Broadcast): `{"sync" : {"test1.py" : "1cbcc3416544206f8789391dc6805f8e"}}` +Server (Broadcast): **test1.py** + +Client3: **Creates test2.py** +Client3: `{"sync" : {"test2.py" : "2cbcc3416544206f8789391dc6805f8e"}}` +Client3: **test2.py** +Server (Broadcast): `{"sync" : {"test2.py" : "2cbcc3416544206f8789391dc6805f8e"}}` +Server (Broadcast): **test2.py** + +Client3: **Creates test3.py** +Client3: `{"sync" : {"test3.py" : "3cbcc3416544206f8789391dc6805f8e"}}` +Client3: **test3.py** +Server (Broadcast): `{"sync" : {"test3.py" : "3cbcc3416544206f8789391dc6805f8e"}}` +Server (Broadcast): **test3.py** + +Client1: **Deletes test2.py** +Client1: `{"sync" : {"test2.py" : "0"}}` +Server (Broadcast): `{"sync" : {"test2.py" : "0"}}` + +Client2: **Changes test3.py** +Client2: `{"sync" : {"test3.py" : "7cbcc3416544206f8789391dc6805f8e"}}` +Client2: **test3.py** +Server (Broadcast): `{"sync" : {"test3.py" : "7cbcc3416544206f8789391dc6805f8e"}}` +Server (Broadcast): **test3.py**