1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activestorage/app
Evgeniy Rashchepkin 6af5662165
Disable template digesting for Active Storage controllers
Error entries appear in the log when we request ActiveStorage
controllers (`ActiveStorage::Representations::ProxyController#show`,
`ActiveStorage::Blobs::ProxyController#show`).

These entries look like: "Couldn't find template for digesting:
active_storage/representations/proxy/show".

These controllers use the method
`ActionController::ConditionalGet#http_cache_forever`,
and therefore `ActionController::ConditionalGet#combine_etags` method,
and therefore `ActionController::EtagWithTemplateDigest` module via
`etaggers` array.

`ActionController::EtagWithTemplateDigest` module requires a template
(view).

We have no views in ActiveStorage, so `EtagWithTemplateDigest` is
now turned off in ActiveStorage controllers by
`etag_with_template_digest` class attribute.
2020-07-05 10:51:08 -04:00
..
assets/javascripts Defaults content_type to application/octet-stream 2020-01-07 10:30:56 -08:00
controllers Disable template digesting for Active Storage controllers 2020-07-05 10:51:08 -04:00
javascript/activestorage Defaults content_type to application/octet-stream 2020-01-07 10:30:56 -08:00
jobs/active_storage Discard ActiveStorage::AnalyzeJobs on ActiveRecord::RecordNotFound 2019-09-28 10:28:21 -04:00
models/active_storage Use Active Record signed IDs in Active Storage 2020-07-04 21:09:00 -04:00