diff --git a/CHANGELOG.md b/CHANGELOG.md index 420ba7658..dd12bea9d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,8 @@ You can find and compare releases at the [GitHub release page](https://github.co ## Unreleased +## v6.45.0 + ### Added - Cache query validation results https://github.com/nuwave/lighthouse/pull/2603 diff --git a/docs/6/performance/query-caching.md b/docs/6/performance/query-caching.md index 313822b3f..e6a1f8789 100644 --- a/docs/6/performance/query-caching.md +++ b/docs/6/performance/query-caching.md @@ -2,11 +2,14 @@ In order to speed up GraphQL query parsing, the parsed queries can be stored in the Laravel cache. -Query caching is enabled by default. You can define cache store and cache duration, see `config/lighthouse.php`. +Query caching is enabled by default. +You can define cache store and cache duration, see `config/lighthouse.php`. Make sure you flush the query cache when you deploy an upgraded version of the `webonyx/graphql-php` dependency: - php artisan cache:clear +```sh +php artisan cache:clear +``` ## Automated Persisted Queries @@ -17,11 +20,12 @@ APQ is enabled by default, but depends on query caching being enabled. ## Query validation caching -Lighthouse can cache the result of the query validation process as well. It only caches queries without errors. +Lighthouse can cache the result of the query validation process as well. +It only caches queries without errors. `QueryComplexity` validation can not be cached as it is dependent on the query, so it is always executed. -Query validation caching is disabled by default. You can enable it by setting `validation_cache.enable` to `true` in the -configuration in `config/lighthouse.php`. +Query validation caching is disabled by default. +You can enable it by setting `validation_cache.enable` to `true` in `config/lighthouse.php`. ## Testing caveats diff --git a/docs/master/performance/query-caching.md b/docs/master/performance/query-caching.md index 08bd9f400..e6a1f8789 100644 --- a/docs/master/performance/query-caching.md +++ b/docs/master/performance/query-caching.md @@ -2,11 +2,14 @@ In order to speed up GraphQL query parsing, the parsed queries can be stored in the Laravel cache. -Query caching is enabled by default. You can define cache store and cache duration, see `config/lighthouse.php`. +Query caching is enabled by default. +You can define cache store and cache duration, see `config/lighthouse.php`. Make sure you flush the query cache when you deploy an upgraded version of the `webonyx/graphql-php` dependency: - php artisan cache:clear +```sh +php artisan cache:clear +``` ## Automated Persisted Queries