blob: e8a4a381f3b0124ab1ed5252d4f05b542bd6ca55 [file] [log] [blame]
Boyoung Jeong9e8faec2018-06-17 21:19:23 +09001/*
2 * Copyright 2018-present Open Networking Foundation
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 */
16package org.onosproject.openstacktelemetry.api;
17
Boyoung Jeong1cca5e82018-08-01 21:00:08 +090018import java.util.Map;
19import java.util.Queue;
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090020import java.util.Set;
21
22/**
23 * Admin service API for making a flow rule.
24 */
25public interface StatsFlowRuleAdminService {
26
27 /**
Jian Li0bbbb1c2018-06-22 22:01:17 +090028 * Starts this service.
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090029 */
30 void start();
31
32 /**
Jian Li0bbbb1c2018-06-22 22:01:17 +090033 * Stops this service.
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090034 */
35 void stop();
36
37 /**
Jian Li0bbbb1c2018-06-22 22:01:17 +090038 * Creates a stat flow rule.
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090039 *
Jian Li0bbbb1c2018-06-22 22:01:17 +090040 * @param statFlowRule stat flow rule for a VM
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090041 */
Jian Li0bbbb1c2018-06-22 22:01:17 +090042 void createStatFlowRule(StatsFlowRule statFlowRule);
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090043
44 /**
Jian Lif8b8c7f2018-08-27 18:49:04 +090045 * Gets a set of flow infos collected from overlay network.
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090046 *
Jian Li0bbbb1c2018-06-22 22:01:17 +090047 * @return a set of flow infos
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090048 */
Jian Lif8b8c7f2018-08-27 18:49:04 +090049 Set<FlowInfo> getOverlayFlowInfos();
50
51 /**
52 * Gets a set of flow infos collected from underlay network.
53 *
54 * @return a set of flow infos
55 */
56 Set<FlowInfo> getUnderlayFlowInfos();
Jian Li0bbbb1c2018-06-22 22:01:17 +090057
58 /**
59 * Deletes stat flow rule.
60 *
61 * @param statFlowRule stat flow rule for a VM
62 */
63 void deleteStatFlowRule(StatsFlowRule statFlowRule);
Boyoung Jeong1cca5e82018-08-01 21:00:08 +090064
65 /**
66 * Gets a map of flow information.
67 *
68 * @return a map of flow infos
69 */
70 Map<String, Queue<FlowInfo>> getFlowInfoMap();
71
Boyoung Jeong9e8faec2018-06-17 21:19:23 +090072}