CI that keeps up
← Changelog
v0.19.4 · Oct 30, 2025

Function Cache Control

Before this change, Dagger cached all system functions but not module developers' own functions. We couldn't safely infer purity from side effects, so default caching could have broken behavior.

Now module developers can explicitly set cache policy per function. With explicit control in place, default caching can improve performance safely.

@func() // pure function: default TTL caching
async test(): Promise<string> { ... }

@func({ cache: "15m" }) // refresh external data periodically
async latestBaseDigest(): Promise<string> { ... }

@func({ cache: "never" }) // side effects: always execute
async deploy(): Promise<string> { ... }