Georgios Katsikas | 8360098 | 2017-05-28 20:41:45 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2017-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 | */ |
| 16 | |
| 17 | package org.onosproject.drivers.server.stats; |
| 18 | |
| 19 | /** |
| 20 | * Timing statistics API. |
| 21 | */ |
| 22 | public interface TimingStatistics { |
| 23 | |
| 24 | /** |
Georgios Katsikas | fda6674 | 2018-07-31 20:18:14 +0200 | [diff] [blame^] | 25 | * Returns the unit of timing statistics. |
| 26 | * |
| 27 | * @return timing statistics' unit |
| 28 | */ |
| 29 | MonitoringUnit unit(); |
| 30 | |
| 31 | /** |
Georgios Katsikas | 8360098 | 2017-05-28 20:41:45 +0200 | [diff] [blame] | 32 | * Time (ns) to parse the controller's deployment instruction. |
| 33 | * |
| 34 | * @return time in nanoseconds to parse a 'deploy' command |
| 35 | */ |
| 36 | long deployCommandParsingTime(); |
| 37 | |
| 38 | /** |
| 39 | * Time (ns) to launch a slave process in the dataplane. |
| 40 | * |
| 41 | * @return time in nanoseconds to launch a 'deploy' command |
| 42 | */ |
| 43 | long deployCommandLaunchingTime(); |
| 44 | |
| 45 | /** |
| 46 | * Time (ns) to parse + launch the controller's deployment instruction. |
| 47 | * This is the sum of the above two timers. |
| 48 | * |
| 49 | * @return time in nanoseconds to parse + launch a 'deploy' command |
| 50 | */ |
| 51 | long totalDeploymentTime(); |
| 52 | |
| 53 | /** |
| 54 | * Time (ns) to perform a local reconfiguration. |
| 55 | * (i.e., the agent autoscales the number of CPUs). |
| 56 | * |
| 57 | * @return time in nanoseconds to autoscale |
| 58 | */ |
| 59 | long autoscaleTime(); |
| 60 | |
| 61 | } |