Move MessageTrackerTest
[controller.git] / opendaylight / md-sal / cds-access-client / src / main / java / org / opendaylight / controller / cluster / access / client / NoProgressException.java
1 /*
2  * Copyright (c) 2016 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.controller.cluster.access.client;
9
10 import java.util.concurrent.TimeUnit;
11 import org.opendaylight.controller.cluster.access.concepts.RequestException;
12
13 /**
14  * Internal {@link RequestException} used as poison cause when the client fails to make progress for a long time.
15  * See {@link SequencedQueue} for details.
16  *
17  * @author Robert Varga
18  */
19 final class NoProgressException extends RequestException {
20     private static final long serialVersionUID = 1L;
21
22     protected NoProgressException(final long nanos) {
23         super(String.format("No progress in %s seconds", TimeUnit.NANOSECONDS.toSeconds(nanos)));
24     }
25
26     @Override
27     public boolean isRetriable() {
28         return false;
29     }
30 }