Bug 2502: If creating an object fails, we need to free the uuid that was allocated