Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
<execution forEvent="promote" class="org.wso2.carbon.registry.extensions.ServiceVersionExecutor"/>

 

Back to Top ^

...

<parameter>
Anchor
execution
execution

XML Syntax<execution forEvent<parameter name="" classvalue=""/>
Description

An executor is business logic that is executed once a state transition happens in a lifecycle. The execution element defines the event and the execution class that will be invoked at runtime.

Type

The element is defined under the <execution> element. The parameter element contains the name and value attributes itself. The parameter will be referred by its name attribute by the business logic that has been defined by the "class" attribute defined within the "<execution>" element and the corresponding parameter's value which is denoted by the value attribute will be used to compute the logic.

Type 
Default Value 
Fixed Values 
Mandatory/Optional 

...

AttributeDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
forEventDefines the event for which this execution should be performed. This gives user the flexibility to define executions for each eventname

The parameter will be referred by its name attribute by the business logic that has been defined by the "class" attribute defined within the "<execution>" element

  • currentEnvironment/targetEnvironment - denotes the resource path at the current and target state. Its String literal type.
  • service.mediatype/wsdl.mediatype/endpoint.mediatype - denotes the mime "MediaType" parameters.
     
classDefines the class that needs to be executed at runtime. A user must give the full, qualified name of a class that implements the Execution interface, as the value of the attribute classvalue parameter's value which is denoted by the value attribute will be used to compute the logic.     
Sample Implementations

...