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

Added UUID entity. #793

Merged
merged 4 commits into from
Jan 19, 2022
Merged

Added UUID entity. #793

merged 4 commits into from
Jan 19, 2022

Conversation

Tomas-Kraus
Copy link
Contributor

Signed-off-by: Tomas Kraus tomas.kraus@oracle.com


name: Pull Request
about: Create a pull request for a Platform TCK change
title: JPA UUID Test
labels:
assignees: Tomas-Kraus


Fixes Issue
jakartaee/persistence#319

Related Issue(s)
jakartaee/persistence#151
jakartaee/persistence#152

Describe the change
Simple test to verify EM persist of an entity class with UUID.

Additional context
N/A

CC @alwin-joseph @anajosep @arjantijms @cesarhernandezgt @dblevins @m0mus @edbratt @gurunrao @jansupol @jgallimore @kazumura @kwsutter @LanceAndersen @bhatpmk @RohitKumarJain @shighbar @gthoman @brideck @scottmarlow @lukasj

Signed-off-by: Tomas Kraus <tomas.kraus@oracle.com>
@Tomas-Kraus Tomas-Kraus marked this pull request as draft January 3, 2022 14:19
@Tomas-Kraus
Copy link
Contributor Author

Keeping this as draft. This PR requires UUID JPA spec change to be merged and JPA Spec Assertion IDs to be updated.

@gavinking
Copy link

Nice.

@jgrassel
Copy link
Member

(heard that my code review comment isn't visible):
Shouldn't there be a call to EntityManager.clear() after the flush() to force the provider-impl to fetch from the database? Otherwise, the provider-impl will just short-circuit to fetching what's already in the persistence context and will not have to make a fetch request to the database.

@Tomas-Kraus
Copy link
Contributor Author

@jgrassel I did not see your comment in the code. But adding clear is not a problem. I can do it with Spec Assertion IDs update.

Signed-off-by: Tomas Kraus <tomas.kraus@oracle.com>
@Tomas-Kraus Tomas-Kraus marked this pull request as ready for review January 18, 2022 13:57
@Tomas-Kraus
Copy link
Contributor Author

This PR contains JPA 3.1 spec assertions IDs update.

@Tomas-Kraus
Copy link
Contributor Author

JPA API 3.1.0-RC2 is in central. Test must be verified using this latest API.

Signed-off-by: Tomas Kraus <tomas.kraus@oracle.com>
@scottmarlow scottmarlow self-requested a review January 18, 2022 17:39
Copy link
Contributor

@scottmarlow scottmarlow left a comment

Choose a reason for hiding this comment

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

testCreateUUIDType() seems to be missing the call to EntityManager.clear() which from previous comments, I expected to see added.

Signed-off-by: Tomas Kraus <tomas.kraus@oracle.com>
@Tomas-Kraus
Copy link
Contributor Author

Tomas-Kraus commented Jan 18, 2022

Yes, I forgot it. Should be OK now.
@alwin-joseph Alwin, please can you test this with JPA API 3.1.0-RC2?
I can't build master branch now. Have build errors in

 [ts.javac] /data/metro/build-tck/src/com/sun/ts/tests/jacc/provider/TSPolicyConfigurationFactoryImpl.java:38: error: TSPolicyConfigurationFactoryImpl is not abstract and does not override abstract method getPolicyConfiguration() in PolicyConfigurationFactory

@scottmarlow scottmarlow merged commit feb60a9 into jakartaee:master Jan 19, 2022
@Tomas-Kraus Tomas-Kraus deleted the jpa_uuid branch March 17, 2022 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants