Skip to content

Commit a37025b

Browse files
committed
TASK: Convert http components to middlewares
In addition instead of checking the flow session the request is validated against cookie and parameter allow and ignore lists that can be defined via setting. ``` # requests have to fulfill certain conditions for beeing cached request: # !!! Only the http methods "GET" and "HEAD" are supported !!! # a request will only qualify for caching if it contains no cookieParams that # are not ignored. cookieParams: # ignored cookie params exclude cookies that are handled by the frontenecn # and are not relevant for the backend. A usecase would be gdpr consent cookies # if they are only used on the client side ignore: [] # a request will only qualify for caching if it only contains queryParams that # are allowed or ignored. All other arguments will prevent caching. queryParams: # allowed params become part of the cache identifier, use this for # arguments that modify the reponse but still allow caching like pagination allow: [] # ignored arguments are not part of the cache identifier but do not # prevent caching either. Use this for arguments that are meaningless for # the backend like utm_campaign ignore: [] ``` The creation of the 304 state is removed as the standardsCompliance middleware handles this already. Obviously the version requirement had to be raised.
1 parent 833a5d6 commit a37025b

11 files changed

Lines changed: 316 additions & 347 deletions

Classes/Aspects/ContentCacheAspect.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class ContentCacheAspect
2828
protected $cacheFrontend;
2929

3030
/**
31-
* @Flow\Before("method(Neos\Fusion\Core\Cache\ContentCache->createUncachedSegment())")
31+
* @Flow\Before("method(Neos\Fusion\Core\Cache\ContentCache->(createUncachedSegment|replaceUncachedPlaceholders)())")
3232
*/
3333
public function grabUncachedSegment(JoinPointInterface $joinPoint)
3434
{

Classes/Http/CacheControlHeaderComponent.php

Lines changed: 0 additions & 103 deletions
This file was deleted.

Classes/Http/RequestInterceptorComponent.php

Lines changed: 0 additions & 127 deletions
This file was deleted.

Classes/Http/RequestStorageComponent.php

Lines changed: 0 additions & 88 deletions
This file was deleted.

0 commit comments

Comments
 (0)