blob: 674bc2ed2c759986c5fcd5b5d1de93e58a83ebb7 [file] [log] [blame]
Yoonseon Hancbfac9a2016-10-20 13:14:06 -07001/*
2 * Copyright 2016-present Open Networking Laboratory
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package org.onosproject.incubator.net.virtual.provider;
18
19import org.onosproject.incubator.net.virtual.NetworkId;
20import org.onosproject.net.DeviceId;
21import org.onosproject.net.group.Group;
22import org.onosproject.net.group.GroupOperation;
23
24import java.util.Collection;
25
26/**
27 * Service through which Group providers can inject information into
28 * the virtual network core.
29 */
30public interface VirtualGroupProviderService
31 extends VirtualProviderService<VirtualGroupProvider> {
32 /**
33 * Notifies core if any failure from data plane during group operations.
34 *
35 * @param networkId the identity of the virtual network where this rule applies
36 * @param deviceId the device ID
37 * @param operation offended group operation
38 */
39 void groupOperationFailed(NetworkId networkId, DeviceId deviceId,
40 GroupOperation operation);
41
42 /**
43 * Pushes the collection of group detected in the data plane along
44 * with statistics.
45 *
46 * @param networkId the identity of the virtual network where this rule applies
47 * @param deviceId device identifier
48 * @param groupEntries collection of group entries as seen in data plane
49 */
50 void pushGroupMetrics(NetworkId networkId,
51 DeviceId deviceId, Collection<Group> groupEntries);
52
53 /**
54 * Notifies store of group failovers.
55 *
56 * @param networkId the identity of the virtual network where this rule applies
57 * @param failoverGroups failover groups in which a failover has occurred
58 */
59 void notifyOfFailovers(NetworkId networkId, Collection<Group> failoverGroups);
60}