Keeping track of connected nodes