1 /*
2 * Licensed to The Apereo Foundation under one or more contributor license
3 * agreements. See the NOTICE file distributed with this work for additional
4 * information regarding copyright ownership.
5 *
6 *
7 * The Apereo Foundation licenses this file to you under the Educational
8 * Community License, Version 2.0 (the "License"); you may not use this file
9 * except in compliance with the License. You may obtain a copy of the License
10 * at:
11 *
12 * http://opensource.org/licenses/ecl2.txt
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
16 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
17 * License for the specific language governing permissions and limitations under
18 * the License.
19 *
20 */
21
22 package org.opencastproject.serviceregistry.impl.jmx;
23
24 /**
25 * JMX Bean interface exposing jobs statistics.
26 */
27 public interface JobsStatisticsMXBean {
28
29 /**
30 * Gets the total number of jobs
31 *
32 * @return the number of jobs
33 */
34 int getJobCount();
35
36 /**
37 * Gets the number of running jobs
38 *
39 * @return the number of running jobs
40 */
41 int getRunningJobCount();
42
43 /**
44 * Gets the number of queued jobs
45 *
46 * @return the number of queued jobs
47 */
48 int getQueuedJobCount();
49
50 /**
51 * Gets the number of finished jobs
52 *
53 * @return the number of finished jobs
54 */
55 int getFinishedJobCount();
56
57 /**
58 * Gets the number of failed jobs
59 *
60 * @return the number of failed jobs
61 */
62 int getFailedJobCount();
63
64 /**
65 * Gets the number of jobs of this JMX node
66 *
67 * @return the number of jobs
68 */
69 int getJobCountByNode();
70
71 /**
72 * Gets the number of running jobs of this JMX node
73 *
74 * @return the number of running jobs
75 */
76 int getRunningJobCountByNode();
77
78 /**
79 * Gets the number of queued jobs of this JMX node
80 *
81 * @return the number of queued jobs
82 */
83 int getQueuedJobCountByNode();
84
85 /**
86 * Gets the number of finished jobs of this JMX node
87 *
88 * @return the number of finished jobs
89 */
90 int getFinishedJobCountByNode();
91
92 /**
93 * Gets the number of failed jobs of this JMX node
94 *
95 * @return the number of failed jobs
96 */
97 int getFailedJobCountByNode();
98
99 /**
100 * Gets a list of all jobs
101 *
102 * @return an array including all jobs
103 */
104 String[] getJobs();
105
106 /**
107 * Gets a list of all running jobs
108 *
109 * @return an array including all running jobs
110 */
111 String[] getRunningJobs();
112
113 /**
114 * Gets a list of all queued jobs
115 *
116 * @return an array including all queued jobs
117 */
118 String[] getQueuedJobs();
119
120 /**
121 * Gets a list of all finished jobs
122 *
123 * @return an array including all finished jobs
124 */
125 String[] getFinishedJobs();
126
127 /**
128 * Gets a list of all failed jobs
129 *
130 * @return an array including all failed jobs
131 */
132 String[] getFailedJobs();
133
134 /**
135 * Gets a list of all jobs of this JMX node
136 *
137 * @return an array including all jobs
138 */
139 String[] getJobsByNode();
140
141 /**
142 * Gets a list of running jobs of this JMX node
143 *
144 * @return an array including running jobs
145 */
146 String[] getRunningJobsByNode();
147
148 /**
149 * Gets a list of queued jobs of this JMX node
150 *
151 * @return an array including queued jobs
152 */
153 String[] getQueuedJobsByNode();
154
155 /**
156 * Gets a list of finished jobs of this JMX node
157 *
158 * @return an array including finished jobs
159 */
160 String[] getFinishedJobsByNode();
161
162 /**
163 * Gets a list of failed jobs of this JMX node
164 *
165 * @return an array including failed jobs
166 */
167 String[] getFailedJobsByNode();
168
169 /**
170 * Gets a list of average job run times
171 *
172 * @return an array including average job run times
173 */
174 String[] getAverageJobRunTime();
175
176 /**
177 * Gets a list of average job queue times
178 *
179 * @return an array including average job queue times
180 */
181 String[] getAverageJobQueueTime();
182
183 }