fix Atomic commit not being atomic