geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From manugeo...@apache.org
Subject svn commit: r708815 [1/2] - in /geronimo/server/trunk: plugingroups/javaee5-jetty/ plugingroups/javaee5-jetty/src/main/history/ plugingroups/javaee5-tomcat/ plugingroups/javaee5-tomcat/src/main/history/ plugins/console/console-portal-driver/src/main/we...
Date Wed, 29 Oct 2008 08:02:00 GMT
Author: manugeorge
Date: Wed Oct 29 01:01:59 2008
New Revision: 708815

URL: http://svn.apache.org/viewvc?rev=708815&view=rev
Log:
Merging patch for GERONIMO-3811 EjbServer Portlet.

Added:
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/pom.xml
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/dependencies.xml
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/
    geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/plan.xml
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/pom.xml
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/dependencies.xml
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/
    geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/plan.xml
    geronimo/server/trunk/plugins/openejb/openejb-portlets/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/pom.xml
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EJBServerPortlet.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbHelper.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbInformation.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Status.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Tree.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/TreeEntry.java
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/resources/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/resources/openejb-portlet.properties
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/portlet.xml
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/view/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/view/ejbserver/
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/view/ejbserver/help.jsp
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/view/ejbserver/view.jsp
    geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/webapp/WEB-INF/web.xml
Modified:
    geronimo/server/trunk/plugingroups/javaee5-jetty/pom.xml
    geronimo/server/trunk/plugingroups/javaee5-jetty/src/main/history/dependencies.xml
    geronimo/server/trunk/plugingroups/javaee5-tomcat/pom.xml
    geronimo/server/trunk/plugingroups/javaee5-tomcat/src/main/history/dependencies.xml
    geronimo/server/trunk/plugins/console/console-portal-driver/src/main/webapp/WEB-INF/web.xml
    geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/BmpContainerGBean.java
    geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystem.java
    geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
    geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatefulContainerGBean.java
    geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatelessContainerGBean.java
    geronimo/server/trunk/plugins/openejb/openejb/pom.xml
    geronimo/server/trunk/plugins/openejb/pom.xml

Modified: geronimo/server/trunk/plugingroups/javaee5-jetty/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugingroups/javaee5-jetty/pom.xml?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugingroups/javaee5-jetty/pom.xml (original)
+++ geronimo/server/trunk/plugingroups/javaee5-jetty/pom.xml Wed Oct 29 01:01:59 2008
@@ -209,6 +209,13 @@
             <version>${version}</version>
             <type>car</type>
         </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>openejb-console-jetty</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
         <!-- end admin console related plugins -->
     </dependencies>
 

Modified: geronimo/server/trunk/plugingroups/javaee5-jetty/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugingroups/javaee5-jetty/src/main/history/dependencies.xml?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugingroups/javaee5-jetty/src/main/history/dependencies.xml (original)
+++ geronimo/server/trunk/plugingroups/javaee5-jetty/src/main/history/dependencies.xml Wed Oct 29 01:01:59 2008
@@ -121,4 +121,9 @@
         <artifactId>agent</artifactId>
         <type>car</type>
     </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb-console-jetty</artifactId>
+        <type>car</type>
+    </dependency>
 </plugin-artifact>

Modified: geronimo/server/trunk/plugingroups/javaee5-tomcat/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugingroups/javaee5-tomcat/pom.xml?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugingroups/javaee5-tomcat/pom.xml (original)
+++ geronimo/server/trunk/plugingroups/javaee5-tomcat/pom.xml Wed Oct 29 01:01:59 2008
@@ -201,6 +201,13 @@
             <version>${version}</version>
             <type>car</type>
         </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>openejb-console-tomcat</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
         <!-- end admin console related plugins -->
     </dependencies>
 

Modified: geronimo/server/trunk/plugingroups/javaee5-tomcat/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugingroups/javaee5-tomcat/src/main/history/dependencies.xml?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugingroups/javaee5-tomcat/src/main/history/dependencies.xml (original)
+++ geronimo/server/trunk/plugingroups/javaee5-tomcat/src/main/history/dependencies.xml Wed Oct 29 01:01:59 2008
@@ -121,4 +121,9 @@
         <artifactId>agent</artifactId>
         <type>car</type>
     </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb-console-tomcat</artifactId>
+        <type>car</type>
+    </dependency>
 </plugin-artifact>

Modified: geronimo/server/trunk/plugins/console/console-portal-driver/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/console/console-portal-driver/src/main/webapp/WEB-INF/web.xml?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/console/console-portal-driver/src/main/webapp/WEB-INF/web.xml (original)
+++ geronimo/server/trunk/plugins/console/console-portal-driver/src/main/webapp/WEB-INF/web.xml Wed Oct 29 01:01:59 2008
@@ -128,6 +128,21 @@
     </init-param>
   </servlet>
 
+  <!-- DWR for the EJBServer Portlet -->
+  <servlet>
+    <display-name>DWR Forward Servlet 6</display-name>
+    <servlet-name>dwr-forward6</servlet-name>
+    <servlet-class>org.apache.geronimo.console.servlet.ContextForwardServlet</servlet-class>
+    <init-param>
+       <param-name>servlet-path</param-name>
+       <param-value>/dwr6</param-value>
+    </init-param>
+    <init-param>
+       <param-name>context-path</param-name>
+       <param-value>/openejb-server</param-value>
+    </init-param>
+  </servlet>
+
   <servlet>
     <display-name>Generic Context Forward Servlet</display-name>
     <servlet-name>context-forward</servlet-name>
@@ -176,6 +191,11 @@
   </servlet-mapping>
 
   <servlet-mapping>
