moved out GraphHandler connected component methods