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

[DI][Router][DX] Invalidate routing cache when container parameters changed#21767

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:masterfromogizanagi:feature/container_parameters_resource
Mar 5, 2017
Merged

[DI][Router][DX] Invalidate routing cache when container parameters changed#21767

fabpot merged 1 commit intosymfony:masterfromogizanagi:feature/container_parameters_resource
Mar 5, 2017

Conversation

@ogizanagi
Copy link
Contributor

@ogizanagiogizanagi commentedFeb 26, 2017
edited
Loading

QA
Branch?master
Bug fix?yes
New feature?yes
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#21426
LicenseMIT
Doc PRN/A

Supersedes#21443 but only for master.

Indeed, this implementation uses a new feature: aContainerParametersResource which compares cached containers parameters (collected at some point, here by theRouter) with current ones in the container.

On the contrary of the previous PR targeting 2.7, this will only invalidate routing cache when parameters actually used in the routes changed and will avoid always rebuilding the routing cache when the container is rebuilt, just to catch the edge case of someone modifying a parameter.

@carsonbotcarsonbot added Status: Needs Review DependencyInjection Routing DXDX = Developer eXperience (anything that improves the experience of using Symfony) Bug Feature labelsFeb 26, 2017
@nicolas-grekasnicolas-grekas added this to the3.3 milestoneFeb 27, 2017
@weaverryan
Copy link
Member

👍 Nice work!

private $parameters;

/**
* @param array $parameters The container parameters values to track
Copy link
Member

Choose a reason for hiding this comment

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

I would remove "values" here.

return false;
}
}
} catch (ParameterNotFoundException $exception) {
Copy link
Member

Choose a reason for hiding this comment

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

Why not callinghasParameter() instead?

@ogizanagi
Copy link
ContributorAuthor

Thanks for the review.@xabbuh's comments addressed.

@xabbuh
Copy link
Member

👍

@fabpot
Copy link
Member

Thank you@ogizanagi.

@fabpotfabpot merged commitfad4d9e intosymfony:masterMar 5, 2017
fabpot added a commit that referenced this pull requestMar 5, 2017
…er parameters changed (ogizanagi)This PR was merged into the 3.3-dev branch.Discussion----------[DI][Router][DX] Invalidate routing cache when container parameters changed| Q             | A| ------------- | ---| Branch?       | master| Bug fix?      | yes| New feature?  | yes| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets |#21426| License       | MIT| Doc PR        | N/ASupersedes#21443 but only for master.Indeed, this implementation uses a new feature: a `ContainerParametersResource` which compares cached containers parameters (collected at some point, here by the `Router`) with current ones in the container.On the contrary of the previous PR targeting 2.7, this will only invalidate routing cache when parameters actually used in the routes changed and will avoid always rebuilding the routing cache when the container is rebuilt, just to catch the edge case of someone modifying a parameter.Commits-------fad4d9e [DI][Router][DX] Invalidate routing cache when container parameters changed
@ogizanagiogizanagi deleted the feature/container_parameters_resource branchMarch 5, 2017 19:48
@fabpotfabpot mentioned this pull requestMay 1, 2017
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@xabbuhxabbuhxabbuh left review comments

Assignees

No one assigned

Labels

BugDependencyInjectionDXDX = Developer eXperience (anything that improves the experience of using Symfony)FeatureRoutingStatus: Needs Review

Projects

None yet

Milestone

3.3

Development

Successfully merging this pull request may close these issues.

6 participants

@ogizanagi@weaverryan@xabbuh@fabpot@nicolas-grekas@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp