FeatureFuel
1

`CACHE_ENABLED` should not affect `CACHE_CONTROL_S_MAXAGE`

Source: directus/directus#24887 · opened by @viters
Describe the Bug


If I define CACHE_CONTROL_S_MAXAGE > 0 and set CACHE_ENABLED = false, Cache-Control header is set to no-cache. In my opinion I should be able to set s-maxage without enabling Directus internal cache system.

The workaround now is to create a hook that would modify Cache-Control before response is sent.

Expected behavior


CACHE_CONTROL_S_MAXAGE = 600 and CACHE_ENABLED = false should result in response with header Cache-Control: (public/private same as CACHE_ENABLED=true), s-maxage=600.

Errors Shown


_No response_

What version of Directus are you using?


9.19.1

What version of Node.js are you using?


N/A

What database are you using?


N/A

What browser are you using?


N/A

How are you deploying Directus?


N/A

No pledges yet. Be the first to back this.

Make a pledge

Pledge your monetary support if this feature is added.

$

Comments

No comments yet.

Replying to

Add a comment

What do you think about this feature request?


Similar requests