feat(amber): set cache-control headers for static frontend assets#5846
feat(amber): set cache-control headers for static frontend assets#5846Ma77Ball wants to merge 11 commits into
Conversation
|
| config | throughput | MB/s | latency | max Δ latest / 7d | |
|---|---|---|---|---|---|
| 🔴 | bs=10 sw=10 sl=64 | 403 | 0.246 | 24,052/31,349/31,349 us | 🔴 -7.4% / 🟢 -10.4% |
| 🔴 | bs=100 sw=10 sl=64 | 822 | 0.502 | 119,526/148,059/148,059 us | 🔴 +19.1% / 🔴 -7.8% |
| ⚪ | bs=1000 sw=10 sl=64 | 944 | 0.576 | 1,062,736/1,085,949/1,085,949 us | ⚪ within ±5% / 🔴 -9.3% |
Baseline details
Latest main 6eb4165 from same runner
| config | metric | PR | latest main | 7d avg | Δ latest | Δ 7d |
|---|---|---|---|---|---|---|
| bs=10 sw=10 sl=64 | throughput | 403 tuples/sec | 435 tuples/sec | 410.82 tuples/sec | -7.4% | -1.9% |
| bs=10 sw=10 sl=64 | MB/s | 0.246 MB/s | 0.265 MB/s | 0.251 MB/s | -7.2% | -1.9% |
| bs=10 sw=10 sl=64 | p50 | 24,052 us | 22,887 us | 23,785 us | +5.1% | +1.1% |
| bs=10 sw=10 sl=64 | p95 | 31,349 us | 33,479 us | 34,980 us | -6.4% | -10.4% |
| bs=10 sw=10 sl=64 | p99 | 31,349 us | 33,479 us | 34,980 us | -6.4% | -10.4% |
| bs=100 sw=10 sl=64 | throughput | 822 tuples/sec | 871 tuples/sec | 891.94 tuples/sec | -5.6% | -7.8% |
| bs=100 sw=10 sl=64 | MB/s | 0.502 MB/s | 0.531 MB/s | 0.544 MB/s | -5.5% | -7.8% |
| bs=100 sw=10 sl=64 | p50 | 119,526 us | 114,220 us | 112,277 us | +4.6% | +6.5% |
| bs=100 sw=10 sl=64 | p95 | 148,059 us | 124,355 us | 139,802 us | +19.1% | +5.9% |
| bs=100 sw=10 sl=64 | p99 | 148,059 us | 124,355 us | 139,802 us | +19.1% | +5.9% |
| bs=1000 sw=10 sl=64 | throughput | 944 tuples/sec | 932 tuples/sec | 1,041 tuples/sec | +1.3% | -9.3% |
| bs=1000 sw=10 sl=64 | MB/s | 0.576 MB/s | 0.569 MB/s | 0.635 MB/s | +1.2% | -9.3% |
| bs=1000 sw=10 sl=64 | p50 | 1,062,736 us | 1,075,520 us | 972,714 us | -1.2% | +9.3% |
| bs=1000 sw=10 sl=64 | p95 | 1,085,949 us | 1,107,212 us | 1,023,057 us | -1.9% | +6.1% |
| bs=1000 sw=10 sl=64 | p99 | 1,085,949 us | 1,107,212 us | 1,023,057 us | -1.9% | +6.1% |
Raw CSV
config_idx,batch_size,schema_width,string_len,num_batches,total_ms,total_tuples,total_bytes,tuples_per_sec,mb_per_sec,lat_p50_us,lat_p95_us,lat_p99_us
0,10,10,64,20,496.27,200,128000,403,0.246,24051.75,31348.63,31348.63
1,100,10,64,20,2431.99,2000,1280000,822,0.502,119525.99,148059.24,148059.24
2,1000,10,64,20,21178.18,20000,12800000,944,0.576,1062735.67,1085948.95,1085948.95
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #5846 +/- ##
============================================
- Coverage 54.42% 54.32% -0.11%
+ Complexity 2891 2890 -1
============================================
Files 1107 1103 -4
Lines 42768 42635 -133
Branches 4599 4588 -11
============================================
- Hits 23276 23160 -116
+ Misses 18130 18120 -10
+ Partials 1362 1355 -7
*This pull request uses carry forward flags. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Automated Reviewer SuggestionsBased on the
|
|
/request-review @Yicong-Huang |
What changes were proposed in this PR?
no-cache, must-revalidateso a stale entry document is never served past a deploy; content-hashed bundles (name..js/.css and other fingerprinted assets) getpublic, max-age=31536000, immutable; /api/* responses are left untouched.Any related issues, documentation, discussions?
Closes: #5835
How was this PR tested?
sbt "WorkflowExecutionService/testOnly *StaticAssetCacheFilterSpec"on JDK 17, expect 7 passing cases: hashed js/css/media to immutable, index.html and Angular routes to revalidate, /api/* untouched, and short numeric segments not mistaken for a content hash.curl -I http://localhost:8080/index.htmland expectCache-Control: no-cache, must-revalidate;curl -Ia hashed bundle (e.g. /main..js) and expectCache-Control: public, max-age=31536000, immutable.Was this PR authored or co-authored using generative AI tooling?
Co-authored with Claude Opus 4.8 in compliance with ASF