fix(mindspace): use lightweight page sync for background list refresh
Background page list sync was calling syncAndDeliver over the remote adapter, which could exceed the 60s timeout for heavy users and block Portal. Route list sync through pageSyncService only via listSync while keeping full delivery on Finish and agent-run paths. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -20,7 +20,18 @@ const contractSource = read('mindspace-server-adapter-contract.mjs');
|
||||
assertIncludes(
|
||||
'server.mjs syncUserGeneratedPages',
|
||||
serverSource,
|
||||
'await mindSpacePageSync.syncUserGeneratedPages(userId);',
|
||||
'mindSpacePageSync.syncUserGeneratedPages(userId',
|
||||
);
|
||||
assertIncludes(
|
||||
'server.mjs list page sync bypasses full delivery',
|
||||
serverSource,
|
||||
'listSync = false',
|
||||
);
|
||||
const pageCoreRoutesSource = read('server/portal-mindspace-page-core-routes.mjs');
|
||||
assertIncludes(
|
||||
'portal page list background sync',
|
||||
pageCoreRoutesSource,
|
||||
'syncUserGeneratedPages(userId, { listSync: true })',
|
||||
);
|
||||
if (serverSource.includes("mindSpaceServerRuntime.adapterKind === 'remote'")) {
|
||||
throw new Error(
|
||||
|
||||
Reference in New Issue
Block a user