implement election ops queue; fix memory race for dup_key