IBackgroundTaskHandler - DitaDeliveryUpdatePublicationMetadata
Updates the publication metadata in Dynamic Delivery with the fields provided in the configuration parameters.
Input data
The input data XML identifies an output format, version or a publication output.
- ishobject @ishref
-
Defines the identifer of the logical level.
- Required:
yes
- Required:
- ishobject @ishlngref
-
Defines the identifier of the language level.
- Required:
no
- Required:
- ishfields
-
A Metadata XML structure that holds information about the fields that need to be updated.
- Required:
no
- Required:
Input data examples
This XML example shows typical event input data for this background task if there was a change on the logical level:
<ishobject ishref="GUID-AB4876AC-D7C9-401F-8701-FBDD6D4ED627" ishtype="ISHPublication">
<ishfields>
<ishfield name="FISHPRODUCTFAMILY" level="logical">SDL Knowledge Center 2016</ishfield>
</ishfields>
<ishchanges>
<ishchange sequence="2">
<ishfieldchange name="FISHPRODUCTFAMILY" level="logical" ishvaluetype="value">SDL Knowledge Center 2016</ishfieldchange>
</ishchange>
<ishchange sequence="1">
<ishfieldchange name="FISHPRODUCTFAMILY" level="logical" ishvaluetype="value">SDL LiveContent Architect 2014</ishfieldchange>
</ishchange>
</ishchanges>
</ishobject> This XML example shows typical event input data for this background task if there was a change on the version level:
<ishobject ishref="GUID-AB4876AC-D7C9-401F-8701-FBDD6D4ED627" ishtype="ISHPublication">
<ishfields>
<ishfield name="VERSION" level="version">1</ishfield>
<ishfield name="FISHPRODUCTRELEASENAME" level="version">SDL Knowledge Center</ishfield>
</ishfields>
<ishchanges>
<ishchange sequence="2">
<ishfieldchange name="FISHPRODUCTRELEASENAME" level="version" ishvaluetype="value">SDL Knowledge Center</ishfieldchange>
</ishchange>
<ishchange sequence="1">
<ishfieldchange name="FISHPRODUCTRELEASENAME" level="version" ishvaluetype="value"></ishfieldchange>
</ishchange>
</ishchanges>
</ishobject> This XML example shows typical event input data for this background task if there was a change on the language level:
<ishobject ishref="GUID-AB4876AC-D7C9-401F-8701-FBDD6D4ED627" ishtype="ISHPublication" ishlngref="1845703">
<ishfields>
<ishfield name="VERSION" level="version">1</ishfield>
<ishfield name="DOC-LANGUAGE" level="lng">iw</ishfield>
<ishfield name="FISHDITADLVRREMOTESTATUS" level="lng" ishvaluetype="element">VDITADLVRREMOTESTATUSONLINE</ishfield>
<ishfield name="FISHPUBSTATUS" level="lng" ishvaluetype="element">VPUBSTATUSPUBLISHEDDRAFT</ishfield>
</ishfields>
<ishchanges>
<ishchange sequence="2">
<ishfieldchange name="FISHPUBSTATUS" level="lng" ishvaluetype="element">VPUBSTATUSPUBLISHEDDRAFT</ishfieldchange>
</ishchange>
<ishchange sequence="1">
<ishfieldchange name="FISHPUBSTATUS" level="lng" ishvaluetype="element">VPUBSTATUSDEPLOYINGDRAFT</ishfieldchange>
</ishchange>
</ishchanges>
</ishobject>
Background task configuration
The list below describes the configurable parameters.- Action
-
The name of the command action to execute on a queue.
- Required:
yes - Default value:
none - Allowed values:
valid action name - Example:
IshPublish
- Required:
- Verbs
-
The names of the verbs that the queue operates upon. Multiple verbs need to be separated with ", " (comma+space).
- Required:
yes - Default value:
none - Allowed values:
valid verb names - Example:
IshPrepare, IshProcess
- Required:
- MatchPublicationOutputStatusElements
-
The element names of the publication output statuses that should match.
- Required:
yes - Default value:
none - Allowed values:
valid publication output status LOV values, separated by ', ' - Example:
VPUBSTATUSPUBLISHEDDRAFT, VPUBSTATUSPUBLISHEDRELEASECANDIDATE
- Required:
- WaitTimeBetweenChecks
-
Time between execution statuses checks. Note that the
WaitTimeBetweenChecksmultiplied with theMaximumNumberOfChecksshould be lower than thetimeoutattribute value specified on theexecutionelement of thehandler. See example below.- Required:
yes - Default value:
00:00:30 - Allowed values:
valid HH:mm:ss timespan value - Example:
see default value
- Required:
- MaximumNumberOfChecks
-
The maximum number of checks after which the background task stops and changes publication output status to
Failed.- Required:
yes - Default value:
100 - Allowed values:
valid number - Example:
see default value
- Required:
- RemoteTimeout
-
The timeout of the http request.
- Required:
no - Default value:
00:05:00 - Allowed values:
valid HH:mm:ss timespan value - Example:
see default value
- Required:
- RemoteNumberOfRetries
-
The number of times an http request is retried.
- Required:
no - Default value:
2 - Allowed values:
valid number - Example:
see default value
- Required:
- RemoteWaitTimeBetweenRetries
-
Time to wait between retries of the http request.
- Required:
no - Default value:
00:01:00 - Allowed values:
valid HH:mm:ss timespan value - Example:
see default value
- Required:
Default background task configuration example
The following configuration gets and handles a DITADELIVERYUPDATEPUBLICATIONMETADATA event from the background task queue:
<handler eventType="DITADELIVERYUPDATEPUBLICATIONMETADATA">
<scheduler executeSynchronously="false"/>
<authorization type="authenticationContext"/>
<execution timeout="01:00:00" recoveryGracePeriod="00:10:00" isolationLevel="None" useSingleThreadApartment="false"/>
<activator>
<net name="DitaDeliveryUpdatePublicationMetadata">
<parameters>
<parameter name="Action">IshPublish</parameter>
<parameter name="Verbs">IshPrepare, IshUpdate</parameter>
<parameter name="MatchPublicationOutputStatusElements">VPUBSTATUSPUBLISHEDDRAFT, VPUBSTATUSPUBLISHEDRELEASECANDIDATE</parameter>
<parameter name="WaitTimeBetweenChecksPerZip">00:00:30</parameter>
<parameter name="MaximumNumberOfChecks">100</parameter>
<parameter name="RemoteTimeout">00:05:00</parameter>
<parameter name="RemoteNumberOfRetries">2</parameter>
<parameter name="RemoteWaitTimeBetweenRetries">00:01:00</parameter>
</parameters>
</net>
</activator>
<errorHandler maximumRetries="0"/>
</handler>
Flow
- Prepares the overall package containing only publication metadata needed to be updated.
- Zips the prepared package.
- Uploads the zipped package to the deployer, generates an execution id and adds an execution record in the delivery platform database to signal that the package needs to be processed.
- Checks the execution status of the deploying package and waits until the package is processed.
- The task finishes with success if the package is processed successfully.
- The task finishes with failure if the package was processed with error.