From 2c220c4a1d04b5d8263b18473994a97ec4cb8d08 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Thu, 1 Dec 2016 08:55:25 +0100 Subject: [PATCH 1/2] Added docs for the cache:pool:clear command --- components/cache/cache_pools.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/components/cache/cache_pools.rst b/components/cache/cache_pools.rst index f7fddbff78f..b2bdff66acb 100644 --- a/components/cache/cache_pools.rst +++ b/components/cache/cache_pools.rst @@ -278,4 +278,13 @@ when all items are successfully deleted):: // ... $cacheIsEmpty = $cache->clear(); +.. tip:: + + If the Cache component is used inside a Symfony application, you can remove + all the items of a given cache pool with the following command: + + .. code-block:: terminal + + $ ./bin/console cache:pool:clear + .. _`Doctrine Cache`: https://github.com/doctrine/cache From 3c31e09b26bece26cedd5426b31ee83414683567 Mon Sep 17 00:00:00 2001 From: Jules Pietri Date: Sat, 29 Jul 2017 13:59:18 +0200 Subject: [PATCH 2/2] applying comment from @wouterJ --- components/cache/cache_pools.rst | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/components/cache/cache_pools.rst b/components/cache/cache_pools.rst index b2bdff66acb..0f52c279c61 100644 --- a/components/cache/cache_pools.rst +++ b/components/cache/cache_pools.rst @@ -285,6 +285,12 @@ when all items are successfully deleted):: .. code-block:: terminal - $ ./bin/console cache:pool:clear + $ php bin/console cache:pool:clear + + # clears the "cache.app" pool + $ php bin/console cache:pool:clear cache.app + + # clears the "cache.validation" and "cache.app" pool + $ php bin/console cache:pool:clear cache.validation cache.app .. _`Doctrine Cache`: https://github.com/doctrine/cache