Java Classregistry cleanup