Add cluster validation routines. Make changes according to #1255