Data formatting for Web Services

Different CICS® technologies can generate JSON and XML data that is equally specification compliant, but physically different. They might also report errors that are found in an input message in different ways, as a result of the order in which they apply checks to validate the data.

CICS uses several different technologies for automatically transforming JSON and XML data. These include z/OS® Connect for CICS (both the Java™ and non-Java variants), Axis2, and PIPELINE resources. These technologies generate JSON and XML data in an external format as dictated by the relevant specifications.

There can be multiple ways to represent data, that are equally specification-compliant, but physically different. The CICS technologies always generate data that is compliant, but there might be physical differences between them. For example, if you switch between the Java and non-Java z/OS Connect for CICS options for JSON, you might detect minor differences in the generated JSON.

Such differences might include different error messages being reported under failure conditions, differences in how white-space characters are inserted, alternative (but equivalent) representations for numeric data, and variations in how special characters are escaped. Further changes of this nature can be introduced as a result of applying corrective maintenance to CICS, or with new releases of CICS.

Partner systems, such as a JSON client, should be written to tolerate specification-compliant variations of this nature. Partners often exploit widely used cross-industry libraries and technologies for interacting with JSON and XML; such libraries automatically handle such minor formatting differences. However, it is possible for less-compliant partner systems to detect and respond differently to the formatting differences in the various CICS technologies, care might therefore be required if you are writing applications that work directly with the JSON or XML without the benefit of a standards-based parser.