+    <servlet-name>dwr-forward6</servlet-name>
+    <url-pattern>/dwr6/*</url-pattern>
+  </servlet-mapping>
+
+  <servlet-mapping>
     <servlet-name>plutoPortalDriver</servlet-name>
     <url-pattern>/portal/*</url-pattern>
   </servlet-mapping>
@@ -238,6 +258,7 @@
       <url-pattern>/dwr3/*</url-pattern>
       <url-pattern>/dwr4/*</url-pattern>
       <url-pattern>/dwr5/*</url-pattern>
+      <url-pattern>/dwr6/*</url-pattern>
       <http-method>GET</http-method>
       <http-method>POST</http-method>
       <http-method>PUT</http-method>

Modified: geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/BmpContainerGBean.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/BmpContainerGBean.java?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/BmpContainerGBean.java (original)
+++ geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/BmpContainerGBean.java Wed Oct 29 01:01:59 2008
@@ -38,11 +38,11 @@
             @ParamSpecial(type = SpecialAttributeType.abstractName) AbstractName abstractName,
             @ParamReference(name = "OpenEjbSystem") OpenEjbSystem openEjbSystem,
             @ParamAttribute(name = "provider") String provider,
-            @ParamAttribute(name = "accessTimeout") int accessTimeout,
+            @ParamAttribute(name = "poolSize") int poolSize,
             @ParamAttribute(name = "properties") Properties properties) {
         super(abstractName, BmpEntityContainerInfo.class, openEjbSystem, provider, "BMP_ENTITY", properties);
-        set("AccessTimeout", Integer.toString(accessTimeout));
-        this.poolSize = accessTimeout;
+        set("PoolSize", Integer.toString(poolSize));
+        this.poolSize = poolSize;
     }
 
     public int getPoolSize() {

Modified: geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystem.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystem.java?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystem.java (original)
+++ geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystem.java Wed Oct 29 01:01:59 2008
@@ -62,4 +62,8 @@
     AppInfo configureApplication(AppModule appModule) throws OpenEJBException;
 
     void setORBContext(ORB orb, HandleDelegate handleDelegate);
+    
+    void setProperties(Properties properties);
+    
+    Properties getProperties();
 }

Modified: geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java (original)
+++ geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/OpenEjbSystemGBean.java Wed Oct 29 01:01:59 2008
@@ -88,14 +88,16 @@
     // These are provided by the corba subsystem when it first initializes.  
     // Once we have a set, we ignore any additional notifications. 
     private ORB orb;
-
+    private Properties properties; 
+    
     public OpenEjbSystemGBean(TransactionManager transactionManager) throws Exception {
-        this(transactionManager, null, null, null, OpenEjbSystemGBean.class.getClassLoader());
+        this(transactionManager, null, null, null, OpenEjbSystemGBean.class.getClassLoader(), new Properties());
     }
-    public OpenEjbSystemGBean(TransactionManager transactionManager, Collection<ResourceAdapterWrapper> resourceAdapters, Collection<PersistenceUnitGBean> persistenceUnitGBeans, Kernel kernel, ClassLoader classLoader) throws Exception {
+    public OpenEjbSystemGBean(TransactionManager transactionManager, Collection<ResourceAdapterWrapper> resourceAdapters, Collection<PersistenceUnitGBean> persistenceUnitGBeans, Kernel kernel, ClassLoader classLoader, Properties properties) throws Exception {
         this.kernel = kernel;
         this.classLoader = classLoader;
-
+        this.properties = properties;
+        
         System.setProperty("duct tape","");
         System.setProperty("admin.disabled", "true");
         System.setProperty("openejb.logger.external", "true");
@@ -161,6 +163,14 @@
         }
     }
 
+    public Properties getProperties() {
+        return properties;
+    }
+    
+    public void setProperties(Properties properties) {
+        this.properties = properties;
+    }
+    
     @SuppressWarnings({"unchecked"})
     private static <T> T getRawService(Kernel kernel, T proxy) {
         if (kernel == null) return proxy;
@@ -279,6 +289,11 @@
                         ContainerInfo containerInfo = configurationFactory.configureService(MdbContainerInfo.class, containerName, null, null, "Container");
                         containerInfo.id = containerName;
                         containerInfo.displayName = containerName;
+                        properties = (properties == null)?new Properties():properties;                        
+                        String instanceLimit = (String)properties.get(containerName + "." + "InstanceLimit");                                                
+                        if(instanceLimit != null){
+                            containerInfo.properties.put("InstanceLimit", instanceLimit);
+                        }
 
                         // set ra specific properties
                         containerInfo.properties.put("MessageListenerInterface",
@@ -286,7 +301,7 @@
                         containerInfo.properties.put("ActivationSpecClass",
                                 resourceAdapter.getClass().getClassLoader().loadClass(activationSpecClass));
                         containerInfo.properties.put("ResourceAdapter", resourceAdapter);
-                        containerInfo.properties.put("TxRecovery", true);
+                       // containerInfo.properties.put("TxRecovery", true);
  
                         // create the container
                         assembler.createContainer(containerInfo);
@@ -423,12 +438,14 @@
         infoBuilder.addReference("PersistenceUnitGBeans", PersistenceUnitGBean.class);
         infoBuilder.addAttribute("kernel", Kernel.class, false);
         infoBuilder.addAttribute("classLoader", ClassLoader.class, false);
+        infoBuilder.addAttribute("properties", Properties.class, true, true);
         infoBuilder.setConstructor(new String[] {
                 "TransactionManager",
                 "ResourceAdapterWrappers",
                 "PersistenceUnitGBeans",
                 "kernel",
                 "classLoader",
+                "properties"
         });
         GBEAN_INFO = infoBuilder.getBeanInfo();
     }

Modified: geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatefulContainerGBean.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatefulContainerGBean.java?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatefulContainerGBean.java (original)
+++ geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatefulContainerGBean.java Wed Oct 29 01:01:59 2008
@@ -59,9 +59,9 @@
             @ParamAttribute(name = "timeout") long timeout,
             @ParamAttribute(name = "properties") Properties properties) {
         super(abstractName, StatefulSessionContainerInfo.class, openEjbSystem, provider, "STATEFUL", properties);
-        set("bulkPassivate", Integer.toString(bulkPassivate));
-        set("capacity", Integer.toString(capacity));
-        set("timeout", Long.toString(timeout));
+        set("BulkPassivate", Integer.toString(bulkPassivate));
+        set("Capacity", Integer.toString(capacity));
+        set("TimeOut", Long.toString(timeout));
         this.bulkPassivate = bulkPassivate;
         this.capacity = capacity;
         this.timeout = timeout;

Modified: geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatelessContainerGBean.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatelessContainerGBean.java?rev=708815&r1=708814&r2=708815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatelessContainerGBean.java (original)
+++ geronimo/server/trunk/plugins/openejb/geronimo-openejb/src/main/java/org/apache/geronimo/openejb/StatelessContainerGBean.java Wed Oct 29 01:01:59 2008
@@ -72,9 +72,9 @@
             @ParamAttribute(name = "timeout") int timeout,
             @ParamAttribute(name = "properties") Properties properties) {
         super(abstractName, StatelessSessionContainerInfo.class, openEjbSystem, provider, "STATELESS", properties);
-        set("poolSize", Integer.toString(poolSize));
-        set("strictPooling", Boolean.toString(strictPooling));
-        set("timeout", Integer.toString(timeout));
+        set("PoolSize", Integer.toString(poolSize));
+        set("StrictPooling", Boolean.toString(strictPooling));
+        set("TimeOut", Integer.toString(timeout));
         this.poolSize = poolSize;
         this.strictPooling = strictPooling;
         this.timeout = timeout;

Added: geronimo/server/trunk/plugins/openejb/openejb-console-jetty/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-jetty/pom.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-jetty/pom.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-jetty/pom.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,126 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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.
+-->
+
+<!-- $Rev: 617770 $ $Date: 2008-02-02 14:00:00 +0530 (Sat, 02 Feb 2008) $ -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb</artifactId>
+        <version>2.2-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>openejb-console-jetty</artifactId>
+    <name>Geronimo Plugins, OpenEJB :: Jetty</name>
+    <packaging>car</packaging>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>${jetty}-deployer</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>jasper-deployer</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>openejb-portlets</artifactId>
+            <version>${version}</version>
+            <type>war</type>
+            <scope>provided</scope>
+        </dependency>
+
+	<dependency>
+           <groupId>org.apache.geronimo.configs</groupId>
+           <artifactId>openejb</artifactId>
+           <version>${version}</version>
+           <type>car</type>
+        </dependency>
+	
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>console-jetty</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>dojo-jetty6</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.framework</groupId>
+            <artifactId>plugin</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+    </dependencies> 
+
+    <build>
+        <resources>
+            <resource>
+                <directory>${pom.basedir}/src/main/resources</directory>
+                <filtering>true</filtering>
+            </resource>
+        </resources>
+
+        <plugins>
+            <plugin>
+                <groupId>org.apache.geronimo.buildsupport</groupId>
+                <artifactId>car-maven-plugin</artifactId>
+                <configuration>
+                    <deploymentConfigs>
+                        <deploymentConfig>${gbeanDeployer}</deploymentConfig>
+                        <deploymentConfig>${j2eeDeployer}</deploymentConfig>
+                        <deploymentConfig>${jettyDeployer}</deploymentConfig>
+                        <deploymentConfig>${jasperDeployer}</deploymentConfig>
+                    </deploymentConfigs>
+                    <module>
+                        <groupId>org.apache.geronimo.plugins</groupId>
+                        <artifactId>openejb-portlets</artifactId>
+                        <version>${version}</version>
+                        <type>war</type>
+                    </module>
+                    <category>Administration</category>
+                    <osiApproved>true</osiApproved>
+                    <useMavenDependencies>
+                        <value>true</value>
+                        <includeVersion>true</includeVersion>
+                    </useMavenDependencies>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>

Added: geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/dependencies.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/dependencies.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/history/dependencies.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<plugin-artifact xmlns:ns2="http://geronimo.apache.org/xml/ns/attributes-1.2" xmlns="http://geronimo.apache.org/xml/ns/plugins-1.3">
+    <module-id>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb-console-jetty</artifactId>
+        <version>2.2-SNAPSHOT</version>
+        <type>car</type>
+    </module-id>
+    <dependency>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>console-jetty</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>openejb</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.framework</groupId>
+        <artifactId>plugin</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>dojo-jetty6</artifactId>
+        <type>car</type>
+    </dependency>
+</plugin-artifact>

Added: geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/plan.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/plan.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/plan.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-jetty/src/main/plan/plan.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,44 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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.
+-->
+<web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web/jetty-1.2">
+    
+    <!-- This is where the files are accessed from. (aka - portletContext) -->
+    <context-root>/openejb-server</context-root>
+
+
+    <security-realm-name>geronimo-admin</security-realm-name>
+    <security xmlns="http://geronimo.apache.org/xml/ns/security-1.2">
+        <role-mappings>
+            <role role-name="admin">
+                <principal class="org.apache.geronimo.security.realm.providers.GeronimoGroupPrincipal" name="admin" />
+            </role>
+        </role-mappings>
+    </security>
+    
+    <!-- Start off a ACEGBean, this is the lifecycle for the portlet -->
+    <gbean name="EJBServerACEGBean" class="org.apache.geronimo.pluto.AdminConsoleExtensionGBean">
+        <attribute name="pageTitle">Server/EJB Server</attribute>
+        <attribute name="portletContext">/openejb-server</attribute>
+        <attribute name="portletList">[EJBServerPortlet]</attribute>
+        <attribute name="icon">/images/ico_beanjar_16x16.gif</attribute>
+	<reference name="PortalContainerServices">
+            <name>PlutoPortalServices</name>
+        </reference>
+    </gbean>
+</web-app>

Added: geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/pom.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/pom.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/pom.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,129 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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.
+-->
+
+<!-- $Rev: 617770 $ $Date: 2008-02-02 14:00:00 +0530 (Sat, 02 Feb 2008) $ -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb</artifactId>
+        <version>2.2-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>openejb-console-tomcat</artifactId>
+    <name>Geronimo Plugins, OpenEJB :: Tomcat</name>
+    <packaging>car</packaging>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>tomcat6-deployer</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>jasper-deployer</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>openejb-portlets</artifactId>
+            <version>${version}</version>
+            <type>war</type>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>console-tomcat</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+	<dependency>
+           <groupId>org.apache.geronimo.configs</groupId>
+           <artifactId>openejb</artifactId>
+           <version>${version}</version>
+           <type>car</type>
+        </dependency>
+	
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>dojo-tomcat</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.framework</groupId>
+            <artifactId>plugin</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+        </dependency>
+
+    </dependencies>
+
+    <build>
+        <resources>
+            <resource>
+                <directory>${pom.basedir}/src/main/resources</directory>
+                <filtering>true</filtering>
+            </resource>
+        </resources>
+
+        <plugins>
+            <plugin>
+                <groupId>org.apache.geronimo.buildsupport</groupId>
+                <artifactId>car-maven-plugin</artifactId>
+                <configuration>
+                    <deploymentConfigs>
+                        <deploymentConfig>${gbeanDeployer}</deploymentConfig>
+                        <deploymentConfig>${j2eeDeployer}</deploymentConfig>
+                        <deploymentConfig>${tomcatDeployer}</deploymentConfig>
+                        <deploymentConfig>${jasperDeployer}</deploymentConfig>
+                    </deploymentConfigs>
+                    <module>
+                        <groupId>org.apache.geronimo.plugins</groupId>
+                        <artifactId>openejb-portlets</artifactId>
+                        <version>${version}</version>
+                        <type>war</type>
+                    </module>
+                    <category>Administration</category>
+                    <description>
+                       OpenEJB Server plugin for Tomcat
+                    </description>
+                    <osiApproved>true</osiApproved>
+                    <useMavenDependencies>
+                        <value>true</value>
+                        <includeVersion>true</includeVersion>
+                    </useMavenDependencies>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>

Added: geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/dependencies.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/dependencies.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/history/dependencies.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<plugin-artifact xmlns:ns2="http://geronimo.apache.org/xml/ns/attributes-1.2" xmlns="http://geronimo.apache.org/xml/ns/plugins-1.3">
+    <module-id>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb-console-tomcat</artifactId>
+        <version>2.2-SNAPSHOT</version>
+        <type>car</type>
+    </module-id>
+    <dependency>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>console-tomcat</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>dojo-tomcat</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>openejb</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.framework</groupId>
+        <artifactId>plugin</artifactId>
+        <type>car</type>
+    </dependency>
+</plugin-artifact>

Added: geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/plan.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/plan.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/plan.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-console-tomcat/src/main/plan/plan.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,46 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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.
+-->
+<web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web/tomcat-1.2">
+    
+    <!-- This is where the files are accessed from. (aka - portletContext) -->
+    <context-root>/openejb-server</context-root>
+
+    <!-- required for pluto cross context dispatches -->
+    <cross-context />
+
+    <security-realm-name>geronimo-admin</security-realm-name>
+    <security xmlns="http://geronimo.apache.org/xml/ns/security-1.2">
+        <role-mappings>
+            <role role-name="admin">
+                <principal class="org.apache.geronimo.security.realm.providers.GeronimoGroupPrincipal" name="admin" />
+            </role>
+        </role-mappings>
+    </security>
+    
+    <!-- Start off a ACEGBean, this is the lifecycle for the portlet -->
+    <gbean name="EJBServerACEGBean" class="org.apache.geronimo.pluto.AdminConsoleExtensionGBean">
+        <attribute name="pageTitle">Server/EJB Server</attribute>
+        <attribute name="portletContext">/openejb-server</attribute>
+        <attribute name="portletList">[EJBServerPortlet]</attribute>
+        <attribute name="icon">/images/ico_beanjar_16x16.gif</attribute>
+	<reference name="PortalContainerServices">
+            <name>PlutoPortalServices</name>
+        </reference>
+    </gbean>
+</web-app>

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/pom.xml?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/pom.xml (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/pom.xml Wed Oct 29 01:01:59 2008
@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+-->
+
+<!-- $Rev: 617770 $ $Date: 2008-02-02 14:00:00 +0530 (Sat, 02 Feb 2008) $ -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>openejb</artifactId>
+        <version>2.2-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>openejb-portlets</artifactId>
+    <name>Geronimo Plugins, OpenEJB :: Portlets</name>
+    <packaging>war</packaging>
+
+    <dependencies>
+        <!-- for jspc maven plugin -->
+        <dependency>
+            <groupId>org.apache.geronimo.framework</groupId>
+            <artifactId>jee-specs</artifactId>
+            <version>${version}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>openejb</artifactId>
+            <version>2.2-SNAPSHOT</version>
+            <type>car</type>
+        </dependency>
+            
+        <!-- for jspc maven plugin -->
+        <dependency>
+            <groupId>org.apache.pluto</groupId>
+            <artifactId>pluto-taglib</artifactId>
+            <version>${plutoVersion}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.framework</groupId>
+            <artifactId>geronimo-management</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.modules</groupId>
+            <artifactId>geronimo-j2ee-builder</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.modules</groupId>
+            <artifactId>geronimo-naming-builder</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.modules</groupId>
+            <artifactId>geronimo-security-builder</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.modules</groupId>
+            <artifactId>geronimo-connector-builder</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.modules</groupId>
+            <artifactId>geronimo-web-2.5-builder</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.framework</groupId>
+            <artifactId>geronimo-deploy-jsr88</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.plugins</groupId>
+            <artifactId>console-core</artifactId>
+            <version>${version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>javax.portlet</groupId>
+            <artifactId>portlet-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>commons-fileupload</groupId>
+            <artifactId>commons-fileupload</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.xmlbeans</groupId>
+            <artifactId>xmlbeans</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.directwebremoting</groupId>
+            <artifactId>dwr</artifactId>
+            <scope>provided</scope>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <resources>
+            <resource>
+                <directory>src/main/resources</directory>
+                <filtering>true</filtering>
+            </resource>
+        </resources>
+        <plugins>
+            <plugin>
+                <groupId>org.codehaus.mojo.jspc</groupId>
+                <artifactId>jspc-maven-plugin</artifactId>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-war-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EJBServerPortlet.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EJBServerPortlet.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EJBServerPortlet.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EJBServerPortlet.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,110 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.StringTokenizer;
+
+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.BasePortlet;
+import org.apache.geronimo.console.util.PortletManager;
+import org.apache.geronimo.kernel.GBeanNotFoundException;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.KernelRegistry;
+import org.apache.geronimo.openejb.EjbDeployment;
+import org.apache.openejb.assembler.classic.ContainerInfo;
+import org.apache.openejb.assembler.classic.ServiceInfo;
+import org.apache.openejb.assembler.classic.ContainerSystemInfo;
+import org.apache.openejb.assembler.classic.OpenEjbConfiguration;
+import org.apache.openejb.Container;
+import org.apache.openejb.DeploymentInfo;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.spi.ContainerSystem;
+
+public class EJBServerPortlet extends BasePortlet {
+	
+
+	    private static final String VIEW_JSP = "/WEB-INF/view/ejbserver/view.jsp";
+
+	    private static final String HELPVIEW_JSP = "/WEB-INF/view/ejbserver/help.jsp";
+	    
+	    private PortletRequestDispatcher normalView;
+
+	    private PortletRequestDispatcher helpView;
+	    
+	    private List treeList;
+
+	    public void processAction(ActionRequest actionRequest,
+	            ActionResponse actionResponse) throws PortletException, IOException {
+	    }
+
+	    protected void doView(RenderRequest renderRequest,
+	            RenderResponse renderResponse) throws IOException, PortletException {
+	    	
+	    	if (WindowState.MAXIMIZED.equals(renderRequest.getWindowState())) {
+	    		normalView.include(renderRequest, renderResponse);
+	        } else if (WindowState.MINIMIZED.equals(renderRequest.getWindowState())) {
+	            return;
+	        } else if (WindowState.NORMAL.equals(renderRequest.getWindowState())) {
+	            normalView.include(renderRequest, renderResponse);
+	        } else {
+	            return;
+	        }
+	    }
+
+	    private List split(String path, String sep) {
+	        StringTokenizer st = new StringTokenizer(path, sep);
+
+	        List l = new ArrayList();
+
+	        while (st.hasMoreTokens()) {
+	            l.add(st.nextToken());
+	        }
+	        return l;
+	    }
+
+	    protected void doHelp(RenderRequest renderRequest,
+	            RenderResponse renderResponse) throws PortletException, IOException {
+	        helpView.include(renderRequest, renderResponse);
+	    }
+
+	    public void init(PortletConfig portletConfig) throws PortletException {
+	        super.init(portletConfig);
+	        normalView = portletConfig.getPortletContext().getRequestDispatcher(
+	                VIEW_JSP);
+	        helpView = portletConfig.getPortletContext().getRequestDispatcher(
+	                HELPVIEW_JSP);
+	    }
+
+	    public void destroy() {
+	        normalView = null;	        
+	        helpView = null;
+	        super.destroy();
+	    }
+
+}

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbHelper.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbHelper.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbHelper.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbHelper.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,530 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import java.lang.reflect.Method;
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.ResourceBundle;
+import java.util.Set;
+import java.util.TreeMap;
+
+import org.apache.geronimo.console.util.KernelManagementHelper;
+import org.apache.geronimo.gbean.AbstractName;
+import org.apache.geronimo.gbean.AbstractNameQuery;
+import org.apache.geronimo.gbean.GAttributeInfo;
+import org.apache.geronimo.gbean.GBeanData;
+import org.apache.geronimo.kernel.GBeanNotFoundException;
+import org.apache.geronimo.kernel.InternalKernelException;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.kernel.KernelRegistry;
+import org.apache.geronimo.kernel.NoSuchAttributeException;
+import org.apache.geronimo.kernel.config.Configuration;
+import org.apache.geronimo.kernel.config.ConfigurationUtil;
+import org.apache.geronimo.kernel.config.ManageableAttributeStore;
+import org.apache.geronimo.openejb.EjbContainer;
+import org.apache.geronimo.openejb.OpenEjbSystem;
+import org.apache.openejb.Container;
+import org.apache.openejb.ContainerType;
+import org.apache.openejb.DeploymentInfo;
+import org.apache.openejb.assembler.classic.ContainerInfo;
+import org.apache.openejb.assembler.classic.ContainerSystemInfo;
+import org.apache.openejb.assembler.classic.OpenEjbConfiguration;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.spi.ContainerSystem;
+import org.apache.openejb.util.Duration;
+import org.directwebremoting.annotations.RemoteMethod;
+import org.directwebremoting.annotations.RemoteProxy;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+@RemoteProxy
+public class EjbHelper {
+
+    private static final Logger log = LoggerFactory.getLogger(EjbHelper.class);
+    
+    private static final String POOLSIZE = "PoolSize";
+    private static final String BULKPASSIVATE = "BulkPassivate";
+    private static final String CAPACITY = "Capacity";
+    private static final String TIMEOUT = "TimeOut";
+    private static final String ACCESSTIMEOUT = "AccessTimeout";
+    private static final String PASSIVATOR = "Passivator";
+    private static final String STRICTPOOLING = "StrictPooling";
+    private static final String INSTANCELIMIT = "InstanceLimit";
+    private static final String CMPENGINEFACTORY = "CmpEngineFactory";
+    private static final String TXRECOVERY = "TxRecovery";
+    private static final String RESOURCEADAPTER  = "ResourceAdapter";
+    private static final String MESSAGELISTENERINTERFACE = "MessageListenerInterface";
+    private static final String ACTIVATIONSPECCLASS = "ActivationSpecClass";
+    private static final String TRUE = "true";
+    private static final String FALSE = "false";
+    private static final String BUNDLE_NAME = "openejb-portlet";
+    private static final String BEANCLASSNAME_KEY="portlet.openejb.view.beanclassname";
+    private static final String BLI_KEY="portlet.openejb.view.businesslocalinterfaces";
+    private static final String BRI_KEY="portlet.openejb.view.businessremoteinterfaces";
+    private static final String DEPLOYMENTID_KEY="portlet.openejb.view.deploymentid";
+    private static final String EJBNAME_KEY="portlet.openejb.view.ejbname";
+    private static final String EJBHOMEI_KEY="portlet.openejb.view.ejbhomeinterface";
+    private static final String JNDINAMES_KEY="portlet.openejb.view.jndinames";
+    private static final String LHI_KEY="portlet.openejb.view.localhomeinterface";
+    private static final String LI_KEY="portlet.openejb.view.localinterface";
+    private static final String RI_KEY="portlet.openejb.view.remoteinterface";
+    private static final String PKC_KEY="portlet.openejb.view.primarykeyclass";
+    private static final String PKF_KEY="portlet.openejb.view.primarykeyfield";
+    private static final String SEI_KEY="portlet.openejb.view.sepinterface";
+    private static final String CC_KEY="portlet.openejb.view.containerclass";
+    private static final String CI_KEY="portlet.openejb.view.containerid";
+    private static final String CD_KEY="portlet.openejb.view.containerdescription";
+    private static final String DN_KEY="portlet.openejb.view.displayname";
+    
+    
+    private ContainerSystem containerSystem;
+    private OpenEjbConfiguration configuration;
+    private Kernel kernel;    
+    private ResourceBundle resourceBundle;
+    private KernelManagementHelper helper = null;
+    public EjbHelper() {
+        initContainerSystem();
+    }
+
+    private void initContainerSystem() {
+        kernel = KernelRegistry.getSingleKernel();
+        helper = new KernelManagementHelper(kernel);
+        containerSystem = SystemInstance.get().getComponent(
+                ContainerSystem.class);
+        configuration = SystemInstance.get().getComponent(
+                OpenEjbConfiguration.class);
+        resourceBundle = ResourceBundle.getBundle(BUNDLE_NAME);
+    }
+
+    @RemoteMethod
+    public Tree getEjbInformation() {
+
+        ClassLoader oldcl = Thread.currentThread().getContextClassLoader();
+        ClassLoader newcl = null;
+        Container container = null;
+        ContainerSystemInfo systemInfo = configuration.containerSystem;
+        Map<ContainerType, TreeEntry> containerMap = new TreeMap<ContainerType, TreeEntry>();
+        List<ContainerInfo> containerInfos = systemInfo.containers;
+        ContainerInfo containerInfo = null;
+        TreeEntry containerTypesEntry, containersEntry, deploymentsEntry = null;
+        Tree tree = new Tree("name", "name");
+        List<TreeEntry> entries = new ArrayList<TreeEntry>();
+        for (int i = 0; i < containerInfos.size(); i++) {
+
+            containerInfo = containerInfos.get(i);
+            container = containerSystem.getContainer(containerInfo.id);
+            List<TreeEntry> containers = null;
+            if (containerMap.get(container.getContainerType()) != null) {
+                containerTypesEntry = containerMap.get(container
+                        .getContainerType());
+                containers = containerTypesEntry.getChildren();
+            } else {
+                containerTypesEntry = new TreeEntry();
+                containerTypesEntry.setName(resolveContainerTypes(container
+                        .getContainerType()));
+                containerTypesEntry.setValue(containerTypesEntry.getName());
+                containers = new ArrayList<TreeEntry>();
+                containerTypesEntry.setChildren(containers);
+                containerMap.put(container.getContainerType(),
+                        containerTypesEntry);
+                entries.add(containerTypesEntry);
+            }
+            containersEntry = new TreeEntry();
+            containersEntry.setName(containerInfo.id);
+            containersEntry.setValue(containerInfo.id);
+
+            DeploymentInfo[] deployments = container.deployments();
+            containersEntry.setChildren(getDeployments(deployments));
+            containers.add(containersEntry);
+        }
+        tree.setItems(entries);
+        return tree;
+    }
+
+    public List getDeployments(DeploymentInfo[] deploymentInfos) {
+        List<TreeEntry> deployments = new ArrayList<TreeEntry>();
+        TreeEntry deploymentsEntry = null;
+        for (DeploymentInfo deployment : deploymentInfos) {
+            deploymentsEntry = new TreeEntry();
+            deploymentsEntry.setName(deployment.getEjbName());
+            deploymentsEntry.setValue(deployment.getContainer()
+                    .getContainerID()
+                    + "#^~" + deployment.getDeploymentID());
+            deploymentsEntry.setChildren(new ArrayList<TreeEntry>());
+            deployments.add(deploymentsEntry);
+        }
+        return deployments;
+    }
+
+    @RemoteMethod
+    public List<EjbInformation> getContainerInfo(String containerId) {
+        Container container = containerSystem.getContainer(containerId);
+        if (container == null)
+            return null;
+        ContainerSystemInfo systemInfo = configuration.containerSystem;
+        List<ContainerInfo> containerInfos = systemInfo.containers;
+        List<EjbInformation> infos = new ArrayList<EjbInformation>();
+        EjbInformation information = null;
+        GBeanData data = null;
+        if (container.getContainerType() == ContainerType.MESSAGE_DRIVEN) {
+            data = getOpenEJBPropertiesGBean(containerId, OpenEjbSystem.class);
+        } else {
+            data = getOpenEJBPropertiesGBean(containerId, EjbContainer.class);
+        }
+        Properties props = null;
+        if (data != null) {
+            props = (Properties) data.getAttribute("properties");
+        }
+        for (ContainerInfo containerInfo : containerInfos) {
+            if (containerInfo.id.equals(containerId)) {
+                information = new EjbInformation();
+                information.setName(resourceBundle.getString(CC_KEY));
+                information.setId("ContainerClass");
+                information.setValue(containerInfo.className);
+                infos.add(information);
+                information = new EjbInformation();
+                information.setName(resourceBundle.getString(CI_KEY));
+                information.setId("ContainerId");
+                information.setValue(containerInfo.id);
+                infos.add(information);
+                information = new EjbInformation();
+                information.setName(resourceBundle.getString(CD_KEY));
+                information.setId("ContainerDesc");
+                information.setValue(containerInfo.description);
+                infos.add(information);
+                information = new EjbInformation();
+                information.setName(resourceBundle.getString(DN_KEY));
+                information.setId("DisplayName");
+                information.setValue(containerInfo.displayName);
+                infos.add(information);
+                List<String> editableProperties = new ArrayList<String>();
+                editableProperties.add(POOLSIZE);
+                editableProperties.add(BULKPASSIVATE);
+                editableProperties.add(TIMEOUT);
+                editableProperties.add(ACCESSTIMEOUT);
+                editableProperties.add(CAPACITY);
+                editableProperties.add(STRICTPOOLING);
+                editableProperties.add(INSTANCELIMIT);                
+
+                for (Map.Entry entry : containerInfo.properties.entrySet()) {
+                    information = new EjbInformation();
+                    information.setName(entry.getKey().toString());
+                    information.setId(entry.getKey().toString());
+                    if (entry.getKey().toString().equals(RESOURCEADAPTER)) {
+                        information.setValue(entry.getValue().getClass()
+                                .getName());
+                    } else {
+                        information.setValue(entry.getValue().toString());
+                    }
+                    if (editableProperties.contains(entry.getKey().toString())) {
+                        String key = information.getName();
+                        String value = null;
+                        if (props != null && props.containsKey(key)) {
+                            value = (String) props.get(key);
+                        } else if (props != null
+                                && props.containsKey(containerId + "." + key)) {
+                            value = (String) props.get(containerId + "." + key);
+                        } else {
+                            value = information.getValue();
+                        }
+                        if (!value.equals(information.getValue())) {
+                            information.setDirty(TRUE);
+                        }
+                        information.setValue(value);
+                        information.setEditable(TRUE);
+                    } else {
+                        information.setEditable(FALSE);
+                    }
+                    infos.add(information);
+                }
+
+            }
+        }
+        return infos;
+    }
+
+    @RemoteMethod
+    public Status setContainerProperty(String containerId, String propertyKey,
+            String propertyValue) {
+        propertyKey = propertyKey.trim();
+        propertyValue = propertyValue.trim();
+        if (containerId.indexOf("%20") != -1) {
+            containerId = containerId.replaceAll("%20", "\\ ");
+        }
+        List<String> numericProperties = new ArrayList<String>();
+        numericProperties.add(POOLSIZE);
+        numericProperties.add(BULKPASSIVATE);
+        numericProperties.add(TIMEOUT);
+        numericProperties.add(INSTANCELIMIT); 
+        numericProperties.add(CAPACITY);
+        numericProperties.add(ACCESSTIMEOUT);
+        
+        if (numericProperties.contains(propertyKey)) {
+            try {
+                Integer.parseInt(propertyValue);
+            } catch (NumberFormatException nfe) {
+                return new Status(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.message1"),propertyKey));
+            }
+        } else if (STRICTPOOLING.equals(propertyKey)) {
+            if (!propertyValue.equalsIgnoreCase(TRUE)
+                    && !propertyValue.equalsIgnoreCase(FALSE)) {
+                return new Status(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.message2"),propertyKey));
+            }        
+        } else {
+            try {
+                EjbHelper.class.getClassLoader().loadClass(propertyValue);
+            } catch (ClassNotFoundException e) {
+                return new Status(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.message3"),propertyKey));
+            }
+        }
+
+        Properties props = null;
+        Container container = containerSystem.getContainer(containerId);
+        if (container.getContainerType() == ContainerType.MESSAGE_DRIVEN) {
+            OpenEjbSystem openEjbSystem = null;
+            AbstractNameQuery absQuery = new AbstractNameQuery(
+                    OpenEjbSystem.class.getName());
+            Set systemGBeans = kernel.listGBeans(absQuery);
+            for (Object obj : systemGBeans) {
+            	AbstractName absName = (AbstractName) obj;
+                openEjbSystem = kernel.getProxyManager()
+                        .createProxy(absName, OpenEjbSystem.class);
+                props = openEjbSystem.getProperties();
+                if (props == null) {
+                    props = new Properties();
+                }
+                props.put(containerId + "." + propertyKey, propertyValue);
+                openEjbSystem.setProperties(props);
+                getGBeanDataFromConfiguration(absName).setAttribute("properties", props);
+
+            }
+        } else {
+            AbstractNameQuery absQuery = new AbstractNameQuery(
+                    EjbContainer.class.getName());
+            Set containerGBeans = kernel.listGBeans(absQuery);
+            for (Object obj : containerGBeans) {
+                try {
+                    String id = (String) kernel.getAttribute(
+                            (AbstractName) obj, "id");
+                    if (containerId.equals(id)) {
+                        AbstractName absName = (AbstractName) obj;
+                        GBeanData gData1  = kernel.getGBeanData(absName);
+                        ManageableAttributeStore attributeStore = kernel.getGBean(ManageableAttributeStore.class);                        
+                        GBeanData gData  = getGBeanDataFromConfiguration(absName);
+                        for(String attributeName : gData.getAttributeNames()){
+                            if(attributeName.equalsIgnoreCase(propertyKey)){
+                                // Hack to make changed values reflect on configuration restart.
+                                gData.setAttribute(attributeName, propertyValue);
+                                Properties gbeanProps = (Properties)gData1.getAttribute("properties");
+                                gbeanProps.setProperty(propertyKey, propertyValue);
+                                GAttributeInfo gAttributeInfo = gData.getGBeanInfo().getAttribute(attributeName);
+                                attributeStore.setValue(absName.getArtifact(), absName, gAttributeInfo, propertyValue, Thread.currentThread().getContextClassLoader());
+                            }
+                        }
+                    }
+                } catch (GBeanNotFoundException e) {
+                    return new Status(
+                            resourceBundle.getString("portlet.openejb.view.errorMessage1"));
+                } catch (NoSuchAttributeException e) {
+                    return new Status(
+                            resourceBundle.getString("portlet.openejb.view.errorMessage1"));
+                } catch (Exception e) {
+                    return new Status(
+                            resourceBundle.getString("portlet.openejb.view.errorMessage1"));
+                }
+            }
+        }
+        return new Status(resourceBundle.getString("portlet.openejb.view.message4"));
+    }
+    
+    private GBeanData getGBeanDataFromConfiguration(AbstractName absName){
+        Configuration configuration = ConfigurationUtil.getConfigurationManager(kernel).getConfiguration(absName.getArtifact());
+        GBeanData gData  = configuration.getGBeans().get(absName);
+        return gData;    	
+    }
+    @RemoteMethod
+    public List<EjbInformation> getDeploymentInfo(String containerId,
+            String deploymentId) {
+        Container container = containerSystem.getContainer(containerId);
+        DeploymentInfo deploymentInfo = container
+                .getDeploymentInfo(deploymentId);
+        List<EjbInformation> informations = new ArrayList<EjbInformation>();
+        EjbInformation information = new EjbInformation();
+        information.setName(resourceBundle.getString(BEANCLASSNAME_KEY));        
+        information.setValue(deploymentInfo.getBeanClass().getName());
+        informations.add(information);
+
+        if (deploymentInfo.getBusinessLocalInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(BLI_KEY));
+            information.setValue(appendMultipleInterfaces(deploymentInfo
+                    .getBusinessLocalInterfaces()));
+            informations.add(information);
+        }
+        if (deploymentInfo.getBusinessRemoteInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(BRI_KEY));
+            information.setValue(appendMultipleInterfaces(deploymentInfo
+                    .getBusinessRemoteInterfaces()));
+            informations.add(information);
+        }
+        information = new EjbInformation();
+        information.setName(resourceBundle.getString(DEPLOYMENTID_KEY));
+        information.setValue(deploymentId);
+        informations.add(information);
+        ;
+        information = new EjbInformation();
+        information.setName(resourceBundle.getString(EJBNAME_KEY));
+        information.setValue(deploymentInfo.getEjbName());
+        informations.add(information);
+        if (deploymentInfo.getHomeInterface() != null) {
+            information = new EjbInformation();
+            information.setValue(deploymentInfo.getHomeInterface().getName());
+            information.setName(resourceBundle.getString(EJBHOMEI_KEY));
+            informations.add(information);
+        }
+        if (!container.getContainerType().equals(ContainerType.MESSAGE_DRIVEN)) {
+            information = new EjbInformation();
+            Class cls = null;
+            try {
+                cls = Class
+                        .forName("org.apache.openejb.assembler.classic.JndiBuilder$Bindings");
+                Method method = cls.getMethod("getBindings");
+                List<String> jndiNames = (List) method.invoke(deploymentInfo
+                        .get(cls));
+                StringBuffer names = new StringBuffer();
+                for (String jndiName : jndiNames) {
+                    if (jndiName.startsWith("openejb/ejb/")) {
+                        jndiName = jndiName.replaceFirst("openejb/ejb/", "");
+                        names.append(jndiName).append(",");
+                    }
+                }
+                information.setValue(names.substring(0, names.length() - 1));
+            } catch (Exception e) {
+                log.error(resourceBundle.getString("portlet.openejb.view.errorMessage2"), e);
+            }
+            information.setName(resourceBundle.getString(JNDINAMES_KEY));
+            informations.add(information);
+        }
+        if (deploymentInfo.getLocalHomeInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(LHI_KEY));
+            information.setValue(deploymentInfo.getLocalHomeInterface()
+                    .getName());
+            informations.add(information);
+        }
+
+        if (deploymentInfo.getLocalInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(LI_KEY));
+            information.setValue(deploymentInfo.getLocalInterface().getName());
+            informations.add(information);
+        }
+
+        if (deploymentInfo.getRemoteInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(RI_KEY));
+            information.setValue(deploymentInfo.getRemoteInterface().getName());
+            informations.add(information);
+        }
+
+        if (deploymentInfo.getPrimaryKeyClass() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(PKC_KEY));
+            information.setValue(deploymentInfo.getPrimaryKeyClass().getName());
+            informations.add(information);
+        }
+
+        if (deploymentInfo.getPrimaryKeyField() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(PKF_KEY));
+            information.setValue(deploymentInfo.getPrimaryKeyField());
+            informations.add(information);
+        }
+
+        if (deploymentInfo.getServiceEndpointInterface() != null) {
+            information = new EjbInformation();
+            information.setName(resourceBundle.getString(SEI_KEY));
+            information.setValue(deploymentInfo.getServiceEndpointInterface()
+                    .getName());
+            informations.add(information);
+        }
+
+        return informations;
+    }
+
+    private String appendMultipleInterfaces(List<Class> multipleValues) {
+        StringBuffer multipleValuedStringBuffer = new StringBuffer();
+        for (Class singleValue : multipleValues) {
+            multipleValuedStringBuffer.append(singleValue.getName())
+                    .append(",");
+        }
+        if (multipleValuedStringBuffer.length() == 0) {
+            return null;
+        }
+        return multipleValuedStringBuffer.substring(0,
+                multipleValuedStringBuffer.length() - 1);
+    }
+
+    private String resolveContainerTypes(ContainerType cType) {
+        switch (cType) {
+        case STATELESS:
+            return "Stateless Containers";
+        case STATEFUL:
+            return "Stateful Containers";
+        case CMP_ENTITY:
+            return "CMP Entity Containers";
+        case BMP_ENTITY:
+            return "BMP Entity Containers";
+        case MESSAGE_DRIVEN:
+            return "Message Driven Containers";
+        default:
+            return "None";
+        }
+    }
+
+    private GBeanData getOpenEJBPropertiesGBean(String containerId, Class query) {
+        GBeanData data = null;
+        AbstractNameQuery absQuery = new AbstractNameQuery(query.getName());
+        Set containerGBeans = kernel.listGBeans(absQuery);
+        for (Object obj : containerGBeans) {
+            try {
+                data = kernel.getGBeanData((AbstractName) obj);
+            } catch (GBeanNotFoundException e) {
+                log.error(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.errorMessage3")
+                        , (AbstractName) obj), e);
+            } catch (InternalKernelException e) {
+                log.error(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.errorMessage4")
+                        , (AbstractName) obj), e);
+            } catch (IllegalStateException e) {
+                log.error(MessageFormat.format(resourceBundle.getString("portlet.openejb.view.errorMessage5")
+                        , (AbstractName) obj), e);
+            }
+            if (containerId.equals(EjbContainer.getId(data.getAbstractName()))
+                    || query == OpenEjbSystem.class) {
+                break;
+            }
+            data = null;
+        }
+        return data;
+    }
+
+}

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbInformation.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbInformation.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbInformation.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/EjbInformation.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,74 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import org.directwebremoting.annotations.DataTransferObject;
+
+@DataTransferObject
+public class EjbInformation {
+	
+	private String id;
+	
+	private String name;
+
+	private String value;
+	
+	private String editable;
+	
+	private String dirty = "false";
+
+	public String getName() {
+		return name;
+	}
+
+	public void setName(String name) {
+		this.name = name;
+	}
+
+	public String getValue() {
+		return value;
+	}
+
+	public void setValue(String value) {
+		this.value = value;
+	}
+
+	public String getEditable() {
+		return editable;
+	}
+
+	public void setEditable(String editable) {
+		this.editable = editable;
+	}
+
+	public String getId() {
+		return id;
+	}
+
+	public void setId(String id) {
+		this.id = id;
+	}
+
+	public String getDirty() {
+		return dirty;
+	}
+
+	public void setDirty(String dirty) {
+		this.dirty = dirty;
+	}
+	
+}

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Status.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Status.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Status.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Status.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,38 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import org.directwebremoting.annotations.DataTransferObject;
+import org.directwebremoting.annotations.RemoteProperty;
+
+@DataTransferObject
+public class Status {
+
+	private static final long serialVersionUID = -6124413956057404301L;
+
+	private String message;
+	
+	public Status(String message){
+		this.message = message;
+	}
+	
+	@RemoteProperty
+	public String getMessage() {		
+		return this.message;
+	}
+
+}

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Tree.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Tree.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Tree.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/Tree.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,60 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import java.util.List;
+import org.directwebremoting.annotations.DataTransferObject;
+
+@DataTransferObject
+public class Tree {
+
+    private String label;
+
+    private String identifier;
+
+    private List<TreeEntry> items;
+    
+    public Tree(String label, String identifier){
+        this.label = label;
+        this.identifier = identifier;
+    }
+
+    public List<TreeEntry> getItems() {
+        return items;
+    }
+
+    public void setItems(List<TreeEntry> items) {
+        this.items = items;
+    }
+
+    public String getLabel() {
+        return label;
+    }
+
+    public void setLabel(String label) {
+        this.label = label;
+    }
+
+    public String getIdentifier() {
+        return identifier;
+    }
+
+    public void setId(String identifier) {
+        this.identifier = identifier;
+    }
+
+}

Added: geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/TreeEntry.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/TreeEntry.java?rev=708815&view=auto
==============================================================================
--- geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/TreeEntry.java (added)
+++ geronimo/server/trunk/plugins/openejb/openejb-portlets/src/main/java/org/apache/geronimo/console/ejbserver/TreeEntry.java Wed Oct 29 01:01:59 2008
@@ -0,0 +1,53 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.ejbserver;
+
+import java.util.List;
+import org.directwebremoting.annotations.DataTransferObject;
+
+@DataTransferObject
+public class TreeEntry {
+
+    private String name;    
+    private List<TreeEntry> children;
+    private String value;
+
+    public List<TreeEntry> getChildren() {
+        return children;
+    }
+
+    public void setChildren(List<TreeEntry> children) {
+        this.children = children;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getValue() {
+        return value;
+    }
+
+    public void setValue(String value) {
+        this.value = value;
+    }
+
+}



Mime
View raw message