Skip to content

JPA map storage: Client scope no-downtime store#9746

Merged
hmlnarik merged 1 commit intokeycloak:mainfrom
vramik:#9663-client-scopes-jpa-store
Feb 1, 2022
Merged

JPA map storage: Client scope no-downtime store#9746
hmlnarik merged 1 commit intokeycloak:mainfrom
vramik:#9663-client-scopes-jpa-store

Conversation

@vramik
Copy link
Copy Markdown
Contributor

@vramik vramik commented Jan 24, 2022

Closes #9663

@vramik vramik added area/storage Indicates an issue that touches storage (change in data layout or data manipulation) kind/enhancement Categorizes a PR related to an enhancement team/storage-sig labels Jan 24, 2022
@vramik vramik requested review from ahus1 and sguilhen January 24, 2022 12:21
ahus1
ahus1 previously approved these changes Jan 24, 2022
Copy link
Copy Markdown
Member

@ahus1 ahus1 left a comment

Choose a reason for hiding this comment

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

LGTM. I reviewed the code and started it locally. Client scopes were filled, and I could edit a client scope. Thanks!

@vramik vramik force-pushed the #9663-client-scopes-jpa-store branch from 383cdce to 45e6356 Compare January 26, 2022 08:52
ahus1
ahus1 previously approved these changes Jan 26, 2022
@vramik vramik force-pushed the #9663-client-scopes-jpa-store branch 3 times, most recently from 2e75a55 to 62382bf Compare January 28, 2022 12:59
Copy link
Copy Markdown
Contributor

@hmlnarik hmlnarik left a comment

Choose a reason for hiding this comment

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

Thank you @vramik, it now looks much better. Please see comments inline

@vramik vramik force-pushed the #9663-client-scopes-jpa-store branch from 62382bf to b320888 Compare January 28, 2022 19:00
Comment thread model/map-jpa/src/main/java/org/keycloak/models/map/storage/jpa/Constants.java Outdated
@vramik vramik force-pushed the #9663-client-scopes-jpa-store branch from b320888 to c6812e7 Compare January 30, 2022 10:58
@hmlnarik hmlnarik force-pushed the #9663-client-scopes-jpa-store branch 2 times, most recently from 47edf35 to 4975cc3 Compare January 31, 2022 19:20
Copy link
Copy Markdown
Member

@ahus1 ahus1 left a comment

Choose a reason for hiding this comment

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

Tested the code locally and found that keycloak didn't start up as the selected columns didn't match the constructors for the recently added "version" column. The version column is required to identify optimistic locking issues during lazy loading and was introduced in #9645

@hmlnarik hmlnarik force-pushed the #9663-client-scopes-jpa-store branch 2 times, most recently from 48d3d49 to aaf846b Compare February 1, 2022 09:56
@hmlnarik hmlnarik requested a review from ahus1 February 1, 2022 10:05
Copy link
Copy Markdown
Member

@ahus1 ahus1 left a comment

Choose a reason for hiding this comment

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

I reviewed the changes and tested them locally. Local test was successful.

One open review comment remains on Integer vs. int on the method signature of JpaClientScopeEntity

@hmlnarik hmlnarik force-pushed the #9663-client-scopes-jpa-store branch from aaf846b to 0dd3e0a Compare February 1, 2022 10:55
@hmlnarik
Copy link
Copy Markdown
Contributor

hmlnarik commented Feb 1, 2022

I reviewed the changes and tested them locally. Local test was successful.

One open review comment remains on Integer vs. int on the method signature of JpaClientScopeEntity

Thanks for spotting this, indeed, this needs to be consistent with the rest of the codebase.

@ahus1 ahus1 self-requested a review February 1, 2022 11:11
Copy link
Copy Markdown
Member

@ahus1 ahus1 left a comment

Choose a reason for hiding this comment

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

LGTM - ready to be merged. All previous comments can be resolved (can only be done by PR author or someone with write access to the repository)

@hmlnarik hmlnarik merged commit 13e02d5 into keycloak:main Feb 1, 2022
@vramik vramik deleted the #9663-client-scopes-jpa-store branch February 2, 2022 12:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/storage Indicates an issue that touches storage (change in data layout or data manipulation) kind/enhancement Categorizes a PR related to an enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

JPA map storage: Client scope no-downtime store

4 participants