geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ammul...@apache.org
Subject svn commit: r219976 [4/12] - in /geronimo/trunk: ./ etc/ sandbox/console-core/ sandbox/console-core/src/ sandbox/console-core/src/java/ sandbox/console-core/src/java/org/ sandbox/console-core/src/java/org/apache/ sandbox/console-core/src/java/org/apach...
Date Thu, 21 Jul 2005 01:38:23 GMT
Added: geronimo/trunk/sandbox/console-framework/src/webapp/login.html
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/login.html?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/login.html (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/login.html Wed Jul 20 18:38:12 2005
@@ -0,0 +1,227 @@
+<html>
+<head>
+<title>Geronimo Console Login</title>
+<link href="main.css" rel="stylesheet" type="text/css">
+<link rel="SHORTCUT ICON" href="favicon.ico" type="image/x-icon"/>
+</head>
+
+<body onload="document.login.j_username.focus()" leftmargin="0" topmargin="0" rightmargin="0">
+
+<form name="login" action="j_security_check" method="POST">
+  <table width="100%"  border="0" cellspacing="0" cellpadding="0">
+    <tr>
+		  <td>
+			  <table width="100%" border="0" cellspacing="0" cellpadding="0">
+				  <tr>
+						<td class="Logo" width="200">GERONIMO CONSOLE</td>
+						<td class="Top">&nbsp;</td>
+					</tr>
+				</table>
+			</td>
+    </tr>
+    <tr>
+      <td>&nbsp;</td>
+    </tr>
+    <tr>
+      <td class="Content"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+        <tr>
+          <td width="10">&nbsp;</td>
+          <td valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+            <tr>
+              <td width="10" class="TopLeft">&nbsp;</td>
+              <td class="Title">WELCOME TO Geronimo Console&#8482;</td>
+              <td width="10" class="TopRight">&nbsp;</td>
+            </tr>
+            <tr>
+              <td class="Left">&nbsp;</td>
+              <td class="Body">&nbsp;</td>
+              <td class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td width="10" height="200" class="Left">&nbsp;</td>
+              <td height="200" valign="top" class="Body"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                <tr>
+                  <td align="center" valign="top"><table width="100%"  border="0" cellspacing="1" cellpadding="5">
+                    <tr>
+                      <td width="5">&nbsp;</td>
+                      <td> <strong>GERONIMO&#8482;</strong> is a Java-certified, production-grade platform designed to allow developers to rapidly deploy and manage their applications. The result is an integrated, highly functional application platform that leverages the latest innovations from the open source community and simplifies application deployment and maintenance. </td>
+                      <td width="5">&nbsp;</td>
+                    </tr>
+                    <tr>
+                      <td>&nbsp;</td>
+                      <td>&nbsp;</td>
+                      <td>&nbsp;</td>
+                    </tr>
+                    <tr>
+                      <td>&nbsp;</td>
+                      <td> <p><strong>Geronimo Console&#8482;</strong> has integrated the following components: </p>
+                        <p>&#149;&nbsp; Application server (Apache Geronimo) </p>
+                        <p>&#149;&nbsp; Web server and servlet engine (Jetty) </p>
+                        <p>&#149;&nbsp; JSP compiler (Jasper) </p>
+                        <p>&#149;&nbsp; Relational database (Apache Derby) </p>
+                        <p>&#149;&nbsp; JSR 168 portlet container (Apache Pluto) </p>
+                        <p>&#149;&nbsp; Messaging (ActiveMQ) </p>
+                        <p>&#149;&nbsp; User management services </p>
+                        <p>&#149;&nbsp; Centralized administration console </p>
+                      <td>&nbsp;</td>
+                    </tr>
+                  </table></td>
+                  <td width="10">&nbsp;</td>
+                  <td width="350" height="300" align="center" valign="top">                    <table width="250" cellpadding="0" cellspacing="0" border="0">
+                      <tr>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td width="50" class="DarkBackground">LOGIN</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td width="6" class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground"><strong>Username</strong></td>
+                              <td class="LightBackground"><strong>:</strong></td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground"><input name="j_username" type="text" class="InputField" value="" size="20px" maxlength="25"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground"><strong>Password</strong></td>
+                              <td class="LightBackground"><strong>:</strong></td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground"><input name="j_password" type="password" class="InputField" value="" size="20px" maxlength="25"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td colspan="4" align="center" class="LightBackground"><input name="submit" type="submit" value="Login"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                        </table></td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                      </tr>
+                    </table>
+                    <p>&nbsp;</p></td>
+                </tr>
+              </table></td>
+              <td width="10" height="200" class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td class="Left">&nbsp;</td>
+              <td class="Body">&nbsp;</td>
+              <td class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td width="10" class="BottomLeft">&nbsp;</td>
+              <td class="Footer">&nbsp;</td>
+              <td width="10" class="BottomRight">&nbsp;</td>
+            </tr>
+          </table></td>
+          <td width="10">&nbsp;</td>
+          <td width="300" valign="top">            <table width="100%"  border="0" cellspacing="0" cellpadding="0">
+              <tr>
+                <td width="10">&nbsp;</td>
+                <td><img src="images/related_links.gif"></td>
+                <td width="10">&nbsp;</td>
+              </tr>
+              <tr>
+                <td height="7"><img src="images/spacer.gif"></td>
+                <td height="7" class="Body"><img src="images/spacer.gif"></td>
+                <td height="7"><img src="images/spacer.gif"></td>
+              </tr>
+              <tr>
+                <td width="10">&nbsp;</td>
+                <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Technical Support</a></td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Download Updates</a> </td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Mailing List</a></td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                </table></td>
+                <td width="10">&nbsp;</td>
+              </tr>
+            </table>
+            </td>
+          <td width="10">&nbsp;</td>
+        </tr>
+      </table></td>
+    </tr>
+    <tr>
+      <td>&nbsp;</td>
+    </tr>
+  </table>
+</form>
+</body>
+</html>

Added: geronimo/trunk/sandbox/console-framework/src/webapp/login_success.jsp
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/login_success.jsp?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/login_success.jsp (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/login_success.jsp Wed Jul 20 18:38:12 2005
@@ -0,0 +1,6 @@
+<HTML>
+<HEAD><TITLE>Login Successful</TITLE></HEAD>
+<BODY>
+Login Successfull. <a href="<%=request.getContextPath()%>/portal/test"> Click here to return to the portal tests.</A>
+</BODY>
+</HTML>
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/console-framework/src/webapp/login_success.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-framework/src/webapp/loginerror.html
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/loginerror.html?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/loginerror.html (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/loginerror.html Wed Jul 20 18:38:12 2005
@@ -0,0 +1,237 @@
+<html>
+<head>
+<title>Geronimo Console Login</title>
+<link href="main.css" rel="stylesheet" type="text/css">
+<link rel="SHORTCUT ICON" href="favicon.ico" type="image/x-icon"/>
+</head>
+
+<body onload="document.login.j_username.focus()" leftmargin="0" topmargin="0" rightmargin="0">
+
+<form name="login" action="j_security_check" method="POST">
+  <table width="100%"  border="0" cellspacing="0" cellpadding="0">
+    <tr>
+		  <td>
+			  <table width="100%" border="0" cellspacing="0" cellpadding="0">
+				  <tr>
+						<td class="Logo" width="200">GERONIMO CONSOLE</td>
+						<td class="Top">&nbsp;</td>
+					</tr>
+				</table>
+			</td>
+    </tr>
+    <tr>
+      <td>&nbsp;</td>
+    </tr>
+    <tr>
+      <td class="Content"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+        <tr>
+          <td width="10">&nbsp;</td>
+          <td valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+            <tr>
+              <td width="10" class="TopLeft">&nbsp;</td>
+              <td class="Title">WELCOME TO Geronimo Console&#8482;</td>
+              <td width="10" class="TopRight">&nbsp;</td>
+            </tr>
+            <tr>
+              <td class="Left">&nbsp;</td>
+              <td class="Body">&nbsp;</td>
+              <td class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td width="10" height="200" class="Left">&nbsp;</td>
+              <td height="200" valign="top" class="Body"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                <tr>
+                  <td align="center" valign="top"><table width="100%"  border="0" cellspacing="1" cellpadding="5">
+                    <tr>
+                      <td width="5">&nbsp;</td>
+                      <td> <strong>GERONIMO&#8482;</strong> is a Java-certified, production-grade platform designed to allow developers to rapidly deploy and manage their applications. The result is an integrated, highly functional application platform that leverages the latest innovations from the open source community and simplifies application deployment and maintenance. </td>
+                      <td width="5">&nbsp;</td>
+                    </tr>
+                    <tr>
+                      <td>&nbsp;</td>
+                      <td>&nbsp;</td>
+                      <td>&nbsp;</td>
+                    </tr>
+                    <tr>
+                      <td>&nbsp;</td>
+                      <td> <p><strong>Geronimo Console&#8482;</strong> has integrated the following components: </p>
+                        <p>&#149;&nbsp; Application server (Apache Geronimo) </p>
+                        <p>&#149;&nbsp; Web server and servlet engine (Jetty) </p>
+                        <p>&#149;&nbsp; JSP compiler (Jasper) </p>
+                        <p>&#149;&nbsp; Relational database (Apache Derby) </p>
+                        <p>&#149;&nbsp; JSR 168 portlet container (Apache Pluto) </p>
+                        <p>&#149;&nbsp; Messaging (ActiveMQ) </p>
+                        <p>&#149;&nbsp; User management services </p>
+                        <p>&#149;&nbsp; Centralized administration console </p>
+                      <td>&nbsp;</td>
+                    </tr>
+                  </table></td>
+                  <td width="10">&nbsp;</td>
+                  <td width="350" height="300" align="center" valign="top">                    <table width="250" cellpadding="0" cellspacing="0" border="0">
+                      <tr>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td width="50" class="DarkBackground">LOGIN</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground" align="center"><font color="red"><b><i>Invalid Username and/or Password!</i></b></font></td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td width="6" class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground"><strong>Username</strong></td>
+                              <td class="LightBackground"><strong>:</strong></td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground"><input name="j_username" type="text" class="InputField" value="" size="20px" maxlength="25"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground"><strong>Password</strong></td>
+                              <td class="LightBackground"><strong>:</strong></td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground"><input name="j_password" type="password" class="InputField" value="" size="20px" maxlength="25"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td colspan="4" align="center" class="LightBackground"><input name="submit" type="submit" value="Login"/></td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                            <tr>
+                              <td width="14" class="LightBackground">&nbsp;</td>
+                              <td align="right" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="1" class="LightBackground">&nbsp;</td>
+                              <td class="LightBackground">&nbsp;</td>
+                              <td width="17" class="LightBackground">&nbsp;</td>
+                            </tr>
+                        </table></td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                        <td class="LightBackground">&nbsp;</td>
+                      </tr>
+                      <tr>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                        <td class="DarkBackground">&nbsp;</td>
+                      </tr>
+                    </table>
+                    <p>&nbsp;</p></td>
+                </tr>
+              </table></td>
+              <td width="10" height="200" class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td class="Left">&nbsp;</td>
+              <td class="Body">&nbsp;</td>
+              <td class="Right">&nbsp;</td>
+            </tr>
+            <tr>
+              <td width="10" class="BottomLeft">&nbsp;</td>
+              <td class="Footer">&nbsp;</td>
+              <td width="10" class="BottomRight">&nbsp;</td>
+            </tr>
+          </table></td>
+          <td width="10">&nbsp;</td>
+          <td width="300" valign="top">            <table width="100%"  border="0" cellspacing="0" cellpadding="0">
+              <tr>
+                <td width="10">&nbsp;</td>
+                <td><img src="images/related_links.gif"></td>
+                <td width="10">&nbsp;</td>
+              </tr>
+              <tr>
+                <td height="7"><img src="images/spacer.gif"></td>
+                <td height="7" class="Body"><img src="images/spacer.gif"></td>
+                <td height="7"><img src="images/spacer.gif"></td>
+              </tr>
+              <tr>
+                <td width="10">&nbsp;</td>
+                <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Technical Support</a></td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Download Updates</a> </td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td align="center">&nbsp;</td>
+                    <td>&nbsp;</td>
+                    <td>&nbsp;</td>
+                  </tr>
+                  <tr>
+                    <td width="20" align="center"><img src="images/bullet.gif"></td>
+                    <td><a href="http://">Mailing List</a></td>
+                    <td width="10">&nbsp;</td>
+                  </tr>
+                </table></td>
+                <td width="10">&nbsp;</td>
+              </tr>
+            </table>
+            </td>
+          <td width="10">&nbsp;</td>
+        </tr>
+      </table></td>
+    </tr>
+    <tr>
+      <td>&nbsp;</td>
+    </tr>
+  </table>
+</form>
+</body>
+</html>

Added: geronimo/trunk/sandbox/console-framework/src/webapp/logout.jsp
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/logout.jsp?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/logout.jsp (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/logout.jsp Wed Jul 20 18:38:12 2005
@@ -0,0 +1,5 @@
+<%@ page language="java" %>
+<%
+    request.getSession().invalidate();
+	response.sendRedirect("./portal/info");
+%>
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/console-framework/src/webapp/logout.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-framework/src/webapp/main.css
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/main.css?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/main.css (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/main.css Wed Jul 20 18:38:12 2005
@@ -0,0 +1,425 @@
+body {
+	/*background-color: #9999CC;*/
+}
+
+td
+{
+	font-size: 11px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+}
+
+a:link, a:visited
+{
+	color: #204486;
+}
+
+a:hover 
+{
+	color: #CF820A;
+}
+
+.Logo
+{
+	/*background-image:url("images/joe_logo.gif");*/
+	width: 200px;
+	height: 100px;
+    color: #FFFFFF;
+	font-size: 35px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	text-align: right;
+	/*vertical-align: bottom;*/
+	line-height: 30px;
+	background-color: #909DB8;
+	font-weight: bold;
+}
+
+.Top
+{
+	/*background-image: url("images/mgmtconsole.jpg");*/
+	background-repeat: no-repeat;
+	color: #FFFFFF;
+	font-size: 11px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	text-align: right;
+	vertical-align: bottom;
+	line-height: 30px;
+	background-color: #909DB8;
+	font-weight: bold;
+}
+
+.Top a:link, .Top a:visited, .Top a:hover
+{
+	color: #FFFFFF;
+	font-size: 11px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	text-decoration: underline;
+	text-align: left;
+	vertical-align: bottom;
+	line-height: 30px;
+	font-weight: bold;
+}
+
+.TopSpacer
+{
+	height: 20px;
+}
+
+.Hidden
+{
+	visibility: hidden;
+	height: 0px;
+	line-height: 0px;
+	display: none;
+}
+
+.Menu .Selection
+{
+	font-size: 12px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+}
+
+.Menu .Selection .CollapsedLeft
+{
+	width: 12px;
+	height: 12px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .Indent
+{
+	width: 2px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .CollapsedRight
+{
+	width: 8px;
+	height: 12px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .TopLeft
+{
+	width: 8px;
+	height: 16px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .TopMiddle
+{
+	color: #333333;
+	text-decoration: none;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .TopMiddle a:link, 
+.Menu .Selection .TopMiddle a:visited, 
+.Menu .Selection .TopMiddle a:hover
+{
+	color: #FFFFFF;
+	line-height: 20px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .TopRight
+{
+	width: 8px;
+	height: 16px;
+  background-color: #919FBC;
+}
+
+.Menu .Selection .Spacer
+{
+	height: 5px;
+}
+
+.Menu .Hidden
+{
+	visibility: hidden;
+	height: 0px;
+	display: none;
+}
+
+.Menu .Subselection .Left
+{
+	width: 12px;
+  background-color: #919FBC;
+}
+
+.Menu .Subselection .Indent
+{
+	width: 2px;
+  background-color: #919FBC;
+}
+
+.Menu .Subselection .Middle
+{
+	font-size: 12px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+  background-color: #919FBC;
+	color:#333333;
+}
+
+.Menu .Subselection .Middle a:link, 
+.Menu .Subselection .Middle a:visited, 
+.Menu .Subselection .Middle a:hover
+{
+	line-height: 20px;
+	color: #FFFFFF;
+}
+
+.Menu .Subselection .Right
+{
+	width: 8px;
+  background-color: #919FBC;
+}
+
+.Menu .Subselection .BottomLeft
+{
+	width: 8px;
+	height: 8px;
+  background-color: #919FBC;
+}
+
+.Menu .Subselection .BottomMiddle
+{
+	height: 8px;
+  background-color: #919FBC;
+}
+
+.Menu .Subselection .BottomRight
+{
+	width: 8px;
+	height: 8px;
+  background-color: #919FBC;
+}
+
+.Gutter
+{
+	width: 5px;
+}
+
+.Content .TopLeft
+{
+	width: 18px;
+	height: 18px;
+	line-height: 18px;
+  background-color:#333366;
+}
+
+.Content .Title
+{
+	font-size: 12px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	background-color: #333366;
+	color: #FCFCFC;
+	height: 18px;
+	line-height: 18px;
+}
+
+.Content .Title a:link, .Content .Title a:hover, .Content .Title a:visited
+{
+	font-size: 12px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	background-color: #333366;
+	color:#CCCCFF;
+	height: 18px;
+	line-height: 18px;
+}
+
+.Content .Title .Indent
+{
+	width: 20px;
+}
+
+.Content .TopRight
+{
+	width: 18px;
+	height: 18px;
+  background-color:#333366;
+}
+
+.Content .CollapsedLeft
+{
+	width: 18px;
+	height: 18px;
+  background-color:#000000;
+}
+
+.Content .CollapsedRight
+{
+	width: 18px;
+	height: 18px;
+  background-color:#000000;
+}
+
+.Content .Left
+{
+	width: 18px;
+	/*background-color: #333366;*/
+	background-color: #DADEE9;
+}
+
+.Content .Body, .Content .Body td
+{
+	font-size: 12px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	background-color: #DADEE9;
+	color: #1E1E52;
+}
+
+.Content .Body strong
+{
+	font-weight: bold;  
+	font-size: 12px;
+}
+
+.Content .Body th
+{
+	font-weight: bold;  
+	font-size: 12px;
+}
+
+.Content .Body .LightBackground
+{
+	background-color: #E8E8F7;
+	color:#333333;
+}
+
+.Content .Body .LightBackground .InputField
+{
+  width: 150px;
+}
+.Content .Body .MediumBackground
+{
+	background-color: #CCCCCC;
+	color:#000000;
+}
+
+.Content .Body .DarkBackground, 
+.Content .Body .DarkBackground a:link, 
+.Content .Body .DarkBackground a:visited,
+.Content .Body .DarkBackground a:hover
+{
+	background-color: #5C6B8D;
+	color:#FCFCFC;
+}
+
+.Content .Body .IndentedTitle
+{
+	background-color: #919FBC;
+	color:#FFFFFF;
+}
+
+.Content .Body .LightIndentedBG
+{
+	background-color: #FFFFFF;
+	color:#000000;
+}
+
+.Content .Body .MediumIndentedBG
+{
+	background-color: #DDDDDD;
+	color:#000000;
+}
+
+
+.Content .Body a:link,
+.Content .Body a:visited,
+.Content .Body a:hover
+{
+	font-size: 10px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	text-decoration: underline;
+	color: #546BC7;
+	font-weight: bold;
+}
+
+.Content .Buttons {
+	border-top-width: thin;
+	border-right-width: thin;
+	border-bottom-width: thin;
+	border-left-width: thin;
+	border-top-style: solid;
+	border-right-style: solid;
+	border-bottom-style: solid;
+	border-left-style: solid;
+	border-top-color: #7B7BAE;
+	border-right-color: #7B7BAE;
+	border-bottom-color: #141336;
+	border-left-color: #141336;
+	background-color: #23224C;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	font-size: 12px;
+  text-decoration: underline;
+	color: #CCCCCC;
+}
+
+.Content .Right
+{
+	width: 18px;
+	background-color: #DADEE9;
+}
+
+.Content .BottomLeft
+{
+	width: 18px;
+	height: 12px;
+	line-height: 12px;
+	background-color:#333366;
+}
+
+.Content .Footer
+{
+	line-height: 12px;
+	height: 12px;
+	font-size: 9px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	background-color:#333366;
+	color:#FFFFFF;
+}
+
+.Content .Footer a:link,
+.Content .Footer a:visited,
+.Content .Footer a:hover
+{
+	color:#FF9900;
+}
+
+.Content .BottomRight
+{
+	width: 18px;
+	line-height: 12px;
+	height: 12px;
+	background-color:#333366;
+}
+
+.Content .Spacer
+{
+	height: 10px;
+}
+
+.BottomSpacer
+{
+}
+
+.Footer
+{
+	font-size: 9px;
+	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
+	height: 20px;
+	background-color: #CCCCCC;
+}
+
+.Footer a:link, 
+.Footer a:visited, 
+.Footer a:hover
+{
+	color:#006699;
+	text-decoration: underline;	
+}
+
+.Box
+{
+	border: thin solid #333333;
+}
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/console-framework/src/webapp/main.css
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-framework/src/webapp/pluto_style.css
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-framework/src/webapp/pluto_style.css?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-framework/src/webapp/pluto_style.css (added)
+++ geronimo/trunk/sandbox/console-framework/src/webapp/pluto_style.css Wed Jul 20 18:38:12 2005
@@ -0,0 +1,31 @@
+BODY, P, TH, TD {
+    font-family: arial, helvetica, sans-serif;
+    text-align: left;
+}
+
+.BODY, .P, .TD {
+    font-size: 12px;
+}
+
+TABLE {
+    width: 100%;
+    padding: 2px 3px;
+    border-collapse:collapse;
+    border-spacing: 3px 3px;
+}
+
+
+.banner, .banner TD, .banner A:link, .banner A:visited, .banner A:hover {
+    background-color: #DDDDDD;
+    color: #36a;
+}
+
+.nav, .nav TD, .nav A:link, .nav A:visited, .nav A:hover {
+    background-color: #DDDDDD;
+    color: #36a;
+}
+
+.small {
+    font-size: -1;
+}
+

Propchange: geronimo/trunk/sandbox/console-framework/src/webapp/pluto_style.css
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/maven.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/maven.xml?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/maven.xml (added)
+++ geronimo/trunk/sandbox/console-standard/maven.xml Wed Jul 20 18:38:12 2005
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project default="default"
+    xmlns:j="jelly:core"
+    xmlns:ant="jelly:ant"
+    xmlns:define="jelly:define"
+    xmlns:velocity="jelly:velocity"
+    xmlns:util="jelly:util">
+
+    <preGoal name="war:install">
+        <attainGoal name="preCompile"/>
+    </preGoal>
+
+    <!-- Output folder for compiled jsps. -->
+    <j:set var="outDir"  value="${basedir}/target/${pom.artifactId}/WEB-INF/work"/>     
+    
+    <!-- pre compile jsps -->   
+    <goal name="default">
+    	<ant:echo>${commons_fileupload_version}</ant:echo>
+        <ant:mkdir dir="${outDir}"/>         
+        <attainGoal name="war:install"/>
+    </goal>
+    
+    <!-- ==================================================== -->
+    <!-- Pre compile JSPs                                     -->
+    <!-- ==================================================== -->
+    <goal name="preCompile">
+        <ant:path id="jspc.classpath">
+            <ant:path refid="maven.dependency.classpath"/>
+            <ant:pathelement path="${maven.build.dest}"/>
+        </ant:path>
+        <ant:echo>Pre-compiling JSPs from ${basedir}/src/webapp to ${outDir}.</ant:echo>
+        <ant:java classname="org.apache.jasper.JspC" fork="true" failonerror="true" classpathref="jspc.classpath">
+            <arg value="-d"/>
+            <arg value="${outDir}"/>
+            <arg value="-webapp"/>
+            <arg value="${basedir}/src/webapp"/>
+        </ant:java>
+        <ant:echo>Compiling generated Java files in ${outDir}.</ant:echo>               
+        <ant:javac
+            srcdir="${outDir}"
+            destdir="${outDir}"
+            debug="${maven.compile.debug}"
+            deprecation="${maven.compile.deprecation}"
+            optimize="${maven.compile.optimize}"
+            classpathref="jspc.classpath"/>
+    </goal>  
+
+</project>

Added: geronimo/trunk/sandbox/console-standard/project.properties
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/project.properties?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/project.properties (added)
+++ geronimo/trunk/sandbox/console-standard/project.properties Wed Jul 20 18:38:12 2005
@@ -0,0 +1 @@
+maven.multiproject.type=war
\ No newline at end of file

Propchange: geronimo/trunk/sandbox/console-standard/project.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/project.xml
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/project.xml?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/project.xml (added)
+++ geronimo/trunk/sandbox/console-standard/project.xml Wed Jul 20 18:38:12 2005
@@ -0,0 +1,253 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project>
+    <pomVersion>3</pomVersion>
+    <extend>../../etc/project.xml</extend>
+
+    <id>geronimo-console-standard</id>
+    <name>Geronimo :: Console :: Standard Portlets</name>
+
+    <dependencies>
+        <dependency>
+            <groupId>jetty</groupId>
+            <artifactId>org.mortbay.jetty</artifactId>
+            <version>${jetty_version}</version>
+            <properties>
+                <repository>true</repository>
+            </properties>
+        </dependency>
+        <dependency>
+             <groupId>geronimo</groupId>
+             <artifactId>geronimo-connector</artifactId>
+             <version>${pom.currentVersion}</version>
+         </dependency>
+         <dependency>
+             <groupId>geronimo</groupId>
+             <artifactId>geronimo-deployment</artifactId>
+             <version>${pom.currentVersion}</version>
+         </dependency>
+         <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-jetty</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-j2ee</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+        <dependency>
+            <groupId>geronimo-spec</groupId>
+            <artifactId>geronimo-spec-servlet</artifactId>
+            <version>${geronimo_spec_servlet_version}</version>
+        </dependency>
+        <dependency>
+             <groupId>geronimo</groupId>
+             <artifactId>geronimo-common</artifactId>
+             <version>${pom.currentVersion}</version>
+         </dependency>
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-kernel</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-system</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+<!--        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>-->
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-security</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+        <dependency>
+            <groupId>mx4j</groupId>
+            <artifactId>mx4j</artifactId>
+            <version>${mx4j_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>portlet-api</groupId>
+            <artifactId>portlet-api</artifactId>
+            <version>${portlet_api_version}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>commons-digester</groupId>
+            <artifactId>commons-digester</artifactId>
+            <version>${commons_digester_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>
+        <dependency>
+            <groupId>commons-fileupload</groupId>
+            <artifactId>commons-fileupload</artifactId>
+            <version>${commons_fileupload_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>
+        <dependency>
+            <groupId>commons-io</groupId>
+            <artifactId>commons-io</artifactId>
+            <version>${commons_io_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>
+        <!-- Portlet services manager dependencies -->
+        <dependency>
+            <groupId>pluto</groupId>
+            <artifactId>pluto</artifactId>
+            <version>${pluto_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>pluto</groupId>
+            <artifactId>pluto-portal</artifactId>
+            <version>${pluto_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>castor</groupId>
+            <artifactId>castor</artifactId>
+            <version>${castor_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>
+
+        <!-- JMS dependencies -->
+         <dependency>
+            <groupId>geronimo-spec</groupId>
+            <artifactId>geronimo-spec-jms</artifactId>
+            <version>${geronimo_spec_jms_version}</version>
+        </dependency>  
+         <dependency>
+            <groupId>activemq</groupId>
+            <artifactId>activemq-core</artifactId>
+            <version>${activemq_version}</version>
+        </dependency>              
+
+        <!-- Logging -->
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <version>${commons_logging_version}</version>
+        </dependency>
+                
+        <!-- Testing dependencies -->
+        <dependency>
+            <groupId>cglib</groupId>
+            <artifactId>cglib-nodep</artifactId>
+            <version>${cglib_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-console-core</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+        <!-- LogManager dependency remember to remove later when/if this is moved into a GBean -->
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+            <version>${log4j_version}</version>
+        </dependency>
+
+        <!-- Used to pre compile JSPs -->
+        <dependency>
+            <groupId>ant</groupId>
+            <artifactId>ant</artifactId>
+            <version>${ant_version}</version>
+<!--            <properties>
+                <repository>true</repository>
+            </properties> -->
+        </dependency>
+        <dependency>
+            <groupId>commons-el</groupId>
+            <artifactId>commons-el</artifactId>
+            <version>${commons_el_version}</version>
+            <url>http://jakarta.apache.org/commons/el/</url>
+            <properties>
+                <repository>true</repository>
+            </properties>
+        </dependency>                       
+        <dependency>
+            <groupId>geronimo-spec</groupId>
+            <artifactId>geronimo-spec-j2ee</artifactId>
+            <version>${geronimo_spec_j2ee_version}</version>
+            <properties>
+                <repository>true</repository>
+            </properties>
+        </dependency>
+        <dependency>
+            <groupId>taglibs</groupId>
+            <artifactId>standard</artifactId>
+            <version>${standard_taglibs_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>        
+        <dependency>
+            <groupId>jstl</groupId>
+            <artifactId>jstl</artifactId>
+            <version>${jstl_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>        
+        <dependency>
+            <groupId>tomcat</groupId>
+            <artifactId>jasper-runtime</artifactId>
+            <version>${jasper_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>        
+        <dependency>
+            <groupId>tomcat</groupId>
+            <artifactId>jasper-compiler</artifactId>
+            <version>${jasper_version}</version>
+            <properties>
+                <war.bundle>true</war.bundle>
+            </properties>
+        </dependency>
+
+    </dependencies>
+
+    <build>
+        <sourceDirectory>src/java</sourceDirectory>
+        <unitTestSourceDirectory>src/test</unitTestSourceDirectory>
+
+        <resources>
+            <resource>
+                <directory>${basedir}/src/java</directory>
+                <includes>
+                    <include>**/*.properties</include>
+                </includes>
+            </resource>
+        </resources>
+
+        <unitTest>
+            <includes>
+                <include>**/*Test.java</include>
+            </includes>
+            <resources>
+                <resource>
+                    <directory>${basedir}/src/test-resources</directory>
+                    <includes>
+                        <include>**/*.xml</include>
+                    </includes>
+                </resource>
+            </resources>
+        </unitTest>
+    </build>
+
+    <reports>
+        <report>maven-junit-report-plugin</report>
+    </reports>
+
+</project>

Propchange: geronimo/trunk/sandbox/console-standard/project.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/ConfigManagerPortlet.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/ConfigManagerPortlet.java?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/ConfigManagerPortlet.java (added)
+++ geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/ConfigManagerPortlet.java Wed Jul 20 18:38:12 2005
@@ -0,0 +1,262 @@
+/**
+ *
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable.
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.console.configmanager;
+
+import java.io.IOException;
+import java.net.URI;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.management.ObjectName;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletConfig;
+import javax.portlet.PortletException;
+import javax.portlet.PortletRequestDispatcher;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.WindowState;
+
+import org.apache.geronimo.console.util.ObjectNameConstants;
+import org.apache.geronimo.console.util.SecurityConstants;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.KernelRegistry;
+import org.apache.geronimo.kernel.config.ConfigurationInfo;
+import org.apache.geronimo.kernel.config.ConfigurationManager;
+import org.apache.geronimo.kernel.config.ConfigurationUtil;
+import org.apache.geronimo.kernel.config.InvalidConfigException;
+import org.apache.geronimo.kernel.config.NoSuchConfigException;
+import org.apache.geronimo.kernel.config.NoSuchStoreException;
+import org.apache.geronimo.kernel.jmx.JMXUtil;
+import org.apache.geronimo.kernel.management.State;
+
+public class ConfigManagerPortlet extends GenericPortlet {
+
+    private static final String START_ACTION = "start";
+
+    private static final String STOP_ACTION = "stop";
+
+    private static final String UNINSTALL_ACTION = "uninstall";
+
+    private static final String CONTAINSCONFIG_METHOD = "containsConfiguration";
+
+    private static final String UNINSTALL_METHOD = "uninstall";
+
+    private static final String[] CONTAINSCONFIG_SIG = { URI.class.getName() };
+
+    private static final String[] UNINSTALL_SIG = { URI.class.getName() };
+
+    private static final String QUEUETOPIC_URI = "runtimedestination/";
+
+    private static final ObjectName deployer = JMXUtil
+            .getObjectName(ObjectNameConstants.DEPLOYER_OBJECT_NAME);
+
+    private String messageInstalled = "";
+
+    private String messageStatus = "";
+
+    private Kernel kernel;
+
+    private PortletRequestDispatcher normalView;
+
+    private PortletRequestDispatcher maximizedView;
+
+    private PortletRequestDispatcher helpView;
+
+    private static final Collection EXCLUDED;
+
+    static {
+        // Add list of the configurationIDs that you do not want to list to this
+        // List.
+        EXCLUDED = new ArrayList();
+    }
+
+    public void processAction(ActionRequest actionRequest,
+            ActionResponse actionResponse) throws PortletException, IOException {
+        String action = actionRequest.getParameter("action");
+        actionResponse.setRenderParameter("message", ""); // set to blank first
+        try {
+            ConfigurationManager configurationManager = ConfigurationUtil
+                    .getConfigurationManager(kernel);
+            ObjectName configName = null;
+            String config = getConfigID(actionRequest);
+            if (configurationManager.isLoaded(URI.create(config)))
+                configName = JMXUtil
+                        .getObjectName(ObjectNameConstants.CONFIG_GBEAN_PREFIX
+                                + "\"" + getConfigID(actionRequest) + "\"");
+            else
+                configName = configurationManager.load(URI.create(config));
+
+            if (START_ACTION.equals(action)) {
+                kernel.startRecursiveGBean(configName);
+                //kernel.startConfiguration(getConfigID(actionRequest));
+                messageStatus = "Started application<br /><br />";
+            } else if (STOP_ACTION.equals(action)) {
+                kernel.stopGBean(configName);
+                //kernel.stopConfiguration(getConfigID(actionRequest));
+                messageStatus = "Stopped application<br /><br />";
+            } else if (UNINSTALL_ACTION.equals(action)) {
+                uninstallConfig(actionRequest);
+                messageStatus = "Uninstalled application<br /><br />";
+            } else {
+                messageStatus = "Invalid value for changeState: " + action
+                        + "<br /><br />";
+                throw new PortletException("Invalid value for changeState: "
+                        + action);
+            }
+        } catch (NoSuchConfigException e) {
+            // ignore this for now
+            messageStatus = "Configuration not found<br /><br />";
+            throw new PortletException("Configuration not found", e);
+        } catch (InvalidConfigException e) {
+            messageStatus = "Configuration not found<br /><br />";
+            throw new PortletException("Configuration not found", e);
+        } catch (Exception e) {
+            messageStatus = "Encountered an unhandled exception<br /><br />";
+            throw new PortletException("Exception", e);
+        }
+    }
+
+    /**
+     * Uninstall an application configuration
+     *
+     * @param actionRequest
+     * @throws PortletException
+     * @throws Exception
+     */
+    private void uninstallConfig(ActionRequest actionRequest)
+            throws PortletException, Exception {
+        ConfigurationManager configManager = ConfigurationUtil
+                .getConfigurationManager(kernel);
+        List configStores = configManager.listStores();
+        int size = configStores.size();
+        String configID = getConfigID(actionRequest);
+        for (int i = 0; i < size; i++) {
+            ObjectName configStore = (ObjectName) configStores.get(i);
+            Boolean result = (Boolean) kernel.invoke(configStore,
+                    CONTAINSCONFIG_METHOD,
+                    new Object[] { URI.create(configID) }, CONTAINSCONFIG_SIG);
+            if (result.booleanValue() == true) {
+                // stop config if running
+                if (configManager.isLoaded(URI.create(configID))) {
+                    //int state = kernel.getConfigurationState(configID);
+                    int state = kernel
+                            .getGBeanState(JMXUtil
+                                    .getObjectName(ObjectNameConstants.CONFIG_GBEAN_PREFIX
+                                            + "\"" + configID + "\""));
+                    if (state == State.RUNNING.toInt()) {
+                        //kernel.stopConfiguration(configID);
+                        kernel
+                                .stopGBean(JMXUtil
+                                        .getObjectName(ObjectNameConstants.CONFIG_GBEAN_PREFIX
+                                                + "\"" + configID + "\""));
+                    }
+                }
+                kernel.invoke(configStore, UNINSTALL_METHOD, new Object[] { URI
+                        .create(configID) }, UNINSTALL_SIG);
+            }
+        }
+    }
+
+    /*
+     * private URI getConfigID(ActionRequest actionRequest) throws
+     * PortletException { URI configID; try { configID = new
+     * URI(actionRequest.getParameter("configId")); } catch (URISyntaxException
+     * e) { throw new PortletException("Invalid configId parameter: " +
+     * actionRequest.getParameter("configId")); } return configID; }
+     */
+
+    private String getConfigID(ActionRequest actionRequest)
+            throws PortletException {
+        return actionRequest.getParameter("configId");
+    }
+
+    protected void doView(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws IOException, PortletException {
+        if (WindowState.MINIMIZED.equals(renderRequest.getWindowState())) {
+            return;
+        }
+
+        List configInfo = new ArrayList();
+        ConfigurationManager configManager = ConfigurationUtil
+                .getConfigurationManager(kernel);
+        List stores = configManager.listStores();
+        for (Iterator i = stores.iterator(); i.hasNext();) {
+            ObjectName storeName = (ObjectName) i.next();
+            try {
+                List infos = configManager.listConfigurations(storeName);
+                for (Iterator j = infos.iterator(); j.hasNext();) {
+                    ConfigurationInfo info = (ConfigurationInfo) j.next();
+                    if (!EXCLUDED.contains(info.getConfigID())) {
+                        // TODO: Check if this is the right solution
+                        // Disregard JMS Queues and Topics &&
+                        if (!info.getConfigID().getPath().startsWith(
+                                QUEUETOPIC_URI)
+                                && !info
+                                        .getConfigID()
+                                        .getPath()
+                                        .startsWith(
+                                                SecurityConstants.SECURITY_CONFIG_PREFIX)) {
+                            configInfo.add(info);
+                        }
+                    }
+                }
+            } catch (NoSuchStoreException e) {
+                // we just got this list so this should not happen
+                // in the unlikely event it does, just continue
+            }
+        }
+        renderRequest.setAttribute("configurations", configInfo);
+        messageInstalled = configInfo.size() == 0 ? "No Installed Applications<br /><br />"
+                : "";
+        renderRequest.setAttribute("messageInstalled", messageInstalled);
+        renderRequest.setAttribute("messageStatus", messageStatus);
+        messageStatus = "";
+        if (WindowState.NORMAL.equals(renderRequest.getWindowState())) {
+            normalView.include(renderRequest, renderResponse);
+        } else {
+            maximizedView.include(renderRequest, renderResponse);
+        }
+    }
+
+    protected void doHelp(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws PortletException, IOException {
+        helpView.include(renderRequest, renderResponse);
+    }
+
+    public void init(PortletConfig portletConfig) throws PortletException {
+        super.init(portletConfig);
+        kernel = KernelRegistry.getSingleKernel();
+        normalView = portletConfig.getPortletContext().getRequestDispatcher(
+                "/WEB-INF/view/configmanager/normal.jsp");
+        maximizedView = portletConfig.getPortletContext().getRequestDispatcher(
+                "/WEB-INF/view/configmanager/maximized.jsp");
+        helpView = portletConfig.getPortletContext().getRequestDispatcher(
+                "/WEB-INF/view/configmanager/help.jsp");
+    }
+
+    public void destroy() {
+        normalView = null;
+        maximizedView = null;
+        kernel = null;
+        super.destroy();
+    }
+}

Propchange: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/ConfigManagerPortlet.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/DeploymentPortlet.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/DeploymentPortlet.java?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/DeploymentPortlet.java (added)
+++ geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/DeploymentPortlet.java Wed Jul 20 18:38:12 2005
@@ -0,0 +1,201 @@
+/**
+ *
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable.
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.console.configmanager;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URI;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.management.ObjectName;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletConfig;
+import javax.portlet.PortletException;
+import javax.portlet.PortletRequestDispatcher;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+
+import org.apache.commons.fileupload.FileItem;
+import org.apache.commons.fileupload.FileUploadException;
+import org.apache.commons.fileupload.disk.DiskFileItemFactory;
+import org.apache.commons.fileupload.portlet.PortletFileUpload;
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.console.util.ObjectNameConstants;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.KernelRegistry;
+import org.apache.geronimo.kernel.config.ConfigurationManager;
+import org.apache.geronimo.kernel.config.ConfigurationUtil;
+import org.apache.geronimo.kernel.jmx.JMXUtil;
+
+public class DeploymentPortlet extends GenericPortlet {
+    private final String LINE_SEP = System.getProperty("line.separator");
+
+    private PortletRequestDispatcher deployView;
+
+    private PortletRequestDispatcher helpView;
+
+    private Kernel kernel;
+
+    private static final String[] ARGS = { File.class.getName(),
+            File.class.getName() };
+
+    private static final ObjectName deployer = JMXUtil
+            .getObjectName(ObjectNameConstants.DEPLOYER_OBJECT_NAME);
+
+    private boolean messageNotRendered = true;
+
+    public void processAction(ActionRequest actionRequest,
+            ActionResponse actionResponse) throws PortletException, IOException {
+        messageNotRendered = true;
+        if (!PortletFileUpload.isMultipartContent(actionRequest)) {
+            throw new PortletException("Expected file upload");
+        }
+
+        File rootDir = new File(System.getProperty("java.io.tmpdir"));
+        PortletFileUpload uploader = new PortletFileUpload(
+                new DiskFileItemFactory(10240, rootDir));
+        File moduleFile = null;
+        File planFile = null;
+        String startApp = null;
+        try {
+            List items = uploader.parseRequest(actionRequest);
+            for (Iterator i = items.iterator(); i.hasNext();) {
+                FileItem item = (FileItem) i.next();
+                if (!item.isFormField()) {
+                    String fieldName = item.getFieldName();
+                    String name = item.getName().trim();
+                    File file;
+                    if (name.length() == 0) {
+                        file = null;
+                    } else {
+                        // Firefox sends basename, IE sends full path
+                        int index = name.lastIndexOf('\\');
+                        if (index != -1) {
+                            name = name.substring(index + 1);
+                        }
+                        file = new File(rootDir, name);
+                    }
+                    if ("module".equals(fieldName)) {
+                        moduleFile = file;
+                    } else if ("plan".equals(fieldName)) {
+                        planFile = file;
+                    }
+                    if (file != null) {
+                        try {
+                            item.write(file);
+                        } catch (Exception e) {
+                            throw new PortletException(e);
+                        }
+                    }
+                } else {
+                    // retrieve 'startApp' form field value
+                    if ("startApp".equalsIgnoreCase(item.getFieldName())) {
+                        startApp = item.getString();
+                    }
+                }
+            }
+        } catch (FileUploadException e) {
+            throw new PortletException(e);
+        }
+        try {
+            List list = (List) kernel.invoke(deployer, "deploy", new Object[] {
+                    moduleFile, planFile }, ARGS);
+            actionResponse.setRenderParameter("outcome",
+                    "The application was successfully deployed.<br/>");
+            // start installed app/s
+            if ((startApp != null) && "YES".equalsIgnoreCase(startApp)) {
+                ConfigurationManager configurationManager = ConfigurationUtil
+                        .getConfigurationManager(kernel);
+                int size = list.size();
+                // assumes installed app/s returned as a list
+                for (int i = 0; i < size; i++) {
+                    URI config = URI.create((String) list.get(i));
+                    // This is a hack that seems to work. Please fix this when
+                    // you understand what is happening or where you can get the
+                    // ObjectName from the configId without calling
+                    // ConfigurationManager.load(URI).
+                    if (configurationManager.isLoaded(config))
+                        configurationManager.unload(config);
+
+                    ObjectName configName = configurationManager.load(config);
+                    kernel.startRecursiveGBean(configName);
+                }
+            }
+        } catch (DeploymentException e) {
+            e.printStackTrace();
+            StringBuffer buf = new StringBuffer(256);
+            Throwable cause = e;
+            while (cause != null) {
+                append(buf, cause.getMessage());
+                buf.append(LINE_SEP);
+                cause = cause.getCause();
+            }
+            actionResponse.setRenderParameter("outcome", buf.toString());
+        } catch (Exception e) {
+            throw new PortletException(e);
+        }
+    }
+
+    private void append(StringBuffer buf, String message) {
+        for (int i = 0; i < message.length(); i++) {
+            char ch = message.charAt(i);
+            if (ch == '<') {
+                buf.append("&lt;");
+            } else if (ch == '>') {
+                buf.append("&gt;");
+            } else {
+                buf.append(ch);
+            }
+        }
+    }
+
+    protected void doView(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws PortletException, IOException {
+        if (messageNotRendered) {
+            renderRequest.setAttribute("outcome", renderRequest
+                    .getParameter("outcome"));
+            messageNotRendered = false;
+        }
+        deployView.include(renderRequest, renderResponse);
+        // clear previous message for next rendering
+    }
+
+    protected void doHelp(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws PortletException, IOException {
+        helpView.include(renderRequest, renderResponse);
+    }
+
+    public void init(PortletConfig portletConfig) throws PortletException {
+        super.init(portletConfig);
+        kernel = KernelRegistry.getSingleKernel();
+        deployView = portletConfig.getPortletContext().getRequestDispatcher(
+                "/WEB-INF/view/configmanager/deploy.jsp");
+        helpView = portletConfig.getPortletContext().getRequestDispatcher(
+                "/WEB-INF/view/configmanager/deployHelp.jsp");
+    }
+
+    public void destroy() {
+        deployView = null;
+        helpView = null;
+        kernel = null;
+        super.destroy();
+    }
+}

Propchange: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/configmanager/DeploymentPortlet.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/AbstractConnectionFactoryManagerPortlet.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/AbstractConnectionFactoryManagerPortlet.java?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/AbstractConnectionFactoryManagerPortlet.java (added)
+++ geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/AbstractConnectionFactoryManagerPortlet.java Wed Jul 20 18:38:12 2005
@@ -0,0 +1,324 @@
+/**
+ *
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable.
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.console.databasemanager;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.management.MalformedObjectNameException;
+import javax.management.ObjectName;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletConfig;
+import javax.portlet.PortletContext;
+import javax.portlet.PortletException;
+import javax.portlet.PortletRequestDispatcher;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.WindowState;
+
+import org.apache.geronimo.console.databasemanager.connectionmanager.ConnectionManagerRenderer;
+import org.apache.geronimo.console.databasemanager.generic.ConnectorRenderer;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.KernelRegistry;
+
+public abstract class AbstractConnectionFactoryManagerPortlet extends
+        GenericPortlet {
+
+    private final static DatabaseManagerHelper helper = new DatabaseManagerHelper();
+
+    private final static String PARENT_ID = "org/apache/geronimo/SystemDatabase";
+
+    private final static String ADDDS_MODE = "addDS";
+
+    private final static String SUBMIT_CREATE = "Create";
+
+    private final static String DATASOURCE_MSSQL = "MSSQLDataSource2";
+
+    protected static final Map RENDERERS = new HashMap();
+
+    private final ObjectName DATABASE_QUERY;
+
+    protected final String NORMAL_VIEW;
+
+    protected final String HELP_VIEW;
+
+    protected final String ADDDS_VIEW = "/WEB-INF/view/databasemanager/addDS.jsp";
+
+    protected final Class connectionFactoryClass;
+
+    protected Kernel kernel;
+
+    private PortletRequestDispatcher normalView;
+
+    private PortletRequestDispatcher helpView;
+
+    private PortletRequestDispatcher addDSView;
+
+    private ConnectorRenderer connectorRenderer;
+
+    private ConnectionManagerRenderer connectionManagerRenderer;
+
+    public AbstractConnectionFactoryManagerPortlet(
+            ObjectName ConnectionFactoryQuery, String NORMAL_VIEW,
+            String HELP_VIEW, Class connectionFactoryClass) {
+        this.DATABASE_QUERY = ConnectionFactoryQuery;
+        this.NORMAL_VIEW = NORMAL_VIEW;
+        this.HELP_VIEW = HELP_VIEW;
+        this.connectionFactoryClass = connectionFactoryClass;
+    }
+
+    public void processAction(ActionRequest actionRequest,
+            ActionResponse actionResponse) throws PortletException, IOException {
+        String mode = actionRequest.getParameter("mode");
+        String submit = actionRequest.getParameter("submit");
+
+        if (mode == null) {
+            return;
+        } else if (ADDDS_MODE.equals(mode)) {
+            actionResponse.setRenderParameter("mode", mode);
+            if (SUBMIT_CREATE.equals(submit)) {
+                String dsName = actionRequest.getParameter("dsName");
+                String jndiName = actionRequest.getParameter("jndiName");
+                String dependency = actionRequest.getParameter("dependency");
+                String driverClass = actionRequest.getParameter("driverClass");
+                String jdbcUrl = actionRequest.getParameter("jdbcUrl");
+                String dbUser = actionRequest.getParameter("dbUser");
+                String dbPassword = actionRequest.getParameter("dbPassword");
+                String dbProperties = actionRequest
+                        .getParameter("dbProperties");
+                String poolMaxSize = actionRequest.getParameter("poolMaxSize");
+                String poolInitSize = actionRequest
+                        .getParameter("poolInitSize");
+
+                String[] args = { trimStr(dsName), trimStr(PARENT_ID),
+                        trimStr(dependency), trimStr(dsName), trimStr(dbUser),
+                        dbPassword, trimStr(driverClass), trimStr(jdbcUrl),
+                        trimStr(poolMaxSize), trimStr(poolInitSize),
+                        trimStr(jndiName), trimStr(dbProperties) };
+                helper.deployPlan(args);
+                // Set mode to list after creating the new datasource
+                actionResponse.setRenderParameter("mode", "list");
+            }
+            return;
+        }
+
+        String name = actionRequest.getParameter("name");
+        if (name != null) {
+            ObjectName gbeanName = null;
+            try {
+                gbeanName = new ObjectName(name);
+            } catch (MalformedObjectNameException e) {
+                System.err.println("Invalid GBeanName: "
+                        + actionRequest.getParameter("name"));
+                actionResponse.setRenderParameter("mode", "list");
+                return;
+            }
+            // Process action if not MSSQL datasource
+            if (name.indexOf(DATASOURCE_MSSQL) == -1) {
+                connectionManagerRenderer.processAction(actionRequest,
+                        actionResponse, gbeanName);
+            }
+            getRenderer(gbeanName).processAction(actionRequest, actionResponse,
+                    gbeanName);
+        }
+    }
+
+    private String trimStr(String str) {
+        if (str != null) {
+            return str.trim();
+        }
+
+        return "";
+    }
+
+    protected void doView(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws IOException, PortletException {
+        if (WindowState.MINIMIZED.equals(renderRequest.getWindowState())) {
+            return;
+        }
+        List dependencies = helper.getDependencies();
+        // pass them to the render request
+        renderRequest.setAttribute("dependencies", (String[]) dependencies
+                .toArray(new String[dependencies.size()]));
+
+        String name = renderRequest.getParameter("name");
+        String mode = renderRequest.getParameter("mode");
+        String check = renderRequest.getParameter("check");
+
+        if ("addDS".equals(mode)) {
+            addDSView.include(renderRequest, renderResponse);
+            return;
+        }
+
+        boolean test = false;
+        if (name == null || mode == null) {
+            mode = "list";
+        }
+        if ("true".equals(check)) {
+            test = true;
+        }
+        if ("detail".equals(mode) || "config".equals(mode)) {
+            renderDetail(renderRequest, renderResponse, name);
+        } else {
+            renderList(renderRequest, renderResponse, name, test);
+        }
+    }
+
+    private void renderList(RenderRequest renderRequest,
+            RenderResponse renderResponse, String name, boolean check)
+            throws PortletException, IOException {
+        Set gbeanNames = kernel.listGBeans(DATABASE_QUERY);
+        List dataSources = new ArrayList(gbeanNames.size());
+        for (Iterator i = gbeanNames.iterator(); i.hasNext();) {
+            ObjectName gbeanName = (ObjectName) i.next();
+
+            // check that this connector is a DataSource
+            try {
+                Class cfInterface = Class.forName((String) kernel.getAttribute(
+                        gbeanName, "connectionFactoryInterface"));
+                if (!connectionFactoryClass.isAssignableFrom(cfInterface)) {
+                    continue;
+                }
+            } catch (Exception e) {
+                throw new PortletException(e);
+            }
+
+            DataSourceInfo info = new DataSourceInfo();
+            info.setObjectName(gbeanName);
+            info.setName(gbeanName.getKeyProperty("name"));
+            try {
+                info.setJndiName((String) kernel.getAttribute(gbeanName,
+                        "globalJNDIName"));
+                info
+                        .setState((Integer) kernel.getAttribute(gbeanName,
+                                "state"));
+                //check if user asked this connection to be tested
+                if ((gbeanName.toString().equals(name)) && (check)) {
+                    info.setWorking(true);
+                    try {
+                        Object cf = kernel.invoke(gbeanName, "$getResource");
+                        testConnection(cf);
+                        info.setMessage("Connected");
+                    } catch (Exception e) {
+                        Throwable t = e;
+                        String message = "Failed: ";
+                        if (t.getMessage() != null) {
+                            message = message + t.getMessage();
+                        } else {
+                            while (t.getMessage() == null) {
+                                t = t.getCause();
+                                if (t != null) {
+                                    message = message + t.getMessage();
+                                } else {
+                                    message = message + "Unknown reason";
+                                }
+                            }
+                        }
+                        info.setMessage(message);
+                    }
+                } else {
+                    info.setWorking(false);
+                }
+
+            } catch (Exception e) {
+                throw new PortletException(e);
+            }
+            dataSources.add(info);
+        }
+        Collections.sort(dataSources);
+        renderRequest.setAttribute("dataSources", dataSources);
+
+        normalView.include(renderRequest, renderResponse);
+    }
+
+    protected abstract void testConnection(Object cf) throws Exception;
+
+    private void renderDetail(RenderRequest renderRequest,
+            RenderResponse renderResponse, String name)
+            throws PortletException, IOException {
+        ObjectName gbeanName;
+        try {
+            gbeanName = new ObjectName(name);
+        } catch (MalformedObjectNameException e) {
+            throw new PortletException("Malformed parameter name: "
+                    + renderRequest.getParameter("name"));
+        }
+        connectionManagerRenderer.addConnectionManagerInfo(renderRequest,
+                gbeanName);
+        getRenderer(gbeanName).render(renderRequest, renderResponse, gbeanName);
+    }
+
+    protected void doHelp(RenderRequest renderRequest,
+            RenderResponse renderResponse) throws PortletException, IOException {
+        helpView.include(renderRequest, renderResponse);
+    }
+
+    public void init(PortletConfig portletConfig) throws PortletException {
+        super.init(portletConfig);
+        kernel = KernelRegistry.getSingleKernel();
+        PortletContext context = portletConfig.getPortletContext();
+        normalView = context.getRequestDispatcher(NORMAL_VIEW);
+        helpView = context.getRequestDispatcher(HELP_VIEW);
+        addDSView = context.getRequestDispatcher(ADDDS_VIEW);
+
+        connectorRenderer = new ConnectorRenderer(kernel, context);
+        setUpExplicitRenderers(context);
+        connectionManagerRenderer = new ConnectionManagerRenderer(kernel);
+    }
+
+    protected abstract void setUpExplicitRenderers(PortletContext context);
+
+    private DetailViewRenderer getRenderer(ObjectName gbeanName)
+            throws PortletException {
+        DetailViewRenderer renderer;
+        try {
+            String clsName = (String) kernel.getAttribute(gbeanName,
+                    "managedConnectionFactoryClass");
+            // ???
+            //Class mcfClass = Class.forName((String)
+            // kernel.getAttribute(gbeanName, "managedConnectionFactoryClass"));
+            //renderer = (DetailViewRenderer)
+            // RENDERERS.get(mcfClass.getName());
+            renderer = (DetailViewRenderer) RENDERERS.get(clsName);
+            if (renderer == null) {
+                renderer = connectorRenderer;
+            }
+        } catch (Exception e) {
+            throw new PortletException(e);
+        }
+        return renderer;
+    }
+
+    public void destroy() {
+
+        connectorRenderer = null;
+        connectionManagerRenderer = null;
+        normalView = null;
+        kernel = null;
+        RENDERERS.clear();
+        super.destroy();
+    }
+}

Propchange: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/AbstractConnectionFactoryManagerPortlet.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/DataSourceInfo.java
URL: http://svn.apache.org/viewcvs/geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/DataSourceInfo.java?rev=219976&view=auto
==============================================================================
--- geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/DataSourceInfo.java (added)
+++ geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/DataSourceInfo.java Wed Jul 20 18:38:12 2005
@@ -0,0 +1,98 @@
+/**
+ *
+ * Copyright 2004, 2005 The Apache Software Foundation or its licensors, as applicable.
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+
+package org.apache.geronimo.console.databasemanager;
+
+import javax.management.ObjectName;
+
+public class DataSourceInfo implements Comparable {
+    private ObjectName objectName;
+
+    private String name;
+
+    private String jndiName;
+
+    private Integer state;
+
+    private boolean working;
+
+    private String message;
+
+    public ObjectName getObjectName() {
+        return objectName;
+    }
+
+    public void setObjectName(ObjectName objectName) {
+        this.objectName = objectName;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getJndiName() {
+        return jndiName;
+    }
+
+    public void setJndiName(String jndiName) {
+        if (jndiName != null && !jndiName.startsWith("ger:")) {
+            StringBuffer buf = new StringBuffer(jndiName.length() + 4);
+            buf.append("ger:");
+            if (jndiName.charAt(0) != '/') {
+                ;
+            }
+            {
+                buf.append('/');
+            }
+            buf.append(jndiName);
+            jndiName = buf.toString();
+        }
+        this.jndiName = jndiName;
+    }
+
+    public Integer getState() {
+        return state;
+    }
+
+    public void setState(Integer state) {
+        this.state = state;
+    }
+
+    public int compareTo(Object o) {
+        return name.compareToIgnoreCase(((DataSourceInfo) o).name);
+    }
+
+    public boolean isWorking() {
+        return working;
+    }
+
+    public void setWorking(boolean working) {
+        this.working = working;
+    }
+
+    public String getMessage() {
+        return message;
+    }
+
+    public void setMessage(String message) {
+        this.message = message;
+    }
+}

Propchange: geronimo/trunk/sandbox/console-standard/src/java/org/apache/geronimo/console/databasemanager/DataSourceInfo.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message