Package oracle.iam.platform.kernel.spi
Interface ValidationHandler
- All Superinterfaces:
oracle.iam.platform.kernel.spi.EventHandler
public interface ValidationHandler
extends oracle.iam.platform.kernel.spi.EventHandler
Validation Handler
- Validation event handlers can look at the operation, new entity, old entity and can decide if the operation can proceed or not.
- If the validation cannot be performed, e.g., the event handler cannot be executed by the orchestration, ValidationFailedException is thrown.
- By default a system validation will be called to make sure the action can be performed, and that action is available to be performed. If the validation fails, it throws ValidationFailedException, as opposed to throwing ValidationException.
- If no event handlers are defined in this stage, we automatically proceed to "Pre-process Stage". (However the system validation for the action is still performed.)
- Event Handlers in this stage are always synchronous.
- Event Handlers can either throw ValidationException to move the process into "Invalid Stage", or simply return to continue with the next validation, or throw a ValidationFailedException to move the process into "Validation Failed Stage".
- If one validation throws either ValidationFailedException or ValidationException then remaining validations are not executed
<validation-handler orch-target="oracle.iam.platform.kernel.vo.SampleOrchestrationTarget" class="oracle.iam.platform.kernel.test.SampleValidateHandler" entity-type="oracle.iam.platform.kernel.impl.Address" operation="E2" name="Validate" order="LAST" sync="TRUE" />
-
Method Summary
Modifier and TypeMethodDescriptionvoid
validate
(long processId, long eventId, BulkOrchestration orchestration) Method containing the actual implementation for validating current orchestration and its data for bulk orchestrationvoid
validate
(long processId, long eventId, Orchestration orchestration) Method containing the actual implementation for validating current orchestration and its dataMethods inherited from interface oracle.iam.platform.kernel.spi.EventHandler
initialize
-
Method Details
-
validate
void validate(long processId, long eventId, Orchestration orchestration) throws ValidationException, oracle.iam.platform.kernel.ValidationFailedException Method containing the actual implementation for validating current orchestration and its data- Parameters:
processId
- , Id of the orchestration processeventId
- , Id of the orchestartion eventorchestration
- , Value object containing information such as orchestartion parameters, operation.- Throws:
ValidationException
- This exception is thrown to move the process to invalid stageoracle.iam.platform.kernel.ValidationFailedException
- This exception is thrown if the validation fails
-
validate
void validate(long processId, long eventId, BulkOrchestration orchestration) throws ValidationException, oracle.iam.platform.kernel.ValidationFailedException Method containing the actual implementation for validating current orchestration and its data for bulk orchestration- Parameters:
processId
- , Id of the orchestration processeventId
- , Id of the orchestartion eventorchestration
- , Value object containing information such as orchestartion parameters, operation.- Throws:
ValidationException
- This exception is thrown to move the process to invalid stageoracle.iam.platform.kernel.ValidationFailedException
- This exception is thrown if the validation fails
-