mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Move static_cache_contorl
deprecation changelog entry to Railties.
The configuration for `config.static_cache_control`, and its replacement `config.public_file_server.headers` are implemented in Railties. People would configure this in environment files, which is Railties domain too.
This commit is contained in:
parent
748b2f9cb1
commit
a3e05f7c81
2 changed files with 22 additions and 5 deletions
|
@ -17,11 +17,6 @@
|
||||||
|
|
||||||
*Agis Anastasopoulos*
|
*Agis Anastasopoulos*
|
||||||
|
|
||||||
* Deprecate `config.static_cache_control` in favor of
|
|
||||||
`config.public_file_server.headers`
|
|
||||||
|
|
||||||
*Yuki Nishijima*
|
|
||||||
|
|
||||||
* Add the ability of returning arbitrary headers to ActionDispatch::Static
|
* Add the ability of returning arbitrary headers to ActionDispatch::Static
|
||||||
|
|
||||||
Now ActionDispatch::Static can accept HTTP headers so that developers
|
Now ActionDispatch::Static can accept HTTP headers so that developers
|
||||||
|
|
|
@ -16,6 +16,28 @@
|
||||||
|
|
||||||
*Kasper Timm Hansen*
|
*Kasper Timm Hansen*
|
||||||
|
|
||||||
|
* Deprecate `config.static_cache_control` in favor of
|
||||||
|
`config.public_file_server.headers`.
|
||||||
|
|
||||||
|
To upgrade, replace occurrences of:
|
||||||
|
|
||||||
|
```
|
||||||
|
config.static_cache_control = 'public, max-age=60'
|
||||||
|
```
|
||||||
|
|
||||||
|
in your environment files, with:
|
||||||
|
|
||||||
|
```
|
||||||
|
config.public_file_server.headers = {
|
||||||
|
'Cache-Control' => 'public, max-age=60'
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`config.public_file_server.headers` can set arbitrary headers, sent along when
|
||||||
|
a response is delivered.
|
||||||
|
|
||||||
|
*Yuki Nishijima*
|
||||||
|
|
||||||
* Route generator should be idempotent
|
* Route generator should be idempotent
|
||||||
running generators several times no longer require you to cleanup routes.rb
|
running generators several times no longer require you to cleanup routes.rb
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue