mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-04-21 05:06:29 +00:00
Two way sync V0 (#282)
* Unfinished two-way sync API * In-memory two-way sync complete * Move PatchSet application into ChangeProcessor thread, where it can be synchronous * Stop InstanceMap's signals when a ServeSession terminates * Apply patch in ChangeProcessor * Feature flag * Fix error in ChangeProcessor due to wrong drop order
This commit is contained in:
committed by
GitHub
parent
26e2e81188
commit
a398338c02
@@ -100,6 +100,23 @@ pub struct ReadResponse<'a> {
|
||||
pub instances: HashMap<RbxId, Instance<'a>>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct WriteRequest {
|
||||
pub session_id: SessionId,
|
||||
pub removed: Vec<RbxId>,
|
||||
|
||||
#[serde(default)]
|
||||
pub added: HashMap<RbxId, ()>,
|
||||
pub updated: Vec<InstanceUpdate>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct WriteResponse {
|
||||
pub session_id: SessionId,
|
||||
}
|
||||
|
||||
/// Response body from /api/subscribe/{cursor}
|
||||
#[derive(Debug, Serialize, Deserialize)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
|
||||
Reference in New Issue
Block a user