Skip to content

Commit 26ba767

Browse files
0x00101010Toshi
andcommitted
Show load-test mixes as normalized shares
Co-authored-by: Toshi <toshi-noreply@coinbase.com>
1 parent b415fdf commit 26ba767

3 files changed

Lines changed: 4 additions & 5 deletions

File tree

‎app/scaling/runs/fixtures/synthetic.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"config": {
4545
"funding_amount": "1000000000000000000", "sender_count": 10, "sender_offset": 0, "in_flight_per_sender": 4,
4646
"duration": "30s", "target_gps": 15000000, "seed": 1, "chain_id": null,
47-
"transactions": [{ "type": "transfer", "weight": 70 }, { "type": "swap", "weight": 30 }],
47+
"transactions": [{ "type": "transfer", "weight": 3 }, { "type": "swap", "weight": 1 }],
4848
"looper_contract": null, "swap_token_amount": "0"
4949
}
5050
}

‎app/scaling/runs/lib/unified.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ it('maps a load test as a burst with its mix, observed gas/s and p99 latencies',
3737
timestamp: Date.UTC(2026, 0, 8, 0, 0, 1),
3838
duration: 30,
3939
profile: 'burst',
40-
workload: '70% transfer · 30% swap · target 15 Mgas/s',
40+
workload: 'transfer (75%) · swap (25%) · target 15 Mgas/s',
4141
gasPerSecond: 12.5e6,
4242
latency: [{ label: 'block p99', seconds: 3 }, { label: 'flashblocks p99', seconds: 0.8 }],
4343
status: 'success',

‎app/scaling/runs/lib/unified.ts‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { durationToMs, parseLoadTestTimestamp } from './formatters';
1+
import { durationToMs, formatTransactions, parseLoadTestTimestamp } from './formatters';
22
import type { BenchmarkRunWithStatus, LoadTestEntry, LoadTestResult, RunStatus, RustDuration } from './types';
33

44
export type LoadRun = LoadTestEntry & { result?: LoadTestResult };
@@ -51,7 +51,6 @@ function fromBench(run: BenchmarkRunWithStatus): UnifiedRun {
5151

5252
function fromLoad({ network, timestamp, result }: LoadRun): UnifiedRun {
5353
const config = result?.config;
54-
const mix = config?.transactions.map((t) => `${t.weight}% ${t.type}`).join(' · ');
5554
const target = config ? `target ${config.target_gps / 1e6} Mgas/s` : undefined;
5655
return withQualifies({
5756
kind: 'load',
@@ -62,7 +61,7 @@ function fromLoad({ network, timestamp, result }: LoadRun): UnifiedRun {
6261
commit: null,
6362
machine: null,
6463
duration: result?.throughput ? secs(result.throughput.duration) : null,
65-
workload: [mix, target].filter(Boolean).join(' · ') || '—',
64+
workload: [config && formatTransactions(config), target].filter(Boolean).join(' · ') || '—',
6665
gasPerSecond: result?.throughput?.gps ?? null,
6766
latency: result?.block_latency ? [{ label: 'block p99', seconds: secs(result.block_latency.p99) }, { label: 'flashblocks p99', seconds: secs(result.flashblocks_latency.p99) }] : [],
6867
status: result ? (result.error ? 'fatal' : 'success') : null,

0 commit comments

Comments
 (0)