KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > caucho > management > server > WebAppMXBean


1 /*
2  * Copyright (c) 1998-2006 Caucho Technology -- all rights reserved
3  *
4  * This file is part of Resin(R) Open Source
5  *
6  * Each copy or derived work must preserve the copyright notice and this
7  * notice unmodified.
8  *
9  * Resin Open Source is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  *
14  * Resin Open Source is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE, or any warranty
17  * of NON-INFRINGEMENT. See the GNU General Public License for more
18  * details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with Resin Open Source; if not, write to the
22  *
23  * Free Software Foundation, Inc.
24  * 59 Temple Place, Suite 330
25  * Boston, MA 02111-1307 USA
26  *
27  * @author Scott Ferguson
28  */

29
30 package com.caucho.management.server;
31
32 import com.caucho.jmx.Description;
33 import com.caucho.jmx.Units;
34
35 /**
36  * MBean API for the WebApp.
37  *
38  * <pre>
39  * resin:type=WebAppMBean,name=/wiki,Host=foo.com
40  * </pre>
41  */

42 @Description("The web-app management interface")
43 public interface WebAppMXBean extends DeployControllerMXBean {
44   //
45
// Hierarchy attributes
46
//
47

48   /**
49    * Returns the owning host
50    */

51   @Description("The web-app's host")
52   public HostMXBean getHost();
53
54   /**
55    * Returns the session manager
56    */

57   @Description("The web-app's session manager")
58   public SessionManagerMXBean getSessionManager();
59
60   //
61
// Configuration attributes
62
//
63

64   /**
65    * Returns the root directory.
66    */

67   @Description("The configured filesystem directory for the web-app")
68   public String JavaDoc getRootDirectory();
69
70   /**
71    * Returns the application's context path.
72    */

73   @Description("The configured context path that identifies the web-app in a url")
74   public String JavaDoc getContextPath();
75
76   //
77
// Statistics attributes
78
//
79

80   /**
81    * Returns the current number of requests being serviced by the web-app.
82    */

83   @Description("The current number of requests served by the web-app")
84   public int getRequestCount();
85
86   /**
87    * Returns the total number of requests serviced by the web-app
88    * since it started.
89    */

90   @Description("The total number of requests served by the web-app since starting")
91   public long getRequestCountTotal();
92
93   /**
94    * Returns the total duration in milliseconds that connections serviced by
95    * this web-app have taken.
96    */

97   @Description("The total real (wall-clock) time in milliseconds taken by requests served by the web-app")
98   @Units("milliseconds")
99   public long getRequestTimeTotal();
100
101   /**
102    * Returns the total number of bytes that requests serviced by
103    * this web-app have read.
104    */

105   @Description("The total number of bytes received in client requests")
106   @Units("bytes")
107   public long getRequestReadBytesTotal();
108
109   /**
110    * Returns the total number of bytes that connections serviced by this
111    * web-app have written.
112    */

113   @Description("The total number of bytes sent to clients")
114   @Units("bytes")
115   public long getRequestWriteBytesTotal();
116
117   /**
118    * Returns the number of connections that have ended with a
119    * {@link com.caucho.vfs.ClientDisconnectException} for this web-app in it's lifetime.
120    */

121   @Description("The total number of times a client has disconnected before a request completed")
122   public long getClientDisconnectCountTotal();
123 }
124
Popular Tags