Remove trace statements
Compute difference in current and new ids
Make sure the return xml headers are correct.