Modify ↓
Ticket #982 (closed defect: fixed)
probed.xml should be deterministically ordered
Reported by: | http://faceted.wordpress.com/ | Owned by: | desai |
---|---|---|---|
Priority: | minor | Milestone: | Bcfg2 1.2.0 Release |
Component: | bcfg2-server | Version: | 1.0 |
Keywords: | Cc: |
Description
Every time bcfg2-server is restarted, it rewrites probed.xml with all of the clients in a different order.
This makes tracking probe data in a revision control system cumbersome and not very useful, especially when working with branches and alternate/staging bcfg2 servers etc.
This patch for Bcfg2/Server/Plugins/Probes.py solves the problem.
@@ -73,7 +73,7 @@ def write_data(self): """Write probe data out for use with bcfg2-info.""" top = lxml.etree.Element("Probed") - for client, probed in self.probedata.iteritems(): + for client, probed in sorted(self.probedata.items()): cx = lxml.etree.SubElement(top, 'Client', name=client) for probe in probed: lxml.etree.SubElement(cx, 'Probe', name=probe,
Attachments
Change History
Note: See
TracTickets for help on using
tickets.
Committed in [137113ac0b53df7acfb5dab9eb8ee3ba04ebca8f]. Thanks for the patch.