Issue 7995 by tj: Cleanup and simple uniq id