mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-24 13:17:10 +08:00
feat(server): realtime notification & task status (#14934)
#### PR Dependency Tree * **PR #14934** 👈 This tree was auto-generated by [Charcoal](https://github.com/danerwilliams/charcoal) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Full realtime platform added: live notifications, comments, embedding progress, and transcription task updates via realtime subscriptions. * **Chores** * Frontend switched from polling/GraphQL queries to realtime channels; legacy query fields marked deprecated and client libs updated to use realtime APIs. [](https://app.coderabbit.ai/change-stack/toeverything/AFFiNE/pull/14934) <!-- end of auto-generated comment: release notes by coderabbit.ai --> #### PR Dependency Tree * **PR #14934** 👈 * **PR #14936** This tree was auto-generated by [Charcoal](https://github.com/danerwilliams/charcoal)
This commit is contained in:
@@ -1,3 +1,15 @@
|
||||
import type {
|
||||
RealtimeConfigureInput,
|
||||
RealtimeRequestInputOf,
|
||||
RealtimeRequestName,
|
||||
RealtimeRequestOutputOf,
|
||||
RealtimeStatus,
|
||||
RealtimeSubscriptionReady,
|
||||
RealtimeTopicEventOf,
|
||||
RealtimeTopicInputOf,
|
||||
RealtimeTopicName,
|
||||
} from '@affine/realtime';
|
||||
|
||||
import type { AvailableStorageImplementations } from '../impls';
|
||||
import type {
|
||||
AggregateResult,
|
||||
@@ -189,4 +201,25 @@ export type WorkerManagerOps = {
|
||||
'telemetry.pageview': [TelemetryEvent, { queued: boolean }];
|
||||
'telemetry.flush': [void, TelemetryAck];
|
||||
'telemetry.getQueueState': [void, TelemetryQueueState];
|
||||
'realtime.configure': [RealtimeConfigureInput, void];
|
||||
'realtime.request': [
|
||||
{
|
||||
[Op in RealtimeRequestName]: {
|
||||
op: Op;
|
||||
input: RealtimeRequestInputOf<Op>;
|
||||
timeoutMs?: number;
|
||||
};
|
||||
}[RealtimeRequestName],
|
||||
RealtimeRequestOutputOf<RealtimeRequestName>,
|
||||
];
|
||||
'realtime.subscribe': [
|
||||
{
|
||||
[Topic in RealtimeTopicName]: {
|
||||
topic: Topic;
|
||||
input: RealtimeTopicInputOf<Topic>;
|
||||
};
|
||||
}[RealtimeTopicName],
|
||||
RealtimeTopicEventOf<RealtimeTopicName> | RealtimeSubscriptionReady,
|
||||
];
|
||||
'realtime.status': [void, RealtimeStatus];
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user