Skip to content

feat: network presence #298

Description

@josephfusco

Adds a network-wide presence summary. wp_presence is per-site; nothing aggregates it across a network today.

Each site pushes its own online count into a small network-level table when its own presence data changes, instead of a central process reading every site's table on demand. Reading the summary is one query against that table, not a fan-out across every site's wp_presence table.

This avoids switch_to_blog() entirely, since no per-site table is ever queried at read time. It also avoids the write contention a single shared option or transient would create as the network grows: different sites write different rows, so writes from different sites never block each other.

Shows up in the Sites list, Users list, and a network dashboard widget matching the existing single-site Who's Online widget.

Doesn't need a separate large-network cutoff the way a fan-out query would: reading the summary is always a single query against a table sized to the network, not one query per site.

Metadata

Metadata

Assignees

Labels

Needs DiscussionAnything that needs a discussion/agreement[Type] FeatureA new feature within an existing module

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions