geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r1002525 [1/2] - in /geronimo/server/trunk/plugins: j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/ jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/ jetty8/geronimo-jetty8...
Date Wed, 29 Sep 2010 08:54:48 GMT
Author: djencks
Date: Wed Sep 29 08:54:47 2010
New Revision: 1002525

URL: http://svn.apache.org/viewvc?rev=1002525&view=rev
Log:
GERONIMO-5624 better default web app merging, and make jetty use more of the info tree

Removed:
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/StartupOrderComparatorTest.java
Modified:
    geronimo/server/trunk/plugins/j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/StandardWebAppInfoFactory.java
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilder.java
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilderTest.java
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/PlanParsingTest.java
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/main/java/org/apache/geronimo/jetty8/WebAppContextWrapper.java
    geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/test/java/org/apache/geronimo/jetty8/AbstractWebModuleTest.java
    geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/history/dependencies.xml
    geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/plan/plan.xml
    geronimo/server/trunk/plugins/tomcat/tomcat7-deployer/src/main/plan/plan.xml

Modified: geronimo/server/trunk/plugins/j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/StandardWebAppInfoFactory.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/StandardWebAppInfoFactory.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/StandardWebAppInfoFactory.java (original)
+++ geronimo/server/trunk/plugins/j2ee/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/StandardWebAppInfoFactory.java Wed Sep 29 08:54:47 2010
@@ -21,6 +21,9 @@
 package org.apache.geronimo.web25.deployment;
 
 import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
 
 import org.apache.geronimo.web.info.FilterInfo;
 import org.apache.geronimo.web.info.SecurityConstraintInfo;
@@ -44,18 +47,53 @@ public class StandardWebAppInfoFactory e
     @Override
     public void complete(WebAppInfo webAppInfo) {
         for (ServletInfo servletInfo : defaultWebAppInfo.servlets) {
-            webAppInfo.servlets.add(copy(servletInfo));
+            if (noServlet(servletInfo.servletName, webAppInfo.servlets)) {
+                webAppInfo.servlets.add(copy(servletInfo));
+            }
         }
         for (FilterInfo filterInfo : defaultWebAppInfo.filters) {
-            webAppInfo.filters.add(copy(filterInfo));
+            if (noFilter(filterInfo.filterName, webAppInfo.filters)) {
+                webAppInfo.filters.add(copy(filterInfo));
+            }
         }
         webAppInfo.listeners.addAll(defaultWebAppInfo.listeners);
-        webAppInfo.contextParams.putAll(defaultWebAppInfo.contextParams);
-        webAppInfo.contextRoot = defaultWebAppInfo.contextRoot;
+
+        for (Map.Entry<String, String> entry: defaultWebAppInfo.contextParams.entrySet()) {
+            if (!webAppInfo.contextParams.containsKey(entry.getKey())) {
+                webAppInfo.contextParams.put(entry.getKey(), entry.getValue());
+            }
+
+        }
         for (SecurityConstraintInfo securityConstraintInfo : defaultWebAppInfo.securityConstraints) {
             webAppInfo.securityConstraints.add(copy(securityConstraintInfo));
         }
         webAppInfo.securityRoles.addAll(defaultWebAppInfo.securityRoles);
+        if (webAppInfo.welcomeFiles.isEmpty()) {
+            webAppInfo.welcomeFiles.addAll(defaultWebAppInfo.welcomeFiles);
+        }
+        webAppInfo.errorPages.addAll(defaultWebAppInfo.errorPages);
+        for (Map.Entry<String, String> entry: defaultWebAppInfo.mimeMappings.entrySet()) {
+            if (!webAppInfo.mimeMappings.containsKey(entry.getKey())) {
+                webAppInfo.mimeMappings.put(entry.getKey(), entry.getValue());
+            }
+        }
+    }
+
+    private boolean noServlet(String servletName, List<ServletInfo> servlets) {
+        for (ServletInfo servletInfo: servlets) {
+            if (servletName.equals(servletInfo.servletName)) {
+                return false;
+            }
+        }
+        return true;
+    }
+    private boolean noFilter(String filterName, List<FilterInfo> filters) {
+        for (FilterInfo filterInfo: filters) {
+            if (filterName.equals(filterInfo.filterName)) {
+                return false;
+            }
+        }
+        return true;
     }
 
     @Override

Modified: geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilder.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilder.java (original)
+++ geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/main/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilder.java Wed Sep 29 08:54:47 2010
@@ -17,16 +17,12 @@
 
 package org.apache.geronimo.jetty8.deployment;
 
-import static java.lang.Boolean.FALSE;
-import static java.lang.Boolean.TRUE;
-
 import java.io.File;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.Serializable;
 import java.net.URI;
 import java.net.URL;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
 import java.util.Comparator;
@@ -36,7 +32,6 @@ import java.util.Map;
 import java.util.jar.JarFile;
 
 import javax.xml.bind.JAXBException;
-
 import org.apache.geronimo.common.DeploymentException;
 import org.apache.geronimo.deployment.Deployable;
 import org.apache.geronimo.deployment.DeployableBundle;
@@ -88,6 +83,7 @@ import org.apache.geronimo.security.jaas
 import org.apache.geronimo.security.jacc.ComponentPermissions;
 import org.apache.geronimo.web.WebAttributeName;
 import org.apache.geronimo.web.deployment.GenericToSpecificPlanConverter;
+import org.apache.geronimo.web.info.LoginConfigInfo;
 import org.apache.geronimo.web.info.ServletInfo;
 import org.apache.geronimo.web.info.WebAppInfo;
 import org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder;
@@ -103,15 +99,10 @@ import org.apache.geronimo.xbeans.geroni
 import org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppDocument;
 import org.apache.geronimo.xbeans.geronimo.web.jetty.JettyWebAppType;
 import org.apache.geronimo.xbeans.geronimo.web.jetty.config.GerJettyDocument;
-import org.apache.openejb.jee.ErrorPage;
-import org.apache.openejb.jee.FormLoginConfig;
 import org.apache.openejb.jee.JaxbJavaee;
 import org.apache.openejb.jee.LocaleEncodingMapping;
 import org.apache.openejb.jee.LocaleEncodingMappingList;
-import org.apache.openejb.jee.LoginConfig;
-import org.apache.openejb.jee.MimeMapping;
 import org.apache.openejb.jee.WebApp;
-import org.apache.openejb.jee.WelcomeFileList;
 import org.apache.xbean.osgi.bundle.util.BundleUtils;
 import org.apache.xmlbeans.XmlException;
 import org.apache.xmlbeans.XmlObject;
@@ -122,6 +113,9 @@ import org.osgi.service.packageadmin.Pac
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import static java.lang.Boolean.FALSE;
+import static java.lang.Boolean.TRUE;
+
 /**
  * @version $Rev:385659 $ $Date$
  */
@@ -160,22 +154,15 @@ public class JettyModuleBuilder extends 
 
     protected final NamespaceDrivenBuilderCollection clusteringBuilders;
 
-    private final List<String> defaultWelcomeFiles;
     private final Integer defaultSessionTimeoutSeconds;
-    private final Map<String, String> defaultLocaleEncodingMappings;
-    private final Map<String, String> defaultMimeTypeMappings;
 
     private static final String JETTY_NAMESPACE = JettyWebAppDocument.type.getDocumentElementName().getNamespaceURI();
 
     public JettyModuleBuilder(@ParamAttribute(name = "defaultEnvironment") Environment defaultEnvironment,
                               @ParamAttribute(name = "defaultSessionTimeoutSeconds") Integer defaultSessionTimeoutSeconds,
-                              @ParamAttribute(name = "defaultWelcomeFiles") List<String> defaultWelcomeFiles,
                               @ParamAttribute(name = "jettyContainerObjectName") AbstractNameQuery jettyContainerName,
                               @ParamAttribute(name = "defaultWebApp") WebAppInfo defaultWebApp,
                               @ParamAttribute(name = "jspServlet") WebAppInfo jspServlet,
-                              @ParamAttribute(name = "defaultJspServletName") String defaultJspServletName,
-                              @ParamAttribute(name = "defaultLocaleEncodingMappings") Map<String, String> defaultLocaleEncodingMappings,
-                              @ParamAttribute(name = "defaultMimeTypeMappings") Map<String, String> defaultMimeTypeMappings,
                               @ParamReference(name = "PojoWebServiceTemplate", namingType = NameFactory.SERVLET_WEB_SERVICE_TEMPLATE) Object pojoWebServiceTemplate,
                               @ParamReference(name = "WebServiceBuilder", namingType = NameFactory.MODULE_BUILDER) Collection<WebServiceBuilder> webServiceBuilder,
                               @ParamReference(name = "ClusteringBuilders", namingType = NameFactory.MODULE_BUILDER) Collection<NamespaceDrivenBuilder> clusteringBuilders,
@@ -200,9 +187,6 @@ public class JettyModuleBuilder extends 
         this.pojoWebServiceTemplate = getGBeanData(kernel, pojoWebServiceTemplate);
         this.clusteringBuilders = new NamespaceDrivenBuilderCollection(clusteringBuilders);//, GerClusteringDocument.type.getDocumentElementName());
 
-        this.defaultWelcomeFiles = defaultWelcomeFiles == null ? new ArrayList<String>() : defaultWelcomeFiles;
-        this.defaultLocaleEncodingMappings = defaultLocaleEncodingMappings == null ? new HashMap<String, String>() : defaultLocaleEncodingMappings;
-        this.defaultMimeTypeMappings = defaultMimeTypeMappings == null ? new HashMap<String, String>() : defaultMimeTypeMappings;
         ServiceReference sr = bundleContext.getServiceReference(PackageAdmin.class.getName());
     }
 
@@ -536,20 +520,8 @@ public class JettyModuleBuilder extends 
                 configureNoClustering(moduleContext, webModuleData);
             }
 
-            // configure mime mappings.
-            configureMimeMappings(webApp, webModuleData);
-
-            // configure welcome file lists.
-            configureWelcomeFileLists(webApp, webModuleData);
-
-            // configure local encoding mapping lists.
-            configureLocaleEncodingMappingLists(webApp, webModuleData);
-
-            // configure error pages.
-            configureErrorPages(webApp, webModuleData);
-
             // configure login configs.
-            configureAuthentication(module, webApp, jettyWebApp, webModuleData);
+            configureAuthentication(module, webAppInfo.loginConfig, jettyWebApp, webModuleData);
 
             if (jettyWebApp.isSetSecurityRealmName()) {
                 configureSecurityRealm(earContext, webApp, jettyWebApp, bundle, webModuleData);
@@ -629,14 +601,10 @@ public class JettyModuleBuilder extends 
 
     }
 
