Experimental map-first preprocessing

DITA-OT 2.5 introduces an experimental map-first preprocessing option as an alternative to the default preprocess operation. The new method provides the same functionality, but takes a different approach.

Whereas the default preprocessing routine handles both maps and topics at the same time, the map-first approach begins by processing maps as far as possible, and only then starts processing topics. This simplifies the processing logic and creates cleaner module responsibilities, which makes it easier to process only those topics that are actually referenced after filtering, for example, or to only process the map to validate the map structure.

The current preprocessing architecture was established during the DITA 1.0 era when there were fewer DITA features that operated on the map level. Initially, the difference between processing modes was not that great, but as more map-level features such as keys and key scopes have been added to DITA, processing maps first to build the context makes sense. The original preprocessing operation already does this to a degree, but the new map-first preprocessing option will be even more formal about it.

Note: The map-first preprocessing option is not enabled by default in DITA-OT 2.5, but is offered as an experimental preview feature to allow users and vendors who extend preprocessing to provide feedback on possible issues with the design. The new option will most likely become the default in DITA-OT 3.0.

To use map-first preprocessing, call the preprocess2 Ant target in your customizations instead of the default preprocess target.

Attention: The preprocess2 target name and implementation details are subject to change. Subject schemes and delayed key resolution have not yet been implemented, but support for at least subject schemes will likely be added in an upcoming release.