Skip to content

store_scripts follow-ups: per-reason skip warning, bound overshoot docs, --no-store-scripts #1268

Closed

Description

@nc9

Follow-ups from the review of #1267 (opt-in store_scripts). None blocks the feature.

Problem

  • The warning "N script(s) were not stored (over X bytes each, or past the Y byte total)" also counts scripts skipped as memory-cap and time-budget, and says nothing about the fetch bound being hit.
  • The fetch bounds are checked only when a request starts: time can overshoot by up to about 20 s, memory by up to 10 in-flight bodies, and the preload fetch has its own counters. Bundles with non-Latin1 text hold about 2 bytes per char, so RSS can reach roughly 3x the 256 MB cap. The docs do not say so.
  • The config test title for store_scripts_max_scripts still says "1 to 1000" (the ceiling is 500).
  • Deferred from the review: no per-run --no-store-scripts when config turns it on; content-store.db and project DBs are 0644 (same as the HTML store; bundles can hold keys); the empty crawl_scripts tables are created in every project DB even when the feature is off.

Acceptance Criteria

  • The skipped-scripts warning names each reason separately (too large, total cap, memory cap, time budget) with counts, and says which setting or bound applies.
  • docs/configuration/storage.mdx states the overshoot of the time and memory bounds and the roughly 3x RSS figure for non-Latin1 bundles.
  • The preload fetch shares the memory and time bound with the main script fetch, or the docs say it does not.
  • The config test title says 1 to 500.
  • squirrel audit --no-store-scripts turns the option off for one run when [storage] store_scripts = true.
  • Stored-script files are created with owner-only modes, or the docs state the 0644 modes and the key risk.
  • The empty script tables are created only when the feature is on, or the docs say they exist when it is off.

Metadata

Metadata

Assignees

No one assigned

    Labels

    clienhancementsize: XS

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions