Made classNamesCounter final to be sure it is not accidentally null in a concurrent situation: thanks to Jochen Theodorou for the review and suggestion