Size of NIEM XML documents

webb edited this page Nov 19, 2014 · 2 revisions

A common concern regarding NIEM is the size of NIEM documents. Large documents may take longer to send, or may take more disk space or other resources to process.

Reducing the size of XML documents

One strategy is to design XML documents so that they contain less data, or to reduce the amount of data sent. Strategies include:

  1. Break up messages into small, independent parts.
  2. Use caching to reduce retransmission.
  3. Use lazy strategies: Only send what is needed, when it is needed.
  4. Use NIEM constructs to avoid replicating data in a NIEM XML document.

Compression

If you are concerned with the size of an on-disk XML document, standard compression applications, such as gzip, compress XML documents, including NIEM documents, very well.

An XML document sent as a network message may be compressed using numerous strategies, including:

  1. Use of a Server output filter
  2. Fast Infoset
  3. Efficient XML Interchange (EXI)

Each of these options has advantages and disadvantages.

A server output filter is generally the simplest to implement; they are available as standard parts of web servers, and may be automatically descripted by client libraries and browsers. Their compression ratios are very good, but since they are not XML-oriented, parsing of XML documents may be slower than the other strategies.

Fast Infoset operates entirely at the XML document level, so it does not require any NIEM-specific work.

Efficient XML Interchange (EXI) works at the schema level, compressing XML documents using the XML Schema for the document to guide compression. This means that the sender and receiver must use the same XML Schema for the document. There are some strategies that will improve EXI's performance in compressing XML documents.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.