Content Hash - CI/CD用語集の定義
content hash はファイルのコンテンツから導出されファイル名に使われるため、同一の build は同一の名前を生成します。
content hash はファイルのコンテンツから計算されるハッシュで、出力ファイル名に使われ、コンテンツが変わった場合に限り名前が変わるようにします。Webpack は [contenthash] プレースホルダーとしてこれを公開します。
build ごとのハッシュとは異なり、content hash はファイルが変更されていないときは安定したままで、deploy 間でのキャッシュ再利用を最大化します。これは cache busting と long-term caching の基盤です。CIでは、決定的な content hash によって build も再現可能になります。
関連ガイド
Asset Hashing - CI/CD Glossary DefinitionAsset Hashing: Asset hashing embeds a content-derived hash in output filenames (for example `app.3f9a1c.js`)…
Cache Busting - CI/CD Glossary DefinitionCache Busting: Cache busting forces clients to download a new version of a file by changing its URL, usually…
Long-Term Caching - CI/CD Glossary DefinitionLong-Term Caching: Long-term caching is serving static assets with a far-future cache lifetime so browsers re…