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][Validator] Fix apc cache service & config#16795

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:3.0fromogizanagi:16793_validator_apc_cache_service
Jan 25, 2016
Merged

[FrameworkBundle][Validator] Fix apc cache service & config#16795

fabpot merged 1 commit intosymfony:3.0fromogizanagi:16793_validator_apc_cache_service
Jan 25, 2016

Conversation

@ogizanagi
Copy link
Contributor

QA
Bug fix?yes
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#16793
LicenseMIT
Doc PR-

Keep track of#16794 (comment)

NOTE: This PR is on standby. If#16822 is merged, this one might probably be closed, as everything will be done during the merge.

Copy link
Member

Choose a reason for hiding this comment

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

The previous deprecated notice says, the class ApcCache will be removed, not that the alias "APC" will be discontinued.
This is a new BC break

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

Three options then:

  1. trigger a deprecation in 2.8, now released ? (as a "bugfix": a missing deprecation notice)
  2. keep the ability to pass "apc", but trigger a new deprecation in 3.0. Then, remove this ability in 3.1
  3. keep the ability to pass "apc"

Copy link
Member

Choose a reason for hiding this comment

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

Given Symfony 3 had been released, the options 1 is not valid
Given it's a BC break, the option 2 is not valid. => Have to wait Symfony 4
IMO option 3 is the only one available

ping@nicolas-grekas

Copy link
Contributor

Choose a reason for hiding this comment

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

@jderusse I don't agree. There is no BC break in 3.0 if we remove the apc logic. Configuring apc in 3.0 does not work anyway.ApcCache does not exist anymore.

So we should go with option 1 as planned: Add missing deprecation in 2.8 and removevalidator.mapping.cache.apc service in 3.0

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

@Tobion : Thanks. See#16822 about this.

Copy link
Member

Choose a reason for hiding this comment

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

Removing the feature because it's not documented, mays be a point.
BUT, If someone use the configurationcache: apc with symfony 2.7, he never been warned about the deprecation. Upgrading to Symfony 3 lead to an error due to the missing class.
He may expect we fix the bug, instead of removing the feature.

Just my 2 cents and playing the devil's advocate. I understand the point, to cleanup this code 😉

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

In order to upgrade from symfony 2.7 to 3.0, he'll need to update to 2.8 first. Then adding the deprecation in 2.8 in a bugfix is the right thing to do, and no one should expect having this service anymore in 3.0.

I removed the BC flag from the PR description accordingly. The existence of thevalidator.mapping.cache.apc service and the removal of thevalidator.mapping.cache.doctrine.apc one in 3.0 (as well as its deprecation in 2.8 instead of first one) is a bug and should be fixed in both branches.

@Tobion
Copy link
Contributor

Status: Needs Work

@jderusse
Copy link
Member

Notice that servicevalidator.mapping.cache.doctrine.apchad been previously declared and merged (https://github.com/symfony/symfony/pull/14429/files) and documented (http://symfony.com/doc/current/reference/configuration/framework.html#reference-validation-cache) but then removed by@nicolas-grekas5aa4a3b

@ogizanagi
Copy link
ContributorAuthor

Yes, we can also notice that thevalidator.mapping.cache.doctrine.apc was afeature of 2.8. It would have been really strange to make this feature and deprecate it directly.
So everything seems to confirmthis line was unintentional and logically targeting thevalidator.mapping.cache.apc service instead.

@dunglas
Copy link
Member

👍 but theserializer.mapping.cache.apc service should have be deprecated has well and newserializer.mapping.cache.doctrine.apc created.

As the serializer and the validator only support Doctrine Cache, I don't see what thedoctrine in the service name brings.

@jakzal
Copy link
Contributor

Something went wrong here. Thevalidator.mapping.cache.doctrine.apc serviceexists in 2.8. Looks like it was deprecated in 2.8 instead ofvalidator.mapping.cache.apc, and then removed in master.

@ogizanagi
Copy link
ContributorAuthor

@jakzal : Yes, it's exactly what happened. But let's forget about this PR for now.
Instead, a decision should be taken first on#16822 where we should either:

What bothers me however is to deprecate a service in the same version it appeared. Maybe we should only fix the deprecation on the right service in 2.8, and then deprecatevalidator.mapping.cache.doctrine.apc as well asserializer.mapping.cache.doctrine.apc in 3.1, for a complete removal in 4.0...

@dunglas
Copy link
Member

👍 to merge this one.

@dunglas
Copy link
Member

Any update regarding this PR? This is a blocker to use Symfony 3 in prod.

/cc @symfony/deciders

@xabbuh
Copy link
Member

I would be in favour of merging this one and trigger a deprecation in 2.8.

@ogizanagi
Copy link
ContributorAuthor

I suggest removing the second commit in#16822 (I'll do it right now) and merge it first. The deprecation should be fixed in 2.8 anyway. Then merge this one if necessary, but everything should be properly updated during the merge of 2.8 into 3.0.

@jonathanbull
Copy link

Any update regarding this PR? It looks like a fresh Symfony project still features an invalidvalidator.mapping.cache.apc setting.

@wouterj
Copy link
Member

Isn't it better to just quickly fix this error by merging this or mine PRs and then later decide on whether more actions should be taken? Currently, Symfony 3 with validator mapping cache just doesn't work as it should: bad dev experience...

@peterrehm
Copy link
Contributor

Any update on this?

fabpot added a commit that referenced this pull requestJan 21, 2016
…tion (ogizanagi)This PR was merged into the 2.8 branch.Discussion----------[FrameworkBundle][Validator] Fix apc cache service deprecation| Q             | A| ------------- | ---| Bug fix?      | yes| New feature?  | no| BC breaks?    | no| Deprecations? | yes| Tests pass?   | yes| Fixed tickets | -| License       | MIT| Doc PR        | -Related to#16795I guess the deprecation was on the wrong service.Also, no deprecation notice was triggered about using `"apc"` as the value of the `framework.validation.cache` configuration option. This PR adds the missing deprecation.> 📝 _NOTE_: The standard edition will need to be updated [here](https://github.com/symfony/symfony-standard/blob/2.8/app/config/config_prod.yml#L6).Commits-------907bbec [FrameworkBundle][Validator] Fix apc cache service deprecation
@ogizanagi
Copy link
ContributorAuthor

@fabpot : Since#16822 is now merged, this one can be merged too in order to remove the last leftover of theframework.validation.cache.apc service :)

@fabpot
Copy link
Member

Thank you@ogizanagi.

@fabpotfabpot merged commit94a1728 intosymfony:3.0Jan 25, 2016
fabpot added a commit that referenced this pull requestJan 25, 2016
…g (ogizanagi)This PR was merged into the 3.0 branch.Discussion----------[FrameworkBundle][Validator] Fix apc cache service & config| Q             | A| ------------- | ---| Bug fix?      | yes| New feature?  | no| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets |#16793| License       | MIT| Doc PR        | -_Keep track of#16794 (comment)_NOTE_: This PR is on standby. If#16822 is merged, this one might probably be closed, as everything will be done during the merge.Commits-------94a1728 [FrameworkBundle][Validator] Fix apc cache service & config
@ogizanagiogizanagi deleted the 16793_validator_apc_cache_service branchJanuary 25, 2016 18:35
@fabpotfabpot mentioned this pull requestFeb 3, 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

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

11 participants

@ogizanagi@Tobion@jderusse@dunglas@jakzal@xabbuh@jonathanbull@wouterj@peterrehm@fabpot@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp