Improve Candidate.votingPeers 51/105151/4
authorRobert Varga <robert.varga@pantheon.tech>
Mon, 3 Apr 2023 10:55:44 +0000 (12:55 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Mon, 3 Apr 2023 13:59:15 +0000 (15:59 +0200)
commite44f00950d144590e0d30ef892e7b8e800dcbb06
treefeb6edfe8959f02a4e48b63ece82b1e4ac4640df
parente178860b545a92d987e7b75ce695dd02921611e3
Improve Candidate.votingPeers

Use ImmutableList to ensure the list is never modified. This also
improves overhead/performance slightly.

Change-Id: Iad491da0e446da0a07e96067846c2c57c0dcfb9a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/Candidate.java