An APS task fails with an error message that states 'Document not well-formed', as in the example below:
Application script structured output is not valid. Reason: 'Document not well-formed.'. Details: 'Configure mailbox script was called'
When it runs, the configuration script provides output which does not conform to the declared schema.
Parallels Operations Automation (POA) before version 5.4 silently ignored the output of a configuration script if it did not conform to the schema. However, starting from POA 5.4, an APS task fails in such a case.
In addition, after upgrading to 5.4.10, POA mistakenly tries to process the output of provisioning scripts as 'structured-output' for applications with APS version less than 1.2. Structured output is only supported by APS applications starting from version 1.2.
As a result, even if the APS provisioning script did not present an error (the script just provided a diagnostic message), POA 5.4.10/5.4.11 will erroneously mark the task as failed since POA cannot parse the script output correctly (because it does not conform to 'structured-output').
Additionally it could happen when the APS instance configure script has ECHO ON parameter which will break the output structure sent to POA and can result in this error.
If ECHO ON is the value configured configure.bat then change it to ECHO OFF and see if it resolves the issue.
If you have POA 5.4.10 or 5.4.11 and applications with APS version before 1.2 cannot be installed because POA mistakenly tries to parse provisioning script as 'structured-output', this problem will be solved in the upcoming update POA 5.4.12.
In the meantime, the problem may be solved like this:
Carefully analyze the output provided by the APS configuration script
If the output does not contain any error messages, it means the script was executed successfully and provided some output which cannot be parsed by POA
- If - and only if - you are sure that the script was executed successfully, cancel the failing task in POA
Important! The solution above should only be applied if all the conditions below are true:
POA 5.4.10 or 5.4.11 is installed
An APS task fails with the error message Application script structured output is not valid. Reason: 'Document not well-formed'
- The APS version of the problem application is below 1.2
Otherwise, the problem may be solved in one of two ways:
If structured output is not required for the APS application configuration script, the
<structured-output />element should be removed from the
configuration-scriptelement in the APP-META.xml file in the APS application package. The application then needs to be repacked and re-imported into POA. Once this has been done, the script can provide output in any format.
- If structured output is required, the configuration script should be modified to always provide output in accordance with requirements of the RELAX NG schema defined in the APS Package Format Specification. Use Knowledgebase article #115854 APS: How to verify provisioning script output to check if the script provides the correct output.
Refer to the APS documentation for more details on the structured output of configuration scripts - Configuration script output section.