Braid Protocol Walkthrough
Channel: Braid Protocol
Date: 2021-03-09

A walkthrough of version 2 of the Braid protocol titled “Braid-HTTP: Synchronization for HTTP”
https://datatracker.ietf.org/doc/html/draft-toomim-httpbis-braid-http

Learn more about Braid
https://braid.org

Read by the Bevry community as part of its Bevry Readings initiative:
https://bevry.me
https://www.youtube.com/channel/UChocfRaSZusT5B_n8NpbeqQ

Performed and edited by Benjamin Lupton
https://balupton.com

Referenced interview with Michael Toomim
https://youtu.be/ALTohs4WLjc

## TIMESTAMPS ##

00:00 Abstract
02:15 Introduction
05:50 Versioning for Resources
08:35 Commentary
08:44 Comparison with ETag
09:27 PUT a new version
11:00 Commentary
11:43 PUT a new version as a patch
17:25 Commentary
18:11 GET a specific version with Commentary
26:50 Subscriptions for GET with Commentary
39:20 Creating a Subscription
40:50 Commentary
42:15 Sending multiple updates per GET
42:50 Continuing a Subscription with Commentary
49:41 Ending a Subscription
50:36 Commentary
52:16 Errors with Commentary
54:12 Design Goals
54:46 Use Cases
54:51 Dynamic Resources: Animating a GIF
56:00 Commentary
58:20 Dynamic Proxies and Caches
59:29 Commentary
1:04:10 A Serverless Chat Example
1:05:50 Commentary
1:09:58 Related Work, Web Frameworks with Commentary
1:21:26 Existing IETF Standards
1:22:30 IANA Considerations
1:24:03 Commentary
1:24:13 Security Considerations
1:24:18 Footer with Commentary

Braid is a set of extensions that generalize HTTP from a state *transfer* protocol into a state *synchronization* protocol.  Braid puts the power of Operational Transform and CRDTs on the web, improving network performance and enabling natively peer-to-peer collaboratively-editable, offline-first web applications.

Braid is composed of four extensions to HTTP:

 1. VERSIONING on resources
 2. SUBSCRIPTIONS on GET requests
 3. PATCHES created from Range Requests
 4. MERGE-TYPES that specify OT or CRDT behavior

These extensions are independent; each provides a distinct value for a stand-alone use-case.  However, when used together, they enable a web resource to synchronize automatically across multiple clients, servers and proxies, and support arbitrary simultaneous edits by multiple writers, under arbitrary network delays and partitions, while guaranteeing consistency using a OT, CRDT, or other algorithm.

These synchronization features provide a step towards a standard for the dynamic internal state of websites.  Web programmers currently synchronize state across clients and servers with layers of non-standard Javascript frameworks.  A synchronization standard built upon REST can enable programmers to read and write the internal state of any website as easily as a local variable on their own site.  This could enable a separation of UI from state, and allow any user to edit or choose their own UI for any website's state.