You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
67 lines
4.1 KiB
XML
67 lines
4.1 KiB
XML
9 years ago
|
<section version="5.0" xml:lang="en" xmlns="http://docbook.org/ns/docbook" xmlns:xi="http://www.w3.org/2001/XInclude"
|
||
|
xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="section_template_debug">
|
||
|
|
||
|
<title>Debugging build failures</title>
|
||
|
<para>Maven/docbkx failures generally fall into one of two categories, validation errors or build failures. Correcting the document begins with understanding which type of failure has occurred and understanding where to look in your document source.</para>
|
||
|
<para>Validation errors are generally indicated in the build output with text like the following:
|
||
|
<screen>...
|
||
|
@@@@@@@@@@@@@@@@@@@@@@
|
||
|
!!!VALIDATION ERRORS!!
|
||
|
!!!!!!!!!!!!!!!!!!!!!!
|
||
|
|
||
|
Note: Open the temporary file:
|
||
|
|
||
|
file:/home/user1/openpower-foundation-docbkx-framework/doc/template/target//bk_main.xml-invalid.xml
|
||
|
|
||
|
to see all the errors in context.
|
||
|
You must correct the errors in the original
|
||
|
source DocBook or wadl files however.
|
||
|
|
||
|
You can control whether build fails or not by
|
||
|
setting failOnValidationError to no in your pom.
|
||
|
|
||
|
lineNumber: 272; columnNumber: 70; text not allowed here; expected element "address", ...
|
||
|
</screen></para>
|
||
|
<para>This error message contains three key pieces of information:</para>
|
||
|
<orderedlist>
|
||
|
<listitem>
|
||
|
<para>The full path and filename that contains the context for the failure. In the message above, this is
|
||
|
<literal>/home/user1/openpower-foundation-docbkx-framework/doc/template/target//bk_main.xml-invalid.xml</literal>.</para>
|
||
|
</listitem>
|
||
|
<listitem>
|
||
|
<para>The location within the file of the syntax error. For the above example, the key information is "<literal>lineNumber: 272; columnNumber: 70</literal>.</para>
|
||
|
</listitem>
|
||
|
<listitem>
|
||
|
<para>An explanation of the failure. This information in the above error reads, "text not allowed here; expected element "address", ...".</para>
|
||
|
</listitem>
|
||
|
</orderedlist>
|
||
|
<para>Build errors are easily identified as well. Below is an example:
|
||
|
<screen>...
|
||
|
[INFO] ------------------------------------------------------------------------
|
||
|
[INFO] BUILD FAILURE
|
||
|
[INFO] ------------------------------------------------------------------------
|
||
|
[INFO] Total time: 4.827s
|
||
|
[INFO] Finished at: Wed Jul 29 14:55:33 CDT 2015
|
||
|
[INFO] Final Memory: 17M/171M
|
||
|
[INFO] ------------------------------------------------------------------------
|
||
|
[ERROR] Failed to execute goal org.openpowerfoundation.docs:openpowerdocs-maven-plugin:1.0.0:generate-webhelp (generate-webhelp) on project openpower-template-guide: Execution generate-webhelp of goal org.openpowerfoundation.docs:openpowerdocs-maven-plugin:1.0.0:generate-webhelp failed: XInclude resource error (sec_template_new_document.xml) and no fallback provided. XProc error err:XD0011: org.xml.sax.SAXParseException; systemId: file:/home/user1/openpower-foundation-docbkx-framework/doc/template/sec_template_new_document.xml; lineNumber: 55; columnNumber: 17; The element type "para" must be terminated by the matching end-tag "</para>". -> [Help 1]...
|
||
|
</screen></para>
|
||
|
<para>Like validation errors, three key pieces of information are again provided:</para>
|
||
|
<orderedlist>
|
||
|
<listitem>
|
||
|
<para>The full path and filename of our failure is
|
||
|
<literal>/home/user1/openpower-foundation-docbkx-framework/doc/template/sec_template_new_document.xml</literal>.</para>
|
||
|
</listitem>
|
||
|
<listitem>
|
||
|
<para>The location within the file of the error is "<literal>lineNumber: 55; columnNumber: 17</literal>.</para>
|
||
|
</listitem>
|
||
|
<listitem>
|
||
|
<para>An explanation of the failure begins with the text, "The element type "para" must be terminated by the matching end-tag "</para>."</para>
|
||
|
</listitem>
|
||
|
</orderedlist>
|
||
|
<para>With these details in hand for either error, one simply locates the offending syntax and makes the appropriate correction. Online resources such as those listed in <xref linkend="section_template_references"/> may be helpful.</para>
|
||
|
|
||
|
|
||
|
</section>
|
||
|
|