0f94bc5e1f16432ea4745248426757648018b8bf
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / cluster / sharding / DistributedShardRegistration.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.sharding;
9
10 import com.google.common.annotations.Beta;
11 import java.util.concurrent.CompletionStage;
12
13 /**
14  * Registration of the CDS shard that allows you to remove the shard from the system by closing the registration.
15  * This removal is done asynchronously.
16  */
17 @Beta
18 public interface DistributedShardRegistration {
19
20     /**
21      *  Removes the shard from the system, this removal is done asynchronously, the future completes once the
22      *  backend shard is no longer present.
23      */
24     CompletionStage<Void> close();
25 }