Skip to content

Add versioning support for Pre-Issue Access Token action (v1)#3009

Draft
Lashen1227 wants to merge 14 commits intowso2-extensions:masterfrom
Lashen1227:feat/v1/pre-issue-access-token-action-token-exchange
Draft

Add versioning support for Pre-Issue Access Token action (v1)#3009
Lashen1227 wants to merge 14 commits intowso2-extensions:masterfrom
Lashen1227:feat/v1/pre-issue-access-token-action-token-exchange

Conversation

@Lashen1227
Copy link
Copy Markdown
Member

@Lashen1227 Lashen1227 commented Jan 5, 2026

This pull request introduces versioning support for the Pre-Issue Access Token action in the OAuth component. It adds new classes and factories to handle version-specific logic, integrates the versioning handler into the service component, and includes minor improvements and bug fixes related to grant handling and token audience assignment.

Versioning support for Pre-Issue Access Token action:

  • Added PreIssueAccessTokenActionConstants to define version constants for the action.
  • Implemented PreIssueAccessTokenActionVersioningHandler to handle versioning logic for the Pre-Issue Access Token action, checking if the action can be executed based on the grant type.
  • Introduced ActionTriggerEvaluatorFactory and ActionTriggerEvaluatorForVersion to provide version-specific trigger evaluation logic, currently supporting version "v1".
  • Added PreIssueAccessTokenRequestBuilderFactory to create request builders based on the action version.
  • Registered the new versioning handler in OAuthServiceComponent for dependency injection and service discovery.

Copy link
Copy Markdown
Contributor

@wso2-engineering wso2-engineering bot left a comment

Choose a reason for hiding this comment

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

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: 1
#### Log Improvement Suggestion No: 2
#### Log Improvement Suggestion No: 4
#### Log Improvement Suggestion No: 5
#### Log Improvement Suggestion No: 6
#### Log Improvement Suggestion No: 7
#### Log Improvement Suggestion No: 8
#### Log Improvement Suggestion No: 9
#### Log Improvement Suggestion No: 10
#### Log Improvement Suggestion No: 11
#### Log Improvement Suggestion No: 12
#### Log Improvement Suggestion No: 13
#### Log Improvement Suggestion No: 14
#### Log Improvement Suggestion No: 15
#### Log Improvement Suggestion No: 16

@codecov
Copy link
Copy Markdown

codecov bot commented Jan 13, 2026

Codecov Report

❌ Patch coverage is 51.00402% with 122 lines in your changes missing coverage. Please review.
✅ Project coverage is 57.74%. Comparing base (f4e024f) to head (1882d85).

Files with missing lines Patch % Lines
...ioning/v1/PreIssueAccessTokenRequestBuilderV1.java 61.34% 61 Missing and 14 partials ⚠️
...n/versioning/ActionTriggerEvaluatorForVersion.java 0.00% 14 Missing ⚠️
...on/PreIssueAccessTokenActionVersioningHandler.java 0.00% 9 Missing ⚠️
...dlers/grant/AbstractAuthorizationGrantHandler.java 12.50% 6 Missing and 1 partial ⚠️
...tion/versioning/ActionTriggerEvaluatorFactory.java 0.00% 6 Missing ⚠️
...identity/oauth/internal/OAuthServiceComponent.java 0.00% 5 Missing ⚠️
...handlers/grant/ActionVersioningHandlerFactory.java 0.00% 4 Missing ⚠️
...ning/PreIssueAccessTokenRequestBuilderFactory.java 66.66% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #3009      +/-   ##
============================================
- Coverage     58.77%   57.74%   -1.03%     
- Complexity     9933    10022      +89     
============================================
  Files           701      707       +6     
  Lines         54577    57376    +2799     
  Branches      12697    13052     +355     
============================================
+ Hits          32078    33134    +1056     
- Misses        18256    19841    +1585     
- Partials       4243     4401     +158     
Flag Coverage Δ
unit 42.43% <51.00%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jenkins-is-staging
Copy link
Copy Markdown

PR builder started
Link: https://github.com/wso2/product-is/actions/runs/20947509188

@jenkins-is-staging
Copy link
Copy Markdown

PR builder completed
Link: https://github.com/wso2/product-is/actions/runs/20947509188
Status: success

Copy link
Copy Markdown

@jenkins-is-staging jenkins-is-staging left a comment

Choose a reason for hiding this comment

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

Approving the pull request based on the successful pr build https://github.com/wso2/product-is/actions/runs/20947509188

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Feb 12, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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.

2 participants