-
Notifications
You must be signed in to change notification settings - Fork 170
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
[2.7] Close #1806 - Have to the ability to dynamically set the Validation Group during a transaction #2010
base: 2.7
Are you sure you want to change the base?
Conversation
Hello Eclipselink team, hoping for comment and suggested improvements. Thank you |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- For functional changes like this we expect some test (in this case integration test). Please check and maybe extend
jpa/eclipselink.jpa.test/src/org/eclipse/persistence/testing/tests/jpa/beanvalidation/BeanValidationJunitTest.java
- Please ensure, that copyright year in the modified files is updated.
@@ -319,6 +319,21 @@ public class EntityManagerProperties { | |||
* ) | |||
*/ | |||
public static final String COMPOSITE_UNIT_PROPERTIES = PersistenceUnitProperties.COMPOSITE_UNIT_PROPERTIES; | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are properties bellow limited to EntityManager only or should be defined in PersistenceUnit scope?
I think, that PersistenceUnit scope should be used. Please check e.g. how PU property is stored and handled
#1790 (foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/sessions/Project.java
, jpa/org.eclipse.persistence.jpa/src/org/eclipse/persistence/internal/jpa/EntityManagerSetupImpl.java
, foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/config/PersistenceUnitProperties.java
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I intended them to be Entity Manager Properties, since we could allow them to be changed in a transaction. I believe the PersistenceUnit already has support for this feature, but it can't be changed dynamically, hence the reason for this enhancement. I hope that makes sense! Please let me know if it doesn't or if my reasoning is not correct.
Thank you for the direction! I really appreciate it. We'll get to work on these things. |
This pul isn't abandoned, just still figuring out how to write tests :) |
…Validation Group during a transaction
2f39761
to
ce8a62e
Compare
Hello, this PR Close #1806 for the 2.7 branch. The goal here is to allow a user to specify a validation group that should be executed when persisting. I'm hoping to sort of model this how the schema-per-tenant properties work (Which is very handy btw).
I have a signed ECA, but this is my first PR for EclipseLink so I could use some feedback. If this gets merged, then I'll port the changes to the other branches seeing active development.
Thank you!