Thomas Vachuska | 83e090e | 2014-10-22 14:25:35 -0700 | [diff] [blame] | 1 | /* |
Brian O'Connor | a09fe5b | 2017-08-03 21:12:30 -0700 | [diff] [blame] | 2 | * Copyright 2014-present Open Networking Foundation |
Thomas Vachuska | 83e090e | 2014-10-22 14:25:35 -0700 | [diff] [blame] | 3 | * |
Thomas Vachuska | 4f1a60c | 2014-10-28 13:39:07 -0700 | [diff] [blame] | 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 |
Thomas Vachuska | 83e090e | 2014-10-22 14:25:35 -0700 | [diff] [blame] | 7 | * |
Thomas Vachuska | 4f1a60c | 2014-10-28 13:39:07 -0700 | [diff] [blame] | 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. |
Thomas Vachuska | 83e090e | 2014-10-22 14:25:35 -0700 | [diff] [blame] | 15 | */ |
Brian O'Connor | abafb50 | 2014-12-02 22:26:20 -0800 | [diff] [blame] | 16 | package org.onosproject.net.flow; |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 17 | |
Srikanth Vavilapalli | 95810f5 | 2015-09-14 15:49:56 -0700 | [diff] [blame] | 18 | import java.util.List; |
| 19 | |
Brian O'Connor | abafb50 | 2014-12-02 22:26:20 -0800 | [diff] [blame] | 20 | import org.onosproject.net.DeviceId; |
| 21 | import org.onosproject.net.provider.ProviderService; |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 22 | |
| 23 | /** |
tom | 8bb1606 | 2014-09-12 14:47:46 -0700 | [diff] [blame] | 24 | * Service through which flow rule providers can inject information into |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 25 | * the core. |
| 26 | */ |
tom | d735672 | 2014-08-26 01:07:39 -0700 | [diff] [blame] | 27 | public interface FlowRuleProviderService extends ProviderService<FlowRuleProvider> { |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 28 | |
| 29 | /** |
tom | 8bb1606 | 2014-09-12 14:47:46 -0700 | [diff] [blame] | 30 | * Signals that a flow rule that was previously installed has been removed. |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 31 | * |
Thomas Vachuska | 4b42077 | 2014-10-30 16:46:17 -0700 | [diff] [blame] | 32 | * @param flowEntry removed flow entry |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 33 | */ |
alshabib | 1c319ff | 2014-10-04 20:29:09 -0700 | [diff] [blame] | 34 | void flowRemoved(FlowEntry flowEntry); |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 35 | |
| 36 | /** |
alshabib | 5c370ff | 2014-09-18 10:12:14 -0700 | [diff] [blame] | 37 | * Pushes the collection of flow entries currently applied on the given |
| 38 | * device. |
| 39 | * |
Yuta HIGUCHI | 5c94727 | 2014-11-03 21:39:21 -0800 | [diff] [blame] | 40 | * @param deviceId device identifier |
Thomas Vachuska | 4b42077 | 2014-10-30 16:46:17 -0700 | [diff] [blame] | 41 | * @param flowEntries collection of flow rules |
alshabib | 5c370ff | 2014-09-18 10:12:14 -0700 | [diff] [blame] | 42 | */ |
alshabib | 1c319ff | 2014-10-04 20:29:09 -0700 | [diff] [blame] | 43 | void pushFlowMetrics(DeviceId deviceId, Iterable<FlowEntry> flowEntries); |
alshabib | 5c370ff | 2014-09-18 10:12:14 -0700 | [diff] [blame] | 44 | |
Brian O'Connor | 72cb19a | 2015-01-16 16:14:41 -0800 | [diff] [blame] | 45 | /** |
ssyoon90 | 30fbcd9 | 2015-08-17 10:42:07 +0900 | [diff] [blame] | 46 | * Pushes the collection of flow entries currently applied on the given |
| 47 | * device without flowMissing process. |
| 48 | * |
| 49 | * @param deviceId device identifier |
| 50 | * @param flowEntries collection of flow rules |
| 51 | */ |
| 52 | void pushFlowMetricsWithoutFlowMissing(DeviceId deviceId, Iterable<FlowEntry> flowEntries); |
| 53 | |
| 54 | /** |
Srikanth Vavilapalli | 95810f5 | 2015-09-14 15:49:56 -0700 | [diff] [blame] | 55 | * Pushes the collection of table statistics entries currently extracted |
| 56 | * from the given device. |
| 57 | * |
| 58 | * @param deviceId device identifier |
| 59 | * @param tableStatsEntries collection of flow table statistics entries |
| 60 | */ |
| 61 | void pushTableStatistics(DeviceId deviceId, List<TableStatisticsEntry> tableStatsEntries); |
| 62 | |
| 63 | /** |
Brian O'Connor | 72cb19a | 2015-01-16 16:14:41 -0800 | [diff] [blame] | 64 | * Indicates to the core that the requested batch operation has |
| 65 | * been completed. |
| 66 | * |
| 67 | * @param batchId the batch which was processed |
| 68 | * @param operation the resulting outcome of the operation |
| 69 | */ |
| 70 | void batchOperationCompleted(long batchId, CompletedBatchOperation operation); |
tom | 0eb04ca | 2014-08-25 14:34:51 -0700 | [diff] [blame] | 71 | } |