ObjectExtension
An object extension can be assigned to various core Cloud Director objects, at various phases of their related workflows so that they can be customized in behavior. The assignment can be made toward any-, or specific objects of a particular selector type. The assignment is represented by a selector extension. The object extension defines the communication channel between Cloud Director and the extension's backend. It can optionally narrow down the list of selector types to which it applies, otherwise it applies to any selector type.
A selector extension(see selectorTypes
below) specifies one or more phases where an extension is assigned. Each phase may be optional
and of type BLOCKING
or ASYNC
. Blocking phases cause the workflow execution to wait for the extension to respond. In case of any errors(either in the communication channel itself, or the extension response), Cloud Director sends a final message of type ErrorMessageEnvelope
and will cause the workflow to fail if the extension is not optional.
The communication(request and/or response) between Cloud Director and the extension uses messages of type HalfDuplexEnvelope
. The embedded payload is specific to each phase/workflow. The extension may report an error by returning payload of type ExtensionErrorMessage
in the envelope.
{
"id": "string",
"channel": {
"name": "string",
"id": "string"
},
"enabled": false,
"selectorTypes": [
"string"
]
}
The unique id of the extension
Only enabled object extensions are considered for the workflow executions.
An enum set of selector types to which this object extension can be applied. If not specified(missing, null or empty), this extension applies to any selector type. Valid selector types are:
- urn:selector:providerVdc
- urn:selector:organizationVdc
- urn:selector:organization
Create a selector extension to assign an object extension to a group of- or particular objects of a selector type:
HTTP Verb | Request URL Prototype | Summary |
---|---|---|
POST | host/api/admin/{type}/extension | any object of the selector type(default policy) |
POST | host/api/admin/{type}/{selectorId}/extension | specific object of the selector type(overriden policy) |
where the mapping between the selector type and the type is:
Selector type | type |
---|---|
urn:selector:providerVdc | providervdcs |
urn:selector:organizationVdc | vdcs |
urn:selector:organization | orgs |