Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[FrameworkBundle] Add cache:pool:clear command#19891

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fabpot merged 1 commit intosymfony:masterfromnicolas-grekas:cache-pool-clearer
Sep 14, 2016

Conversation

@nicolas-grekas
Copy link
Member

QA
Branch?master
New feature?yes
Tests pass?yes
LicenseMIT

Useful when deploying apps to get better control of cache pool clearing.

@Koc
Copy link
Contributor

Koc commentedSep 9, 2016

oh, yesterday I was thinking about it and want to create PR. You are the faster than me :D


if ($pool instanceof CacheItemPoolInterface) {
$pools[$id] = $pool;
} elseif ($pool instanceof CacheClearerInterface) {
Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

should beinstanceof Psr6CacheClearer

}

foreach ($clearers as $id => $clearer) {
$io->comment(sprintf('Calling cache clearer: <info>%s</info>', $id));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I think the clearer/pool specific messages should be displayed only if the output is verbose and maybe a global comment should be added before e.g. "Clearing the cache for pools ...", wdyt?

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I don't know :) Doesn't look verbose to me. (Not as an exception trace e.g.). So I'll follow any advises.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Sure, it's not very verbose until you have a lot of pools, I just refer to the clear cache command which hide details by default

{
$this
->setName('cache:pool:clear')
->setDefinition(array(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Just interesting - why not useaddArgument here?

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

All the other commands usesetDefinition, that's the reason :)

@fabpot
Copy link
Member

Thank you@nicolas-grekas.

@fabpotfabpot merged commit37c5b18 intosymfony:masterSep 14, 2016
fabpot added a commit that referenced this pull requestSep 14, 2016
…s-grekas)This PR was merged into the 3.2-dev branch.Discussion----------[FrameworkBundle] Add cache:pool:clear command| Q             | A| ------------- | ---| Branch?       | master| New feature?  | yes| Tests pass?   | yes| License       | MITUseful when deploying apps to get better control of cache pool clearing.Commits-------37c5b18 [FrameworkBundle] Add cache:pool:clear command
@nicolas-grekasnicolas-grekas deleted the cache-pool-clearer branchSeptember 14, 2016 19:25
@fabpotfabpot mentioned this pull requestOct 27, 2016
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@nicolas-grekas@Koc@fabpot@unkind@chalasr

[8]ページ先頭

©2009-2025 Movatter.jp