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

Add action execution component. #5810

Merged
merged 26 commits into from
Jul 29, 2024
Merged

Add action execution component. #5810

merged 26 commits into from
Jul 29, 2024

Conversation

malithie
Copy link
Member

@malithie malithie commented Jul 22, 2024

Proposed changes in this pull request

Implements the core framework to implement actions for wso2/product-is#20739

The framework incorporates following high level components.

ActionExecutorService:
This is the service that will be consumed by other components to trigger an action.
e.g:, OAuth component will consume this service to trigger an API configured to be invoked before issuing an access token.
This service is responsible for building the request that needs to be sent to the API, invoking the API and passing the response back in order to perform necessary state changes.

ActionExecutionRequestBuilder:
Downstream components invoking the ActionExecutorService needs to implement this request builder to build the request that needs to be passed to the external API extending the flow.
e.g: OAuth component will implement a request builder to build the event incorporating all access token related data that needs to be passed to the service extending the flow.

ActionExecutionResponseProcessor:
Downstream components invoking the ActionExecutorService needs to implement this response processor to receive the API response and to perform respective state changes within the flow.
e.g: OAuth component will implement a response processor to perform changes to the access token response based on the response of the service extending the flow.

ActionExecutionRequestBuilderFactory and ActionExecutionResponseProcessorFactory:
Each of these factories provides the ActionExecutionRequestBuilder and ActionExecutionResponseProcessor instances registered against action types to the ActionExecutorService.

When should this PR be merged

As approved

# Conflicts:
#	components/action-mgt/org.wso2.carbon.identity.action.execution/pom.xml
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/ActionExecutionRequestBuilder.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/ActionExecutionRequestBuilderFactory.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/ActionExecutionResponseProcessor.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/ActionExecutorService.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/ActionExecutorServiceImpl.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/exception/ActionExecutionException.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/exception/ActionInvocationException.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/model/ActionInvocationErrorResponse.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/model/ActionInvocationResponse.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/model/ActionInvocationSuccessResponse.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/model/ActionType.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/util/APIClient.java
#	components/action-mgt/org.wso2.carbon.identity.action.execution/src/main/java/org/wso2/carbon/identity/action/execution/util/AuthMethods.java
@malithie malithie marked this pull request as ready for review July 23, 2024 07:06
indeewari
indeewari previously approved these changes Jul 29, 2024
hwupathum
hwupathum previously approved these changes Jul 29, 2024
@malithie malithie merged commit 4ff4d1e into wso2:master Jul 29, 2024
2 checks passed
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.

5 participants