Repository navigation
Conversation
|
@terngunan Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds runtime realtime controls and hardens the browser connection surface. Realtime endpoints now derive from one API URL helper used by the transport guard and report-only CSP. The client checks a remotely served control document before opening and before reconnecting, closes active sockets and clears subscriptions when disabled, and keeps the trip latched. A lifecycle adapter pauses sockets on hidden/pagehide/freeze and resumes on visible/pageshow/resume. The supported API is exposed through
@/lib/realtimewith a lint boundary.Validation
no-restricted-syntaxrule disabled.git diff --check: passed.npm run typecheck,npm run lint, andnpm testremain blocked by existing repository failures: malformed JSX insrc/app/cover/page.tsx, existing lint violations, and Vitest configuration/dependency issues (20 suites fail; unrelated passing tests include 48 passed).Operational follow-up
The production
/realtime-control.jsonmust be served through the backend/CDN with a five-second maximum cache lifetime and purge support; coordinate that endpoint with refract-backend/on-call. This repo has no outbound realtime mutation queue, cross-tab leader-election lease, or existing realtime-consuming REST hooks, so this change cannot flush queued mutations/relinquish a leader role or demonstrate an app-level REST fallback integration. The new topic hook exposes best-effort updates and clears them on disable/lifecycle suspension; current application consumers should continue using REST as their source of truth.Closes #275
Closes #274
Closes #273
Closes #272