feat: frontend perf monitoring, gas optimization, WebSocket pooling, modular contract compilation - #824
Merged
Ebuka321 merged 1 commit intoJul 27, 2026
Conversation
…modular contract compilation Core Web Vitals tracking (LCP, FID, CLS) with budget enforcement and regression alerts. Performance budgets validated in CI via performance-ci.yml workflow. Real user monitoring (RUM) session snapshots with 30s periodic flush to configurable endpoint. Performance regression alerts forwarded to Sentry breadcrumbs in production. Route transition tracking wired into NavigationContainer.onStateChange. Bundle size impact analysis via trackBundleSize() in performanceMonitor. Render/interaction/memory/route/bundle metrics with p95 aggregation and summary. PerformanceDashboardScreen redesigned with Core Web Vitals panel, regression alerts, and route transitions. usePerformanceProfiler extended with LCP option and new useFIDTracker hook. performance-budget.json extended with routeTransitionMs, lcpMs, fidMs, clsFrameDrops, bundleSizeBytes. check-performance-budget.js updated to validate all new budget fields. Gas benchmark tests added in contracts/subscription/src/gas_benchmarks.rs. gas-benchmark.sh updated to target new benchmark test functions. GAS_OPTIMIZATION.md documents storage slot packing, lazy init, and before/after comparison. contracts:gas-benchmark and contracts:gas-benchmark:baseline npm scripts added. WebSocket connection pooling via socketPool map (shared socket per URL, ref-counted). Message batching with configurable flush interval and head-drop backpressure. Heartbeat ping/pong health monitoring with auto-reconnect on pong timeout. Exponential backoff with jitter (capped at 30s) for reconnection. Per-client send queue on server with slow-consumer overflow protection. Per-user connection limit (default 5) for graceful degradation. WebSocketMetrics: throughputEps, eventsDelivered/Dropped, batchesFlushed, evictedClients. websocketStore.ts Zustand store exposes state, metrics, connect, disconnect, subscribe. docs/websocket-optimization.md documents all features and transport integration. Modular contract compilation: all 13 crates now use workspace soroban-sdk dependency. Feature flags per crate: testutils, oracle, extended, metering, audit-log, credit, fraud, full. contracts/.cargo/config.toml sets wasm32-unknown-unknown as default build target. contracts/Makefile with build-core, build-full, build-minimal, size-report, bench-compile targets. build-contracts action rewritten with per-crate targeting and binary size step summary. contract-build.yml CI: feature matrix (8-way parallel), binary size monitoring on PRs, compile benchmark. Closes Smartdevs17#767 Closes Smartdevs17#761 Closes Smartdevs17#760 Closes Smartdevs17#766
|
@ochemegina-ai 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.
Core Web Vitals tracking (LCP, FID, CLS) with budget enforcement and regression alerts. Performance budgets validated in CI via performance-ci.yml workflow. Real user monitoring (RUM) session snapshots with 30s periodic flush to configurable endpoint. Performance regression alerts forwarded to Sentry breadcrumbs in production. Route transition tracking wired into NavigationContainer.onStateChange. Bundle size impact analysis via trackBundleSize() in performanceMonitor. Render/interaction/memory/route/bundle metrics with p95 aggregation and summary. PerformanceDashboardScreen redesigned with Core Web Vitals panel, regression alerts, and route transitions. usePerformanceProfiler extended with LCP option and new useFIDTracker hook. performance-budget.json extended with routeTransitionMs, lcpMs, fidMs, clsFrameDrops, bundleSizeBytes. check-performance-budget.js updated to validate all new budget fields. Gas benchmark tests added in contracts/subscription/src/gas_benchmarks.rs. gas-benchmark.sh updated to target new benchmark test functions. GAS_OPTIMIZATION.md documents storage slot packing, lazy init, and before/after comparison. contracts:gas-benchmark and contracts:gas-benchmark:baseline npm scripts added. WebSocket connection pooling via socketPool map (shared socket per URL, ref-counted). Message batching with configurable flush interval and head-drop backpressure. Heartbeat ping/pong health monitoring with auto-reconnect on pong timeout. Exponential backoff with jitter (capped at 30s) for reconnection. Per-client send queue on server with slow-consumer overflow protection. Per-user connection limit (default 5) for graceful degradation. WebSocketMetrics: throughputEps, eventsDelivered/Dropped, batchesFlushed, evictedClients. websocketStore.ts Zustand store exposes state, metrics, connect, disconnect, subscribe. docs/websocket-optimization.md documents all features and transport integration. Modular contract compilation: all 13 crates now use workspace soroban-sdk dependency. Feature flags per crate: testutils, oracle, extended, metering, audit-log, credit, fraud, full. contracts/.cargo/config.toml sets wasm32-unknown-unknown as default build target. contracts/Makefile with build-core, build-full, build-minimal, size-report, bench-compile targets. build-contracts action rewritten with per-crate targeting and binary size step summary. contract-build.yml CI: feature matrix (8-way parallel), binary size monitoring on PRs, compile benchmark.
Closes #767
Closes #761
Closes #760
Closes #766