HomePhorge

Fix #2010 - add protection code for some storeconfig corruption
c55ac3f2c233Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Fix #2010 - add protection code for some storeconfig corruption

This patch adds a more robust and self-healing storedconfig in case
of logically corrupted database as the one in #2010 (where multiple
resources of same references are present in the database for the
same host).
The problem is that the resources are stored in a hash with the resource
ref as the key, so we collapse resource of different id but same
reference. The patch fixed this by using a hash by resource id, and
maintaining a list of old extraneous resource in the db that are removved
after the storeconfig pass.

Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>

Details

Provenance
Brice Figureau <brice-puppet@daysofwonder.com>Authored on
James Turnbull <james@lovedthanlost.net>Committed on Mar 4 2009, 9:31 AM
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPUa790ee3b487a: Further fix to #1910
Branches
Unknown
Tags
Unknown

Event Timeline

James Turnbull <james@lovedthanlost.net> committed rPUc55ac3f2c233: Fix #2010 - add protection code for some storeconfig corruption (authored by Brice Figureau <brice-puppet@daysofwonder.com>).Mar 4 2009, 9:31 AM