KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > web > monitor > PwcWebModuleStats


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23
24 /*
25  * Copyright 2004-2005 Sun Microsystems, Inc. All rights reserved.
26  * Use is subject to license terms.
27  */

28
29 /*
30  * $Id: PwcWebModuleStats.java,v 1.3 2005/12/25 04:27:30 tcfujii Exp $
31  * $Date: 2005/12/25 04:27:30 $
32  * $Revision: 1.3 $
33  *
34  */

35
36 package com.sun.enterprise.web.monitor;
37
38 import java.io.Serializable JavaDoc;
39 import java.util.HashMap JavaDoc;
40
41 /**
42  * Monitoring interface for web modules.
43  */

44 public interface PwcWebModuleStats extends Serializable JavaDoc {
45
46
47     /**
48      * Gets the number of JSPs that have been loaded in the web module.
49      *.
50      * @return Number of JSPs that have been loaded
51      */

52     public int getJspCount();
53
54
55     /**
56      * Gets the number of JSPs that have been reloaded in the web module.
57      *.
58      * @return Number of JSPs that have been reloaded
59      */

60     public int getJspReloadCount();
61
62
63     /**
64      * Gets the number of errors that were triggered by JSP invocations.
65      *.
66      * @return Number of errors triggered by JSP invocations
67      */

68     public int getJspErrorCount();
69
70
71     /**
72      * Gets the total number of sessions that have been created for the web
73      * module.
74      *.
75      * @return Total number of sessions created
76      */

77     public int getSessionsTotal();
78
79
80     /**
81      * Gets the number of currently active sessions for the web
82      * module.
83      *.
84      * @return Number of currently active sessions
85      */

86     public int getActiveSessionsCurrent();
87
88
89     /**
90      * Gets the maximum number of concurrently active sessions for the web
91      * module.
92      *
93      * @return Maximum number of concurrently active sessions
94      */

95     public int getActiveSessionsHigh();
96
97
98     /**
99      * Gets the total number of rejected sessions for the web module.
100      *
101      * <p>This is the number of sessions that were not created because the
102      * maximum allowed number of sessions were active.
103      *.
104      * @return Total number of rejected sessions
105      */

106     public int getRejectedSessionsTotal();
107
108
109     /**
110      * Gets the total number of expired sessions for the web module.
111      *.
112      * @return Total number of expired sessions
113      */

114     public int getExpiredSessionsTotal();
115
116
117     /**
118      * Gets the longest time (in seconds) that an expired session had been
119      * alive.
120      *
121      * @return Longest time (in seconds) that an expired session had been
122      * alive.
123      */

124     public int getSessionMaxAliveTimeSeconds();
125
126
127     /**
128      * Gets the average time (in seconds) that expired sessions had been
129      * alive.
130      *
131      * @return Average time (in seconds) that expired sessions had been
132      * alive.
133      */

134     public int getSessionAverageAliveTimeSeconds();
135
136
137     /**
138      * Gets the time when the web module was started.
139      *
140      * @return Time (in milliseconds since January 1, 1970, 00:00:00) when the
141      * web module was started
142      */

143     public long getStartTimeMillis();
144
145
146     /**
147      * Gets the cumulative processing times of all servlets in the web module
148      * associated with this PwcWebModuleStats.
149      *
150      * @return Cumulative processing times of all servlets in the web module
151      * associated with this PwcWebModuleStats
152      */

153     public long getServletProcessingTimesMillis();
154
155
156     /**
157      * Returns the session ids of all sessions currently active in the web
158      * module associated with this PwcWebModuleStats.
159      *
160      * @return Session ids of all sessions currently active in the web module
161      * associated with this PwcWebModuleStats
162      */

163     public String JavaDoc getSessionIds();
164
165
166     /**
167      * Returns information about the session with the given id.
168      *
169      * <p>The session information is organized as a HashMap, mapping
170      * session attribute names to the String representation of their values.
171      *
172      * @param id Session id
173      *
174      * @return HashMap mapping session attribute names to the String
175      * representation of their values, or null if no session with the
176      * specified id exists, or if the session does not have any attributes
177      */

178     public HashMap JavaDoc getSession(String JavaDoc id);
179
180
181     /**
182      * Resets this WebModuleStats.
183      */

184     public void reset();
185         
186 }
187
Popular Tags