2 * Copyright (c) 2015 Brocade Communications Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.controller.cluster.raft.base.messages;
10 import com.google.common.base.Preconditions;
11 import java.io.Serializable;
12 import javax.annotation.Nonnull;
15 * Message sent from a leader to its followers to indicate leadership transfer is starting.
17 * @author Thomas Pantelis
19 public final class LeaderTransitioning implements Serializable {
20 private static final long serialVersionUID = 1L;
22 private final String leaderId;
24 public LeaderTransitioning(@Nonnull final String leaderId) {
25 this.leaderId = Preconditions.checkNotNull(leaderId);
29 public String getLeaderId() {
34 public String toString() {
35 return "LeaderTransitioning [leaderId=" + leaderId + "]";