Files
Eagler-Archive/incari-client/files/app-web/download-budget.properties
T

83 lines
4.3 KiB
Properties

# What a player downloads to start the browser build, checked by `./gradlew :app-web:checkDownloadSize`
# (tools/webbuild DownloadSize). Raising a number is fine when the pull request says why; the point
# is that growth is noticed.
#
# Every file in app-web/build/teavm/, and each extra file the page fetches, must be classified here,
# or the check fails: nothing ships unmeasured.
# download the page fetches it at start: measured and budgeted
# debug only a development build has it; measured, not budgeted
# report a compile report; the page never fetches it
# vendor Mojang's file, fetched by the page but not shipped by Incari: measured, not budgeted
file.incari.wasm=download
file.incari.wasm-runtime.js=download
file.index.html=download
# The build-time shader manifest (built by :app-web:shaders; the dev server serves it next to the page).
# The page reads it from the asset pack; an experiment's build without a pack still
# fetches it, so it's measured, not counted twice.
file.shaders.json=debug
# The loader: its scripts (src/main/ts, types stripped), the build manifest, and the asset pack
# (build-time data: the translated shaders, in a zip).
file.boot.js=download
file.loader.js=download
file.features.js=download
file.jspi.js=download
file.wakeups.js=download
file.game-worker.js=download
file.cache-policy.js=download
file.sw.js=download
file.build.json=download
file.incari.pack=download
# TeaVM's stack deobfuscator and the debug information it reads. The development page fetches both
# at start (index.html enables `stackDeobfuscator`), but a release build (webbuild --release) makes
# neither, so they aren't part of what a player downloads.
file.incari.wasm-deobfuscator.wasm=debug
file.incari.wasm.teadbg=debug
file.*.txt=report
# The game's own jar, which the page unpacks for its resources (ClientJar). Mojang's file: reported
# so its weight is visible, never counted as Incari's.
file.client.jar=vendor
# Limits in bytes. The budget is in gzip (level 9, compressed once at deploy time): every browser
# and static host handles it. Brotli (quality 11) is smaller and reported next to it, but a host may
# not serve it. The module's raw size is limited too: the Chromebook holds and compiles it uncompressed.
#
# The limits are the development build's size (`:app-web:teavm`: TeaVM's SIMPLE optimization,
# unobfuscated, so the module carries a 70 MB `name` section) plus a little headroom. Accidental
# growth (a survey rule that pulls in a library, a class-library change that drags in a subsystem)
# tends to be bigger than that, so a limit is raised deliberately. Measured 2026-09-29, with Via and
# the Eagler stage: development build 193.86 MB raw, 38.65 MB gzip; release build (-Pteavm.release)
# 66.33 MB raw, 20.06 MB gzip, 12.56 MB brotli. Via's translation code is most of the growth.
max.gzip.total=40_300_000
max.gzip.incari.wasm=40_000_000
max.raw.incari.wasm=200_000_000
# TeaVM's loader; changes only with a TeaVM upgrade (8.8 kB gzip measured).
max.gzip.incari.wasm-runtime.js=10_000
# The page, with its loading screen's images inline (the backdrop, the mark and the icon, base64:
# about 26 kB that gzip can't shrink). Measured 21.8 kB gzip (2026-10-20).
max.gzip.index.html=25_000
# The translated shaders: 309 stages, 1107 kB raw, 43.5 kB gzip (2026-09-28, ADR 0012). They ship in
# the asset pack (below), whose limit carries this one.
# The loader's scripts are a few kilobytes each; the asset pack carries the shaders (deflated,
# so about what shaders.json gzips to) and a manifest.
max.gzip.boot.js=6_000
max.gzip.loader.js=4_000
max.gzip.features.js=2_000
# Measured 1.6, 1.1 and 2.6 kB gzip (2026-10-19).
max.gzip.jspi.js=3_000
max.gzip.wakeups.js=2_000
max.gzip.game-worker.js=4_000
max.gzip.cache-policy.js=2_000
max.gzip.sw.js=3_000
max.gzip.build.json=2_000
# Via's mapping data rides in the pack (classpath/): 1.25 MB of NBT and JSON, about 270 kB
# compressed. Measured 318.5 kB gzip with the shaders.
# The vanilla sprites decoded (ADR 0026) with their mip levels (sprites.bin, 3142 sprites, 7.4
# MB raw, about 1.06 MB deflated), so a start skips decoding their PNGs. Measured 1.39 MB with the rest.
# Incari's own pack rides in it too (classpath/incari-pack/): GUI textures and six fonts, 379 kB
# packed. Measured 1.73 MB in all (2026-10-20).
max.gzip.incari.pack=1_900_000