Each time when host or template definition is exported, the order of low-level elements is new.
If someone is trying to keep host templates in version control system, or just wants to compare old version of xml with new, diff outputs A MUCH of differences just because whole xml nodes changed their places.
Attached patch makes this job less tricky. For the following components in host and template definitions:
it adds ordering by single field. As far as these components do not depend on component of the same type and all are childs of one parent node, this ordering could not break import operation.