-    private void configureAuthentication(Module module, WebApp webApp, JettyWebAppType jettyWebApp, GBeanData webModuleData) throws DeploymentException, GBeanAlreadyExistsException {
+    private void configureAuthentication(Module module, LoginConfigInfo loginConfigInfo, JettyWebAppType jettyWebApp, GBeanData webModuleData) throws DeploymentException, GBeanAlreadyExistsException {
         EARContext moduleContext = module.getEarContext();
-        List<LoginConfig> loginConfigs = webApp.getLoginConfig();
-        if (loginConfigs.size() > 1) {
-            throw new DeploymentException("Web app " + module.getName() + " cannot have more than one login-config element.  Currently has " + loginConfigs.size() + " login-config elements.");
-        }
         JettyAuthenticationType authType = jettyWebApp.getAuthentication();
-        if (loginConfigs.size() == 1 || authType != null || jettyWebApp.isSetSecurityRealmName()) {
+        if (loginConfigInfo != null || authType != null || jettyWebApp.isSetSecurityRealmName()) {
             AbstractName factoryName = moduleContext.getNaming().createChildName(module.getModuleName(), "securityHandlerFactory", GBeanInfoBuilder.DEFAULT_J2EE_TYPE);
             webModuleData.setReferencePattern("SecurityHandlerFactory", factoryName);
 
@@ -651,24 +619,22 @@ public class JettyModuleBuilder extends 
                 configureLocalJaspicProvider(new JettyAuthenticationWrapper(authType), contextPath, module, securityFactoryData);
                 //otherwise rely on pre-configured jaspi
             } else {
-                LoginConfig loginConfig = loginConfigs.size() == 1 ? loginConfigs.get(0) : null;
                 GBeanData securityFactoryData = new GBeanData(factoryName, JettySecurityHandlerFactory.class);
-                configureConfigurationFactory(jettyWebApp, loginConfig, securityFactoryData);
+                configureConfigurationFactory(jettyWebApp, loginConfigInfo, securityFactoryData);
                 BuiltInAuthMethod auth = BuiltInAuthMethod.NONE;
-                if (loginConfig != null) {
-                    if (loginConfig.getAuthMethod() != null) {
-                        String authMethod = loginConfig.getAuthMethod().trim();
+                if (loginConfigInfo != null) {
+                    if (loginConfigInfo.authMethod != null) {
+                        String authMethod = loginConfigInfo.authMethod.trim();
                         auth = BuiltInAuthMethod.getValueOf(authMethod);
 
                         if (auth == BuiltInAuthMethod.BASIC) {
-                            securityFactoryData.setAttribute("realmName", loginConfig.getRealmName());
+                            securityFactoryData.setAttribute("realmName", loginConfigInfo.realmName);
                         } else if (auth == BuiltInAuthMethod.DIGEST) {
-                            securityFactoryData.setAttribute("realmName", loginConfig.getRealmName());
+                            securityFactoryData.setAttribute("realmName", loginConfigInfo.realmName);
                         } else if (auth == BuiltInAuthMethod.FORM) {
-                            if (loginConfig.getFormLoginConfig() != null) {
-                                FormLoginConfig formLoginConfig = loginConfig.getFormLoginConfig();
-                                securityFactoryData.setAttribute("loginPage", formLoginConfig.getFormLoginPage());
-                                securityFactoryData.setAttribute("errorPage", formLoginConfig.getFormErrorPage());
+                            if (loginConfigInfo.formLoginPage != null) {
+                                securityFactoryData.setAttribute("loginPage", loginConfigInfo.formLoginPage);
+                                securityFactoryData.setAttribute("errorPage", loginConfigInfo.formErrorPage);
                             }
                         } else if (auth == BuiltInAuthMethod.CLIENTCERT) {
                             //nothing to do
@@ -679,8 +645,8 @@ public class JettyModuleBuilder extends 
                     } else {
                         throw new DeploymentException("No auth method configured and no jaspi configured");
                     }
-                    if (loginConfig.getRealmName() != null) {
-                        webModuleData.setAttribute("realmName", loginConfig.getRealmName());
+                    if (loginConfigInfo.realmName != null) {
+                        webModuleData.setAttribute("realmName", loginConfigInfo.realmName);
                     }
                 }
                 securityFactoryData.setAttribute("authMethod", auth);
@@ -729,69 +695,18 @@ public class JettyModuleBuilder extends 
         }
     }
 
-    private void configureConfigurationFactory(JettyWebAppType jettyWebApp, LoginConfig loginConfig, GBeanData securityFactoryData) {
+    private void configureConfigurationFactory(JettyWebAppType jettyWebApp, LoginConfigInfo loginConfigInfo, GBeanData securityFactoryData) {
         String securityRealmName;
         if (jettyWebApp.isSetSecurityRealmName()) {
             securityRealmName = jettyWebApp.getSecurityRealmName().trim();
         } else {
-            if (loginConfig == null) return;
-            securityRealmName = loginConfig.getRealmName().trim();
+            if (loginConfigInfo == null) return;
+            securityRealmName = loginConfigInfo.realmName.trim();
         }
         AbstractNameQuery configurationFactoryName = new AbstractNameQuery(null, Collections.singletonMap("name", securityRealmName), ConfigurationFactory.class.getName());
         securityFactoryData.setReferencePattern("ConfigurationFactory", configurationFactoryName);
     }
 
-    private void configureErrorPages(WebApp webApp, GBeanData webModuleData) {
-        List<ErrorPage> errorPageArray = webApp.getErrorPage();
-        Map<String, String> errorPageMap = new HashMap<String, String>();
-        for (ErrorPage errorPage : errorPageArray) {
-            if (errorPage.getErrorCode() != null) {
-                errorPageMap.put(errorPage.getErrorCode() + "", errorPage.getLocation().trim());
-            } else {
-                errorPageMap.put(errorPage.getExceptionType().trim(), errorPage.getLocation().trim());
-            }
-        }
-        webModuleData.setAttribute("errorPages", errorPageMap);
-    }
-
-    private void configureLocaleEncodingMappingLists(WebApp webApp, GBeanData webModuleData) {
-        List<LocaleEncodingMappingList> localeEncodingMappingListArray = webApp.getLocaleEncodingMappingList();
-        Map<String, String> localeEncodingMappingMap = new HashMap<String, String>(defaultLocaleEncodingMappings);
-        for (LocaleEncodingMappingList aLocaleEncodingMappingListArray : localeEncodingMappingListArray) {
-            List<LocaleEncodingMapping> localeEncodingMappingArray = aLocaleEncodingMappingListArray.getLocaleEncodingMapping();
-            for (LocaleEncodingMapping localeEncodingMapping : localeEncodingMappingArray) {
-                localeEncodingMappingMap.put(localeEncodingMapping.getLocale().trim(), localeEncodingMapping.getEncoding().trim());
-            }
-        }
-        webModuleData.setAttribute("localeEncodingMapping", localeEncodingMappingMap);
-    }
-
-    private void configureWelcomeFileLists(WebApp webApp, GBeanData webModuleData) {
-        List<WelcomeFileList> welcomeFileArray = webApp.getWelcomeFileList();
-        List<String> welcomeFiles;
-        if (welcomeFileArray.size() > 0) {
-            welcomeFiles = new ArrayList<String>();
-            for (WelcomeFileList aWelcomeFileArray : welcomeFileArray) {
-                List<String> welcomeFileList = aWelcomeFileArray.getWelcomeFile();
-                for (String welcomeFile : welcomeFileList) {
-                    welcomeFiles.add(welcomeFile.trim());
-                }
-            }
-        } else {
-            welcomeFiles = new ArrayList<String>(defaultWelcomeFiles);
-        }
-        webModuleData.setAttribute("welcomeFiles", welcomeFiles.toArray(new String[welcomeFiles.size()]));
-    }
-
-    private void configureMimeMappings(WebApp webApp, GBeanData webModuleData) {
-        List<MimeMapping> mimeMappingArray = webApp.getMimeMapping();
-        Map<String, String> mimeMappingMap = new HashMap<String, String>(defaultMimeTypeMappings);
-        for (MimeMapping mimeMapping : mimeMappingArray) {
-            mimeMappingMap.put(mimeMapping.getExtension().trim(), mimeMapping.getMimeType().trim());
-        }
-        webModuleData.setAttribute("mimeMap", mimeMappingMap);
-    }
-
     private void configureHosts(EARContext earContext, JettyWebAppType jettyWebApp, GBeanData webModuleData) throws GBeanAlreadyExistsException {
         String[] hosts = jettyWebApp.getHostArray();
         for (int i = 0; i < hosts.length; i++) {
@@ -816,45 +731,4 @@ public class JettyModuleBuilder extends 
         return JETTY_NAMESPACE;
     }
 
-    static class StartupOrderComparator implements Comparator<org.apache.openejb.jee.Servlet>, Serializable {
-        /**
-         * comparator that compares first on the basis of startup order, and then on the lexicographical
-         * ordering of servlet name.  Since the servlet names have a uniqueness constraint, this should
-         * provide a total ordering consistent with equals.  All servlets with no startup order are after
-         * all servlets with a startup order.
-         *
-         * @param s1 first Servlet object
-         * @param s2 second Servlet object
-         * @return an int < 0 if o1 precedes o2, 0 if they are equal, and > 0 if o2 preceeds o1.
-         */
-        public int compare(org.apache.openejb.jee.Servlet s1, org.apache.openejb.jee.Servlet s2) {
-
-            // load-on-startup is set for neither.  the
-            // ordering at this point doesn't matter, but we
-            // should return "0" only if the two objects say
-            // they are equal
-            if (s1.getLoadOnStartup() == null && s2.getLoadOnStartup() == null) {
-                return s1.equals(s2) ? 0 : s1.getServletName().trim().compareTo(s2.getServletName().trim());
-            }
-
-            // load-on-startup is set for one but not the
-            // other.  whichever one is set will be "less
-            // than", i.e. it will be loaded first
-            if (s1.getLoadOnStartup() != null && s2.getLoadOnStartup() == null) {
-                return -1;
-            }
-            if (s1.getLoadOnStartup() == null && s2.getLoadOnStartup() != null) {
-                return 1;
-            }
-
-            // load-on-startup is set for both.  whichever one
-            // has a smaller value is "less than"
-            int comp = new Integer(s1.getLoadOnStartup()).compareTo(s2.getLoadOnStartup());
-            if (comp == 0) {
-                return s1.getServletName().trim().compareTo(s2.getServletName().trim());
-            }
-            return comp;
-        }
-    }
-
 }

Modified: geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilderTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilderTest.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilderTest.java (original)
+++ geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/JettyModuleBuilderTest.java Wed Sep 29 08:54:47 2010
@@ -349,13 +349,10 @@ public class JettyModuleBuilderTest exte
         bundleContext.registerService(PackageAdmin.class.getName(), packageAdmin, null);
         builder = new JettyModuleBuilder(defaultEnvironment,
                 new Integer(1800),
-                Collections.EMPTY_LIST,
                 new AbstractNameQuery(containerName),
                 //new AbstractNameQuery(containerName),
                 new WebAppInfo(),
                 null,
-                "jsp", null,
-                null,
                 pojoWebServiceTemplate,
                 Collections.singleton(webServiceBuilder),
                 null,

Modified: geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/PlanParsingTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/PlanParsingTest.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/PlanParsingTest.java (original)
+++ geronimo/server/trunk/plugins/jetty8/geronimo-jetty8-builder/src/test/java/org/apache/geronimo/jetty8/deployment/PlanParsingTest.java Wed Sep 29 08:54:47 2010
@@ -145,12 +145,9 @@ public class PlanParsingTest extends Xml
         bundleContext.registerService(PackageAdmin.class.getName(), packageAdmin, null);
         builder = new JettyModuleBuilder(defaultEnvironment,
                 new Integer(1800),
-                null,
                 jettyContainerObjectName,
                 new WebAppInfo(),
                 null,
-                "jsp", null,
-                null,
                 pojoWebServiceTemplate,
                 Collections.singleton(webServiceBuilder),
                 null,

Modified: geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/main/java/org/apache/geronimo/jetty8/WebAppContextWrapper.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/main/java/org/apache/geronimo/jetty8/WebAppContextWrapper.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/main/java/org/apache/geronimo/jetty8/WebAppContextWrapper.java (original)
+++ geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/main/java/org/apache/geronimo/jetty8/WebAppContextWrapper.java Wed Sep 29 08:54:47 2010
@@ -54,6 +54,7 @@ import org.apache.geronimo.management.ge
 import org.apache.geronimo.security.jacc.ApplicationPolicyConfigurationManager;
 import org.apache.geronimo.security.jacc.RunAsSource;
 import org.apache.geronimo.transaction.GeronimoUserTransaction;
+import org.apache.geronimo.web.info.ErrorPageInfo;
 import org.apache.geronimo.web.info.WebAppInfo;
 import org.eclipse.jetty.http.MimeTypes;
 import org.eclipse.jetty.security.SecurityHandler;
@@ -103,14 +104,7 @@ public class WebAppContextWrapper implem
                                 @ParamAttribute(name = "workDir") String workDir,
                                 @ParamAttribute(name = "unshareableResources") Set<String> unshareableResources,
                                 @ParamAttribute(name = "applicationManagedSecurityResources") Set<String> applicationManagedSecurityResources,
-                                @ParamAttribute(name = "displayName") String displayName,
-                                @ParamAttribute(name = "contextParamMap") Map<String, String> contextParamMap,
-//                                @ParamAttribute(name = "listenerClassNames") Collection<String> listenerClassNames,
                                 @ParamAttribute(name = "distributable") boolean distributable,
-                                @ParamAttribute(name = "mimeMap") Map mimeMap,
-                                @ParamAttribute(name = "welcomeFiles") String[] welcomeFiles,
-                                @ParamAttribute(name = "localeEncodingMapping") Map<String, String> localeEncodingMapping,
-                                @ParamAttribute(name = "errorPages") Map errorPages,
                                 @ParamAttribute(name = "tagLibMap") Map<String, String> tagLibMap,
                                 @ParamAttribute(name = "compactPath") boolean compactPath,
 
@@ -203,7 +197,7 @@ public class WebAppContextWrapper implem
         }
 
         MimeTypes mimeTypes = new MimeTypes();
-        mimeTypes.setMimeMap(mimeMap);
+        mimeTypes.setMimeMap(webAppInfo.mimeMappings);
         webAppContext.setMimeTypes(mimeTypes);
 
         this.server = server;
@@ -228,15 +222,26 @@ public class WebAppContextWrapper implem
         }
 
         //stuff from spec dd
-        setDisplayName(displayName);
-        if (contextParamMap != null) {
-            webAppContext.getInitParams().putAll(contextParamMap);
-        }
+        setDisplayName(webAppInfo.displayName);
+        webAppContext.getInitParams().putAll(webAppInfo.contextParams);
         webAppContext.setDistributable(distributable);
-        webAppContext.setWelcomeFiles(welcomeFiles);
-        setLocaleEncodingMapping(localeEncodingMapping);
-        setErrorPages(errorPages);
-        setTagLibMap(tagLibMap);
+        webAppContext.setWelcomeFiles(webAppInfo.welcomeFiles.toArray(new String[webAppInfo.welcomeFiles.size()]));
+        for (Map.Entry<String, String> entry : webAppInfo.localeEncodingMappings.entrySet()) {
+            this.webAppContext.addLocaleEncoding(entry.getKey(), entry.getValue());
+        }
+        ErrorPageErrorHandler errorHandler = (ErrorPageErrorHandler) this.webAppContext.getErrorHandler();
+        for (ErrorPageInfo errorPageInfo: webAppInfo.errorPages) {
+            if (errorPageInfo.exceptionType != null) {
+                errorHandler.addErrorPage(errorPageInfo.exceptionType, errorPageInfo.location);
+            } else {
+                errorHandler.addErrorPage(errorPageInfo.errorCode, errorPageInfo.location);
+            }
+        }
+        if (tagLibMap != null) {
+            for (Map.Entry<String, String> entry : tagLibMap.entrySet()) {
+                this.webAppContext.setResourceAlias(entry.getKey(), entry.getValue());
+            }
+        }
 
         if (!distributable) {
             setSessionTimeoutSeconds(sessionTimeoutSeconds);
@@ -310,40 +315,6 @@ public class WebAppContextWrapper implem
 
         log.warn("WebAppContextWrapper failed");
     }
-    //pass through attributes.  They should be constructor params
-
-    public void setLocaleEncodingMapping(@ParamAttribute(name = "localeEncodingMapping")Map<String, String> localeEncodingMap) {
-        if (localeEncodingMap != null) {
-            for (Map.Entry<String, String> entry : localeEncodingMap.entrySet()) {
-                this.webAppContext.addLocaleEncoding(entry.getKey(), entry.getValue());
-            }
-        }
-    }
-
-//    public void setListenerClassNames(@ParamAttribute(name = "listenerClassNames")Collection<String> eventListeners) throws ClassNotFoundException, IllegalAccessException, InstantiationException {
-//        if (eventListeners != null) {
-//            Collection<EventListener> listeners = new ArrayList<EventListener>();
-//            for (String listenerClassName : eventListeners) {
-//                EventListener listener = (EventListener) newInstance(listenerClassName);
-//                listeners.add(listener);
-//            }
-//            webAppContext.setEventListeners(listeners.toArray(new EventListener[listeners.size()]));
-//        }
-//    }
-
-    public void setErrorPages(Map errorPageMap) {
-        if (errorPageMap != null) {
-            ((ErrorPageErrorHandler) this.webAppContext.getErrorHandler()).setErrorPages(errorPageMap);
-        }
-    }
-
-    public void setTagLibMap(Map<String, String> tagLibMap) {
-        if (tagLibMap != null) {
-            for (Map.Entry<String, String> entry : tagLibMap.entrySet()) {
-                this.webAppContext.setResourceAlias(entry.getKey(), entry.getValue());
-            }
-        }
-    }
 
     public void setSessionTimeoutSeconds(int seconds) {
         this.webAppContext.getSessionHandler().getSessionManager().setMaxInactiveInterval(seconds);

Modified: geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/test/java/org/apache/geronimo/jetty8/AbstractWebModuleTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/test/java/org/apache/geronimo/jetty8/AbstractWebModuleTest.java?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/test/java/org/apache/geronimo/jetty8/AbstractWebModuleTest.java (original)
+++ geronimo/server/trunk/plugins/jetty8/geronimo-jetty8/src/test/java/org/apache/geronimo/jetty8/AbstractWebModuleTest.java Wed Sep 29 08:54:47 2010
@@ -160,14 +160,8 @@ public class AbstractWebModuleTest exten
                 bundle,
                 null, null,
                 null,
-                "context",
-                null,
                 false,
                 null,
-                null,
-                null,
-                null,
-                null,
                 false,
                 0,
                 sessionHandlerFactory,

Modified: geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/history/dependencies.xml?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/history/dependencies.xml (original)
+++ geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/history/dependencies.xml Wed Sep 29 08:54:47 2010
@@ -26,4 +26,29 @@
         <artifactId>geronimo-jetty8-builder</artifactId>
         <type>jar</type>
     </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.modules</groupId>
+        <artifactId>geronimo-web</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.specs</groupId>
+        <artifactId>geronimo-jacc_1.4_spec</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.specs</groupId>
+        <artifactId>geronimo-jaspic_1.0_spec</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.specs</groupId>
+        <artifactId>geronimo-osgi-locator</artifactId>
+        <type>jar</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.xbean</groupId>
+        <artifactId>xbean-bundleutils</artifactId>
+        <type>jar</type>
+    </dependency>
 </plugin-artifact>

Modified: geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/plan/plan.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/plan/plan.xml?rev=1002525&r1=1002524&r2=1002525&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/plan/plan.xml (original)
+++ geronimo/server/trunk/plugins/jetty8/jetty8-deployer/src/main/plan/plan.xml Wed Sep 29 08:54:47 2010
@@ -22,52 +22,48 @@
 
     <gbean name="JettyWebBuilder" class="org.apache.geronimo.jetty8.deployment.JettyModuleBuilder">
         <attribute name="defaultSessionTimeoutSeconds">1800</attribute>
-        <attribute name="defaultWelcomeFiles">index.html,index.htm,index.jsp</attribute>
         <attribute name="jettyContainerObjectName">?name=JettyWebContainer</attribute>
-        <attribute name="defaultLocaleEncodingMappings">
-            ar=ISO-8859-6
-            be=ISO-8859-5
-            bg=ISO-8859-5
-            ca=ISO-8859-1
-            cs=ISO-8859-2
-            da=ISO-8859-1
-            de=ISO-8859-1
-            el=ISO-8859-7
-            en=ISO-8859-1
-            es=ISO-8859-1
-            et=ISO-8859-1
-            fi=ISO-8859-1
-            fr=ISO-8859-1
-            hr=ISO-8859-2
-            hu=ISO-8859-2
-            is=ISO-8859-1
-            it=ISO-8859-1
-            iw=ISO-8859-8
-            ja=Shift_JIS
-            ko=EUC-KR
-            lt=ISO-8859-2
-            lv=ISO-8859-2
-            mk=ISO-8859-5
-            nl=ISO-8859-1
-            no=ISO-8859-1
-            pl=ISO-8859-2
-            pt=ISO-8859-1
-            ro=ISO-8859-2
-            ru=ISO-8859-5
-            sh=ISO-8859-5
-            sk=ISO-8859-2
-            sl=ISO-8859-2
-            sq=ISO-8859-2
-            sr=ISO-8859-5
-            sv=ISO-8859-1
-            tr=ISO-8859-9
-            uk=ISO-8859-5
-            zh=GB2312
-            zh_TW=Big5
-        </attribute>
-        <attribute name="defaultMimeTypeMappings">
-            wsdl=text/xml
-        </attribute>
+        <!--<attribute name="defaultLocaleEncodingMappings">-->
+            <!--ar=ISO-8859-6-->
+            <!--be=ISO-8859-5-->
+            <!--bg=ISO-8859-5-->
+            <!--ca=ISO-8859-1-->
+            <!--cs=ISO-8859-2-->
+            <!--da=ISO-8859-1-->
+            <!--de=ISO-8859-1-->
+            <!--el=ISO-8859-7-->
+            <!--en=ISO-8859-1-->
+            <!--es=ISO-8859-1-->
+            <!--et=ISO-8859-1-->
+            <!--fi=ISO-8859-1-->
+            <!--fr=ISO-8859-1-->
+            <!--hr=ISO-8859-2-->
+            <!--hu=ISO-8859-2-->
+            <!--is=ISO-8859-1-->
+            <!--it=ISO-8859-1-->
+            <!--iw=ISO-8859-8-->
+            <!--ja=Shift_JIS-->
+            <!--ko=EUC-KR-->
+            <!--lt=ISO-8859-2-->
+            <!--lv=ISO-8859-2-->
+            <!--mk=ISO-8859-5-->
+            <!--nl=ISO-8859-1-->
+            <!--no=ISO-8859-1-->
+            <!--pl=ISO-8859-2-->
+            <!--pt=ISO-8859-1-->
+            <!--ro=ISO-8859-2-->
+            <!--ru=ISO-8859-5-->
+            <!--sh=ISO-8859-5-->
+            <!--sk=ISO-8859-2-->
+            <!--sl=ISO-8859-2-->
+            <!--sq=ISO-8859-2-->
+            <!--sr=ISO-8859-5-->
+            <!--sv=ISO-8859-1-->
+            <!--tr=ISO-8859-9-->
+            <!--uk=ISO-8859-5-->
+            <!--zh=GB2312-->
+            <!--zh_TW=Big5-->
+        <!--</attribute>-->
         <xml-attribute name="defaultWebApp">
             <web-app xmlns="http://java.sun.com/xml/ns/javaee">
                 <servlet>
@@ -104,6 +100,730 @@
                     <url-pattern>/</url-pattern>
                 </servlet-mapping>
 
+                <welcome-file-list>
+                    <welcome-file>index.html</welcome-file>
+                    <welcome-file>index.htm</welcome-file>
+                    <welcome-file>index.jsp</welcome-file>
+                </welcome-file-list>
+                <mime-mapping>
+                    <extension>abs</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ai</extension>
+                    <mime-type>application/postscript</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>aif</extension>
+                    <mime-type>audio/x-aiff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>aifc</extension>
+                    <mime-type>audio/x-aiff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>aiff</extension>
+                    <mime-type>audio/x-aiff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>aim</extension>
+                    <mime-type>application/x-aim</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>art</extension>
+                    <mime-type>image/x-jg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>asf</extension>
+                    <mime-type>video/x-ms-asf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>asx</extension>
+                    <mime-type>video/x-ms-asf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>au</extension>
+                    <mime-type>audio/basic</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>avi</extension>
+                    <mime-type>video/x-msvideo</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>avx</extension>
+                    <mime-type>video/x-rad-screenplay</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>bcpio</extension>
+                    <mime-type>application/x-bcpio</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>bin</extension>
+                    <mime-type>application/octet-stream</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>bmp</extension>
+                    <mime-type>image/bmp</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>body</extension>
+                    <mime-type>text/html</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>cdf</extension>
+                    <mime-type>application/x-cdf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>cer</extension>
+                    <mime-type>application/x-x509-ca-cert</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>class</extension>
+                    <mime-type>application/java</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>cpio</extension>
+                    <mime-type>application/x-cpio</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>csh</extension>
+                    <mime-type>application/x-csh</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>css</extension>
+                    <mime-type>text/css</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>dib</extension>
+                    <mime-type>image/bmp</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>doc</extension>
+                    <mime-type>application/msword</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>dtd</extension>
+                    <mime-type>application/xml-dtd</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>dv</extension>
+                    <mime-type>video/x-dv</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>dvi</extension>
+                    <mime-type>application/x-dvi</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>eps</extension>
+                    <mime-type>application/postscript</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>etx</extension>
+                    <mime-type>text/x-setext</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>exe</extension>
+                    <mime-type>application/octet-stream</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>gif</extension>
+                    <mime-type>image/gif</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>gtar</extension>
+                    <mime-type>application/x-gtar</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>gz</extension>
+                    <mime-type>application/x-gzip</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>hdf</extension>
+                    <mime-type>application/x-hdf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>hqx</extension>
+                    <mime-type>application/mac-binhex40</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>htc</extension>
+                    <mime-type>text/x-component</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>htm</extension>
+                    <mime-type>text/html</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>html</extension>
+                    <mime-type>text/html</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>hqx</extension>
+                    <mime-type>application/mac-binhex40</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ief</extension>
+                    <mime-type>image/ief</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jad</extension>
+                    <mime-type>text/vnd.sun.j2me.app-descriptor</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jar</extension>
+                    <mime-type>application/java-archive</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>java</extension>
+                    <mime-type>text/plain</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jnlp</extension>
+                    <mime-type>application/x-java-jnlp-file</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jpe</extension>
+                    <mime-type>image/jpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jpeg</extension>
+                    <mime-type>image/jpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jpg</extension>
+                    <mime-type>image/jpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>js</extension>
+                    <mime-type>text/javascript</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jsf</extension>
+                    <mime-type>text/plain</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>jspf</extension>
+                    <mime-type>text/plain</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>kar</extension>
+                    <mime-type>audio/x-midi</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>latex</extension>
+                    <mime-type>application/x-latex</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>m3u</extension>
+                    <mime-type>audio/x-mpegurl</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mac</extension>
+                    <mime-type>image/x-macpaint</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>man</extension>
+                    <mime-type>application/x-troff-man</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mathml</extension>
+                    <mime-type>application/mathml+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>me</extension>
+                    <mime-type>application/x-troff-me</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mid</extension>
+                    <mime-type>audio/x-midi</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>midi</extension>
+                    <mime-type>audio/x-midi</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mif</extension>
+                    <mime-type>application/x-mif</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mov</extension>
+                    <mime-type>video/quicktime</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>movie</extension>
+                    <mime-type>video/x-sgi-movie</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mp1</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mp2</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mp3</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mp4</extension>
+                    <mime-type>video/mp4</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpa</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpe</extension>
+                    <mime-type>video/mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpeg</extension>
+                    <mime-type>video/mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpega</extension>
+                    <mime-type>audio/x-mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpg</extension>
+                    <mime-type>video/mpeg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>mpv2</extension>
+                    <mime-type>video/mpeg2</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ms</extension>
+                    <mime-type>application/x-wais-source</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>nc</extension>
+                    <mime-type>application/x-netcdf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>oda</extension>
+                    <mime-type>application/oda</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Database -->
+                    <extension>odb</extension>
+                    <mime-type>application/vnd.oasis.opendocument.database</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Chart -->
+                    <extension>odc</extension>
+                    <mime-type>application/vnd.oasis.opendocument.chart</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Formula -->
+                    <extension>odf</extension>
+                    <mime-type>application/vnd.oasis.opendocument.formula</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Drawing -->
+                    <extension>odg</extension>
+                    <mime-type>application/vnd.oasis.opendocument.graphics</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Image -->
+                    <extension>odi</extension>
+                    <mime-type>application/vnd.oasis.opendocument.image</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Master Document -->
+                    <extension>odm</extension>
+                    <mime-type>application/vnd.oasis.opendocument.text-master</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Presentation -->
+                    <extension>odp</extension>
+                    <mime-type>application/vnd.oasis.opendocument.presentation</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Spreadsheet -->
+                    <extension>ods</extension>
+                    <mime-type>application/vnd.oasis.opendocument.spreadsheet</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Text -->
+                    <extension>odt</extension>
+                    <mime-type>application/vnd.oasis.opendocument.text</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Drawing Template -->
+                    <extension>otg </extension>
+                    <mime-type>application/vnd.oasis.opendocument.graphics-template</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- HTML Document Template -->
+                    <extension>oth</extension>
+                    <mime-type>application/vnd.oasis.opendocument.text-web</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Presentation Template -->
+                    <extension>otp</extension>
+                    <mime-type>application/vnd.oasis.opendocument.presentation-template</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Spreadsheet Template -->
+                    <extension>ots</extension>
+                    <mime-type>application/vnd.oasis.opendocument.spreadsheet-template </mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- OpenDocument Text Template -->
+                    <extension>ott</extension>
+                    <mime-type>application/vnd.oasis.opendocument.text-template</mime-type>
+                </mime-mapping>
+                <!-- xiph mime types -->
+                <mime-mapping>
+                    <extension>ogx</extension>
+                    <mime-type>application/ogg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ogv</extension>
+                    <mime-type>video/ogg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>oga</extension>
+                    <mime-type>audio/ogg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ogg</extension>
+                    <mime-type>audio/ogg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>spx</extension>
+                    <mime-type>audio/ogg</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>flac</extension>
+                    <mime-type>audio/flac</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>anx</extension>
+                    <mime-type>application/annodex</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>axa</extension>
+                    <mime-type>audio/annodex</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>axv</extension>
+                    <mime-type>video/annodex</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xspf</extension>
+                    <mime-type>application/xspf+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pbm</extension>
+                    <mime-type>image/x-portable-bitmap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pct</extension>
+                    <mime-type>image/pict</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pdf</extension>
+                    <mime-type>application/pdf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pgm</extension>
+                    <mime-type>image/x-portable-graymap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pic</extension>
+                    <mime-type>image/pict</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pict</extension>
+                    <mime-type>image/pict</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pls</extension>
+                    <mime-type>audio/x-scpls</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>png</extension>
+                    <mime-type>image/png</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pnm</extension>
+                    <mime-type>image/x-portable-anymap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pnt</extension>
+                    <mime-type>image/x-macpaint</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ppm</extension>
+                    <mime-type>image/x-portable-pixmap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ppt</extension>
+                    <mime-type>application/vnd.ms-powerpoint</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>pps</extension>
+                    <mime-type>application/vnd.ms-powerpoint</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ps</extension>
+                    <mime-type>application/postscript</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>psd</extension>
+                    <mime-type>image/x-photoshop</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>qt</extension>
+                    <mime-type>video/quicktime</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>qti</extension>
+                    <mime-type>image/x-quicktime</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>qtif</extension>
+                    <mime-type>image/x-quicktime</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ras</extension>
+                    <mime-type>image/x-cmu-raster</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>rdf</extension>
+                    <mime-type>application/rdf+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>rgb</extension>
+                    <mime-type>image/x-rgb</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>rm</extension>
+                    <mime-type>application/vnd.rn-realmedia</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>roff</extension>
+                    <mime-type>application/x-troff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>rtf</extension>
+                    <mime-type>application/rtf</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>rtx</extension>
+                    <mime-type>text/richtext</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>sh</extension>
+                    <mime-type>application/x-sh</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>shar</extension>
+                    <mime-type>application/x-shar</mime-type>
+                </mime-mapping>
+            <!--
+                <mime-mapping>
+                    <extension>shtml</extension>
+                    <mime-type>text/x-server-parsed-html</mime-type>
+                </mime-mapping>
+            -->
+                <mime-mapping>
+                    <extension>smf</extension>
+                    <mime-type>audio/x-midi</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>sit</extension>
+                    <mime-type>application/x-stuffit</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>snd</extension>
+                    <mime-type>audio/basic</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>src</extension>
+                    <mime-type>application/x-wais-source</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>sv4cpio</extension>
+                    <mime-type>application/x-sv4cpio</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>sv4crc</extension>
+                    <mime-type>application/x-sv4crc</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>svg</extension>
+                    <mime-type>image/svg+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>svgz</extension>
+                    <mime-type>image/svg+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>swf</extension>
+                    <mime-type>application/x-shockwave-flash</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>t</extension>
+                    <mime-type>application/x-troff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tar</extension>
+                    <mime-type>application/x-tar</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tcl</extension>
+                    <mime-type>application/x-tcl</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tex</extension>
+                    <mime-type>application/x-tex</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>texi</extension>
+                    <mime-type>application/x-texinfo</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>texinfo</extension>
+                    <mime-type>application/x-texinfo</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tif</extension>
+                    <mime-type>image/tiff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tiff</extension>
+                    <mime-type>image/tiff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tr</extension>
+                    <mime-type>application/x-troff</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>tsv</extension>
+                    <mime-type>text/tab-separated-values</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>txt</extension>
+                    <mime-type>text/plain</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ulw</extension>
+                    <mime-type>audio/basic</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>ustar</extension>
+                    <mime-type>application/x-ustar</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>vxml</extension>
+                    <mime-type>application/voicexml+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xbm</extension>
+                    <mime-type>image/x-xbitmap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xht</extension>
+                    <mime-type>application/xhtml+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xhtml</extension>
+                    <mime-type>application/xhtml+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xls</extension>
+                    <mime-type>application/vnd.ms-excel</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xml</extension>
+                    <mime-type>application/xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xpm</extension>
+                    <mime-type>image/x-xpixmap</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xsl</extension>
+                    <mime-type>application/xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xslt</extension>
+                    <mime-type>application/xslt+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xul</extension>
+                    <mime-type>application/vnd.mozilla.xul+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>xwd</extension>
+                    <mime-type>image/x-xwindowdump</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>vsd</extension>
+                    <mime-type>application/x-visio</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>wav</extension>
+                    <mime-type>audio/x-wav</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- Wireless Bitmap -->
+                    <extension>wbmp</extension>
+                    <mime-type>image/vnd.wap.wbmp</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- WML Source -->
+                    <extension>wml</extension>
+                    <mime-type>text/vnd.wap.wml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- Compiled WML -->
+                    <extension>wmlc</extension>
+                    <mime-type>application/vnd.wap.wmlc</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- WML Script Source -->
+                    <extension>wmls</extension>
+                    <mime-type>text/vnd.wap.wmlscript</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <!-- Compiled WML Script -->
+                    <extension>wmlscriptc</extension>
+                    <mime-type>application/vnd.wap.wmlscriptc</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>wmv</extension>
+                    <mime-type>video/x-ms-wmv</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>wrl</extension>
+                    <mime-type>x-world/x-vrml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>wspolicy</extension>
+                    <mime-type>application/wspolicy+xml</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>Z</extension>
+                    <mime-type>application/x-compress</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>z</extension>
+                    <mime-type>application/x-compress</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>zip</extension>
+                    <mime-type>application/zip</mime-type>
+                </mime-mapping>
+                <mime-mapping>
+                    <extension>wsdl</extension>
+                    <mime-type>text/xml</mime-type>
+                </mime-mapping>
+
             </web-app>
         </xml-attribute>
         <xml-attribute name="jspServlet">
@@ -135,7 +855,6 @@
 
 
         </xml-attribute>
-        <attribute name="defaultJspServletName">jsp</attribute>
         <references name="ServiceBuilders">
             <pattern>
                 <name>GBeanBuilder</name>



Mime
View raw message