handles election process
Current state of the Raft
Start the election process. Note that, the function has a infinite loop, so will never return.