It is sometimes useful to disable XML validation in an activity to be able to process an XML document that is not fully compliant with the XML schema used in BusinessWorks. For example, this could be related to wrong or missing namespaces or the presence of unexpected elements.
It is important to keep in mind that this should be used only has an exception when no other options are available, processing invalid XML documents may create issues in later BusinessWorks processing (for example a file would be generated but some fields would be missing in some cases).
This article goal is to explain how to disable XML validation at activity level.
How to disable XML validation at activity level
Since BusinessWorks 6.6.0 this can be done using the following properties:
To Disable XML validation in the activity Input:
bw.application.activity.validateInput[.<ApplicationName>[.<ApplicationVersion>]
[.<PackageName>.<ProcessName>[.<ActivityName>]]]
To Disable XML validation in the activity Output:
bw.application.activity.validateOutput[.<ApplicationName>[.<ApplicationVersion>][.<PackageName>.<ProcessName>[.<ActivityName>]]]
Important notes
. In releases prior to 6.9.1 (2.8.2 for BWCE) the properties above have no effect on the ParseXml activity (when at least the application name is specified)
. There is an error in the BusinessWorks documentation this is the Package Name that should be used and not the Module Name
. The Package Name can be made of multiple elements while a package may have sub-packages (in that case name elements should be separated by dots, for example package.subpackage)
If in the example below we want to disable the Output XML validation in the Mapper1 activity of the BadMapping process:
The property to use is the following:
bw.application.activity.validateOutput.TestParseXML.application.1.0.testparsexml.BadMapping.Mapper1=false
The Package, process and activity names are visible when the process is edited.
The application name and version can be verified in the TestParseXML.application Overview panel :
We then have the following elements :
Application name : TestParseXML.application
Application version : 1.0 (use only the two first digits)
Package name : testparsexml
Process name : BadMapping
Activity name : Mapper1
The properties can be used with partial names like, for example:
bw.application.activity.validateOutput.TestParseXML.application to disable Output XML validation for all activities of instances of the TestParseXML application
bw.application.activity.validateOutput.TestParseXML.application.1.0 to disable Output XML validation for all activities of the 1.0 instance of the TestParseXML application (in case multiple versions would be deployed at the same time)
bw.application.activity.validateOutput.TestParseXML.application.1.0.testparsexml 0 to disable Output XML validation for all activities of all processes of the ‘testparsexml’ package of the 1.0 instance of the TestParseXML application
bw.application.activity.validateOutput.TestParseXML.application.1.0.testparsexml 0 to disable Output XML validation for all activities of the ‘BadMapping’ process of the 1.0 instance of the TestParseXML application
It is also possible to disable XML validation at appnode level (all activities of all applications) using the following syntax:
bw.application.activity.validateInput=false
bw.application.activity.validateOutput=false
Note that in this specific case the property takes precedence over the ParseXml activity configuration.
Disabling XML validation in BusinessWorks 5.X context
All needed explanations are available in the following KB article:
https://support.tibco.com/s/article/Tibco-KnowledgeArticle-Article-34708
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now