[wp-trac] [WordPress Trac] #64696: Real time collboration effectively disables persistent post caches while anyone edits a post
WordPress Trac
noreply at wordpress.org
Thu Mar 5 02:26:57 UTC 2026
#64696: Real time collboration effectively disables persistent post caches while
anyone edits a post
--------------------------------------+--------------------------
Reporter: peterwilsoncc | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: 7.0
Component: Posts, Post Types | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses: performance
--------------------------------------+--------------------------
Comment (by peterwilsoncc):
Here are my thoughts after Chris caught me up on the background and
technical requirements of RTC.
---
Items to move to the table:
* `wp_sync_update` post meta for rooms
* Awareness
Remaining where they currently are:
* crdt document - it's only updated when a user saves, not when a sync
occurs
Table name: `wp_collaboration`
Columns:
* ID (BIGINT, Primary key) -- Used as cursor in Post Meta storage class
* `room_id` (VARCHAR, 60, Indexed) - hash, with a bit of room for plugin
authors to do things
* `event_type` (VARCHAR, 255, Indexed) -- "awareness" OR "sync_update" OR
future type
* `gmt_timestamp` (date/time, Indexed) - when the event happened, this may
be updated for items such as the awareness api when it updates on an
ongoing basis
* `event_data` (LONGTEXT) -- blob, client id, etc as appropriate
`WP_Sync_Post_Meta_Storage` to be renamed as appropriate for the new
dedicated table.
The `WP_Sync_Storage` interface to be updated to allow for awareness to be
stored in multiple rows:
{{{
public function get_awareness_states_since( string $room, int $timestamp
): array;
public function add_awareness_state( string $room, array $awareness_state
): void;
public function remove_awareness_states_before( string $room, int
$timestamp ): array;
}}}
Props @chriszarate for giving this an edit and brainstorming prior to
publication.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64696#comment:43>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list