001: /*
002: * BEGIN_HEADER - DO NOT EDIT
003: *
004: * The contents of this file are subject to the terms
005: * of the Common Development and Distribution License
006: * (the "License"). You may not use this file except
007: * in compliance with the License.
008: *
009: * You can obtain a copy of the license at
010: * https://open-esb.dev.java.net/public/CDDLv1.0.html.
011: * See the License for the specific language governing
012: * permissions and limitations under the License.
013: *
014: * When distributing Covered Code, include this CDDL
015: * HEADER in each file and include the License file at
016: * https://open-esb.dev.java.net/public/CDDLv1.0.html.
017: * If applicable add the following below this CDDL HEADER,
018: * with the fields enclosed by brackets "[]" replaced with
019: * your own identifying information: Portions Copyright
020: * [year] [name of copyright owner]
021: */
022:
023: /*
024: * @(#)ComponentStatisticsMBean.java
025: * Copyright 2004-2007 Sun Microsystems, Inc. All Rights Reserved.
026: *
027: * END_HEADER - DO NOT EDIT
028: */
029: package com.sun.jbi.monitoring;
030:
031: import java.util.Date;
032: import javax.management.openmbean.CompositeData;
033:
034: /**
035: * This interface defines the MBean for collection of statistics for a single
036: * installed component. All statistics are since the last JBI startup; they
037: * are all reset when JBI is restarted.
038: *
039: * @author Sun Microsystems, Inc.
040: */
041: public interface ComponentStatisticsMBean extends StatisticsMBean {
042: //
043: // API statistics collected by the framework
044: //
045:
046: /**
047: * Get the time that this component was last started.
048: * @return The time of the last successful start() call.
049: */
050: Date getLastRestartTime();
051:
052: /**
053: * Get the count of calls to the life cycle init() method.
054: * @return The total number of calls to init().
055: */
056: int getInitRequests();
057:
058: /**
059: * Get the count of calls to the life cycle start() method.
060: * @return The total number of calls to start().
061: */
062: int getStartRequests();
063:
064: /**
065: * Get the count of calls to the life cycle stop() method.
066: * @return The total number of calls to stop().
067: */
068: int getStopRequests();
069:
070: /**
071: * Get the count of calls to the life cycle shutDown() method.
072: * @return The total number of calls to shutDown().
073: */
074: int getShutDownRequests();
075:
076: /**
077: * Get the count of failed calls to life cycle methods (excluding timeouts).
078: * @return The total number of failed calls.
079: */
080: int getFailedRequests();
081:
082: /**
083: * Get the count of timed out calls to life cycle methods.
084: * @return The total number of timed out calls.
085: */
086: int getTimedOutRequests();
087:
088: /**
089: * Get the current number of Service Units deployed.
090: * @return The current number of deployed SUs.
091: */
092: short getDeployedSUs();
093:
094: /**
095: * Get the count of calls to the ServiceUnitManager deploy() method.
096: * @return The total number of calls to deploy().
097: */
098: int getDeploySURequests();
099:
100: /**
101: * Get the count of calls to the ServiceUnitManager undeploy() method.
102: * @return The total number of calls to undeploy().
103: */
104: int getUndeploySURequests();
105:
106: /**
107: * Get the count of calls to the ServiceUnitManager init() method.
108: * @return The total number of calls to init().
109: */
110: int getInitSURequests();
111:
112: /**
113: * Get the count of calls to the ServiceUnitManager start() method.
114: * @return The total number of calls to start().
115: */
116: int getStartSURequests();
117:
118: /**
119: * Get the count of calls to the ServiceUnitManager stop() method.
120: * @return The total number of calls to stop().
121: */
122: int getStopSURequests();
123:
124: /**
125: * Get the count of calls to the ServiceUnitManager shutDown() method.
126: * @return The total number of calls to shutDown().
127: */
128: int getShutDownSURequests();
129:
130: /**
131: * Get the count of failed calls to ServiceUnitManager methods (excluding
132: * timeouts).
133: * @return The total number of failed calls.
134: */
135: int getFailedSURequests();
136:
137: /**
138: * Get the count of timed out calls to ServiceUnitManager methods.
139: * @return The total number of timed out calls.
140: */
141: int getTimedOutSURequests();
142:
143: /**
144: * Get the current number of services (for an SE) or endpoints (for a BC)
145: * registered with the NMR.
146: * @return The total number registered services or endpoints.
147: */
148: short getRegisteredServicesOrEndpoints();
149: }
|