-
Notifications
You must be signed in to change notification settings - Fork 1
Ts/setup load testing #62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
Caution MetaMask internal reviewing guidelines:
|
|
Since this package is an internal testing tool and won't be published, we can safely ignore these warnings @SocketSecurity ignore npm/ssh2@1.17.0 -- Intentionally using SSH2 for remote infrastructure management in internal load testing tool. Shell/network access is expected behavior for an SSH client. @SocketSecurity ignore npm/buildcheck@0.0.7 -- Transitive dependency of ssh2. @SocketSecurity ignore npm/cpu-features -- Transitive dependency of ssh2. @SocketSecurity ignore npm/asn1 -- Transitive dependency of ssh2. |
Adds a new load testing package with two scenarios: - connection-storm: Rapid connection establishment testing - steady-state: Connection stability over time Usage: yarn start --target=ws://localhost:8000/connection/websocket --scenario=steady-state --connections=100 --duration=60 Features: - Centrifuge WebSocket client wrapper with timing - Progress bar with real-time connection status - JSON output with latency percentiles - Configurable ramp-up pacing Note: Infrastructure commands (infra, results aggregate) are placeholders for the follow-up distributed testing PR.
- Rename 'latency' to 'connectTime' for clarity (measures connection establishment time, NOT message RTT) - Add p50 and p99 percentiles to connectTime stats - Fix connectionStability comment to accurately describe what it measures (percentage connected at end, not 'stayed connected the whole time') - Add temp/ to gitignore for working documents - Update lavamoat config for tsx>esbuild
e86ea97 to
3353d92
Compare
…ck overflow Since the array is already sorted ascending, use sorted[0] for min and sorted[sorted.length - 1] for max instead of Math.min/max(...sorted). This prevents RangeError: Maximum call stack size exceeded when testing with >65K connections.
d833694 to
885a284
Compare
- Remove .gitkeep, results/ dir is created programmatically - Remove redundant .infra-state.json ignore (already covered by results/) - Simplify .tsbuildinfo pattern to **/*.tsbuildinfo
…testing - DigitalOcean droplet provisioning (create/destroy) - SSH-based command execution on droplets - Parallel execution with progress tracking - Results collection via SFTP - Background execution for long-running tests - Results aggregation across multiple droplets
- Fix latency aggregation bug (allLatencies was never populated) - Rename latency → connectTime to match scaffolding PR - Use corepack for Yarn installation instead of npm install -g yarn - Fix SSH exit code null handling (assume failure if no exit code) - Add concurrency limit (5) for droplet creation to avoid rate limits - Add aggregator input validation for required fields - Extract DROPLET_HOURLY_COST constant
- Add branch name validation to prevent shell injection (droplet.ts, infra.ts) - Add regex escaping for name prefix to prevent incorrect droplet matching - Add shell single-quote escaping for file paths in wait command - Add NaN validation for timeout/interval to prevent infinite loops - Add timeout to SFTP download to prevent hanging indefinitely
59062fd to
f75e1ab
Compare
Uh oh!
There was an error while loading. Please reload this page.