﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
30765	"cache_control() ""max_age"" overrides cache_page() ""timeout"""	Danny Flack	Flavio Curella	"If you decorate a view with **both** `cache_control(max_age=3600)` and `cache_page(timeout=3600*24)`, the server side cache uses the `max_age` value instead of the `timeout` value.  

The comments in `UpdateCacheMiddleware.process_response()` indicate it's trying to set the timeout by first looking for the `max-age` header before reverting to the **default** cache_timeout :

**Try to get the timeout from the ""max-age"" section of the ""Cache-
Control"" header before reverting to using the default cache_timeout
length.**

However, `cache_page(timeout=3600*24)` is explicitly setting the `cache_timeout` so that is what should be used.  

In summary, if a user wants the client-side cache to be shorter-lived than the server-side cache, it is currently not possible using these two decorators.
"	Bug	closed	Core (Cache system)	2.2	Normal	fixed	cache_control cache_page UpdateCacheMiddleware CacheMiddleware		Accepted	1	0	0	0	0	0
