Skip to content

Conversation

@NutharaNR
Copy link
Contributor

Proposed changes in this pull request

Adding a new first class claim property 'enableUserStorePersistence'. This property is introduced to define the storing location of the values of the respective claim; whether the claim values should be stored in the USER_STORE or in the IDENTITY_DB.

Related:

Comment on lines 1290 to 1292
claimProperties.put(PROP_READ_ONLY, String.valueOf(localClaimReqDTO.getReadOnly()));
// TODO : Handle the case where enableUserStorePersistence is null by default.
claimProperties.put(PROP_ENABLE_USER_STORE_PERSISTENCE, String.valueOf(localClaimReqDTO.getEnableUserStorePersistence()));

Choose a reason for hiding this comment

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

Log Improvement Suggestion No: 12

Suggested change
claimProperties.put(PROP_READ_ONLY, String.valueOf(localClaimReqDTO.getReadOnly()));
// TODO : Handle the case where enableUserStorePersistence is null by default.
claimProperties.put(PROP_ENABLE_USER_STORE_PERSISTENCE, String.valueOf(localClaimReqDTO.getEnableUserStorePersistence()));
if (localClaimReqDTO.getEnableUserStorePersistence() != null) {
claimProperties.put(PROP_ENABLE_USER_STORE_PERSISTENCE, String.valueOf(localClaimReqDTO.getEnableUserStorePersistence()));
} else {
// Default behavior: enable user store persistence for non-identity claims
boolean enablePersistence = !localClaimReqDTO.getClaimURI().contains(IDENTITY_CLAIM_URI);
claimProperties.put(PROP_ENABLE_USER_STORE_PERSISTENCE, String.valueOf(enablePersistence));
}

@wso2-engineering-bot
Copy link

AI Agent Log Improvement Checklist

⚠️ Warning: AI-Generated Review Comments

  • The log-related comments and suggestions in this review were generated by an AI tool to assist with identifying potential improvements. Purpose of reviewing the code for log improvements is to improve the troubleshooting capabilities of our products.
  • Please make sure to manually review and validate all suggestions before applying any changes. Not every code suggestion would make sense or add value to our purpose. Therefore, you have the freedom to decide which of the suggestions are helpful.

✅ Before merging this pull request:

  • Review all AI-generated comments for accuracy and relevance.
  • Complete and verify the table below. We need your feedback to measure the accuracy of these suggestions and the value they add. If you are rejecting a certain code suggestion, please mention the reason briefly in the suggestion for us to capture it.
Comment Accepted (Y/N) Reason
#### Log Improvement Suggestion No: 12

@NutharaNR NutharaNR closed this Aug 26, 2025
@NutharaNR NutharaNR deleted the claim-store-location branch August 26, 2025 04:03
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.

3 participants