Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lifecycle callbacks on embeddables, possible or not? #6855

Closed
holtkamp opened this issue Nov 28, 2017 · 4 comments
Closed

Lifecycle callbacks on embeddables, possible or not? #6855

holtkamp opened this issue Nov 28, 2017 · 4 comments

Comments

@holtkamp
Copy link
Contributor

holtkamp commented Nov 28, 2017

Encountered behaviour where embeddables seem not to respect lifecycle callbacks, but do "listen" to a given configuration, as also described here.

The documentation does not mention embeddables, so I suppose it is not supported. If so: might be good to document this more explicitly?

The strange thing: when defining a lifecycle callback that points to a non-existing function: an exception is thrown, so the definition is respected.

@Ocramius
Copy link
Member

Ocramius commented Nov 28, 2017 via email

@holtkamp
Copy link
Contributor Author

holtkamp commented Nov 28, 2017

Wow, < 1 minute response time, raspact!

Should I submit a PR for the documentation on the Entity LifeCycle to explicitly indicate this will not work for embeddables? Or... is that too much 😉 . Maybe others have the same "use case".

@Ocramius
Copy link
Member

Ocramius commented Nov 28, 2017 via email

@holtkamp
Copy link
Contributor Author

This behaviour is also discussed in #4568, and can maybe be covered using https://packagist.org/packages/tarifhaus/doctrine-nullable-embeddable

greg0ire pushed a commit to holtkamp/doctrine2 that referenced this issue Feb 17, 2020
beberlei added a commit to beberlei/doctrine2 that referenced this issue Dec 7, 2020
beberlei added a commit to beberlei/doctrine2 that referenced this issue Mar 1, 2021
beberlei added a commit that referenced this issue Mar 4, 2021
@greg0ire greg0ire closed this as completed Mar 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants