Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature #23792 [HttpKernel][FrameworkBundle] Add RebootableInterface,…
… fix and un-deprecate cache:clear with warmup (nicolas-grekas) This PR was merged into the 3.4 branch. Discussion ---------- [HttpKernel][FrameworkBundle] Add RebootableInterface, fix and un-deprecate cache:clear with warmup | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | yes | Tests pass? | yes | Fixed tickets | #23592, #8500 | License | MIT | Doc PR | - This PR fixes the reasons why we deprecated cache:clear without --no-warmup. Internally, it requires some cooperation from the Kernel, so that a deprecation is needed. This allows the same kernel instance to be rebooted under a new cache directory, used during the warmup. It leverages the new capability to create two independent non colliding containers. Commits ------- a4fc492 [HttpKernel][FrameworkBundle] Add RebootableInterface, fix and un-deprecate cache:clear with warmup
- Loading branch information
Showing
6 changed files
with
98 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the Symfony package. | ||
* | ||
* (c) Fabien Potencier <fabien@symfony.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Symfony\Component\HttpKernel; | ||
|
||
/** | ||
* Allows the Kernel to be rebooted using a temporary cache directory. | ||
* | ||
* @author Nicolas Grekas <p@tchwork.com> | ||
*/ | ||
interface RebootableInterface | ||
{ | ||
/** | ||
* Reboots a kernel. | ||
* | ||
* The getCacheDir() method of a rebootable kernel should not be called | ||
* while building the container. Use the %kernel.cache_dir% parameter instead. | ||
* | ||
* @param string|null $warmupDir pass null to reboot in the regular cache directory | ||
*/ | ||
public function reboot($warmupDir); | ||
} |