This is an XML Schema Definition for Geronimo tomcat web applicationdeployment plan. In case the web application deployment plan isprovided internally in the web archive, it should be namedMETA-INF/geronimo-web.xml. In case the web application deploymentplan is provided externally, the deployment descriptor can be namedanything and provided to the deploy tool. Alternatively, it can beincluded in the EAR and referenced by an alt-dd element of the EARdeployment plan. All the web application deployment plan mustspecify the top level element as web-app with namespace specified asxmlns="http://geronimo.apache.org/xml/ns/j2ee/web/tomcat-2.0.1". Thedefault location for this document ishttp://geronimo.apache.org/xml/ns/j2ee/web/tomcat-2.0.1
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. Copyright 2005-2007 Sun Microsystems, Inc. All rights reserved. The contents of this file are subject to the terms of either the GNU General Public License Version 2 only ("GPL") or the Common Development and Distribution License("CDDL") (collectively, the "License"). You may not use this file except in compliance with the License. You can obtain a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html or glassfish/bootstrap/legal/LICENSE.txt. See the License for the specific language governing permissions and limitations under the License. When distributing the software, include this License Header Notice in each file and include the License file at glassfish/bootstrap/legal/LICENSE.txt. Sun designates this particular file as subject to the "Classpath" exception as provided by Sun in the GPL Version 2 section of the License file that accompanied this code. If applicable, add the following below the License Header, with the fields enclosed by brackets [] replaced by your own identifying information: "Portions Copyrighted [year] [name of copyright owner]" Contributor(s): If you wish your version of this file to be governed by only the CDDL or only the GPL Version 2, indicate your decision by adding "[Contributor] elects to include this software in this distribution under the [CDDL or GPL Version 2] license." If you don't indicate a single choice of license, a recipient has the option to distribute your version of this file under either the CDDL, the GPL Version 2 or to extend the choice of license to its licensees as provided above. However, if you add GPL Version 2 code and therefore, elected the GPL Version 2 license, then the option applies only if the new code is made subject to such option by the copyright holder.
This is the XML Schema for the persistence configuration file. The file must be named "META-INF/persistence.xml" in the persistence archive. Persistence configuration files must indicate the persistence schema by using the persistence namespace: http://java.sun.com/xml/ns/persistence and indicate the version of the schema by using the version element as shown below: <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" version="1.0"> ... </persistence>
The web-app element is the root of the deployment descriptor fora Geronimo tomcat web application. Note that the sub-elements ofthis element should be as in the given order in a sequence.
<xs:element name="web-app" type="tomcat:web-appType"><xs:annotation><xs:documentation>The web-app element is the root of the deployment descriptor for
a Geronimo tomcat web application. Note that the sub-elements of
this element should be as in the given order in a sequence.</xs:documentation></xs:annotation></xs:element>
This is the first part of the URL used to access the web application. For example context-root of "Sample-App" will have URL of http://host:port/Sample-App" and a context-root of "/" would make this the default web application to the server. If the web application is packaged as an EAR that can use application context in the "application.xml". This element is necessary unless you want context root to default to the WAR name.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="context-root" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>This is the first part of the URL used to access the web
application. For example context-root of "Sample-App"
will have URL of http://host:port/Sample-App" and a
context-root of "/" would make this the default web
application to the server.
If the web application is packaged as an EAR that can
use application context in the "application.xml". This
element is necessary unless you want context root to
default to the WAR name.</xs:documentation></xs:annotation></xs:element>
This is the work directory that will be used by thisapplication. The directory location will be relativeto "catalina.home".
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="work-dir" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>This is the work directory that will be used by this
application. The directory location will be relative
to "catalina.home".</xs:documentation></xs:annotation></xs:element>
The host element maps the web application to thisparticular host name.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="host" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The host element maps the web application to this
particular host name.</xs:documentation></xs:annotation></xs:element>
The cross-context is an indicative element to specifythat the web application will use dispatch request toother applications and this cross context should beenabled.
<xs:element name="cross-context" type="tomcat:emptyType" minOccurs="0"><xs:annotation><xs:documentation>The cross-context is an indicative element to specify
that the web application will use dispatch request to
other applications and this cross context should be
enabled.</xs:documentation></xs:annotation></xs:element>
<xs:element name="disable-cookies" type="tomcat:emptyType" minOccurs="0"><xs:annotation><xs:documentation>The presence of disable-cookies element indicates the
cookies will not be used by tomcat web application and
should be disabled.</xs:documentation></xs:annotation></xs:element>
The valve-chain provides the list of first elementtomcat valves chain for this web application.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="valve-chain" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The valve-chain provides the list of first element
tomcat valves chain for this web application.</xs:documentation></xs:annotation></xs:element>
The listener-chain provides the list of first elementtomcat lifecycle listener chain for this web application.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="listener-chain" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The listener-chain provides the list of first element
tomcat lifecycle listener chain for this web application.</xs:documentation></xs:annotation></xs:element>
The tomcat-realm provides the tomcat security realm usedby this web application.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="tomcat-realm" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The tomcat-realm provides the tomcat security realm used
by this web application.</xs:documentation></xs:annotation></xs:element>
The manager provides the clustering implementation usedby this web application.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="manager" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The manager provides the clustering implementation used
by this web application.</xs:documentation></xs:annotation></xs:element>
The cluster provides the name of cluster this webapplication belongs to.
Diagram
Type
xs:string
Properties
content:
simple
minOccurs:
0
Source
<xs:element name="cluster" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The cluster provides the name of cluster this web
application belongs to.</xs:documentation></xs:annotation></xs:element>
The security-realm-name element provides the name ofsecurity realm that will be used by JAASauthentication. The name should match the yoursecurity realm GBean.
Diagram
Type
xs:string
Properties
content:
simple
Source
<xs:element name="security-realm-name" type="xs:string"><xs:annotation><xs:documentation>The security-realm-name element provides the name of
security realm that will be used by JAAS
authentication. The name should match the your
security realm GBean.</xs:documentation></xs:annotation></xs:element>
<xsd:element name="persistence"><xsd:complexType><xsd:sequence><!-- **************************************************** --><xsd:element name="persistence-unit" minOccurs="0" maxOccurs="unbounded"><xsd:complexType><xsd:annotation><xsd:documentation>Configuration of a persistence unit.</xsd:documentation></xsd:annotation><xsd:sequence><!-- **************************************************** --><xsd:element name="description" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Textual description of this persistence unit.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="provider" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Provider class that supplies EntityManagers for this
persistence unit.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of the JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="non-jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of a non-JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="mapping-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>File containing mapping information. Loaded as a resource
by the persistence provider.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="jar-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Jar file that should be scanned for entities.
Not applicable to Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="class" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Class to scan for annotations. It should be annotated
with either @Entity, @Embeddable or @MappedSuperclass.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="exclude-unlisted-classes" type="xsd:boolean" default="false" minOccurs="0"><xsd:annotation><xsd:documentation>When set to true then only listed classes and jars will
be scanned for persistent classes, otherwise the enclosing
jar or directory will also be scanned. Not applicable to
Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="properties" minOccurs="0"><xsd:annotation><xsd:documentation>A list of vendor-specific properties.</xsd:documentation></xsd:annotation><xsd:complexType><xsd:sequence><xsd:element name="property" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>A name-value pair.</xsd:documentation></xsd:annotation><xsd:complexType><xsd:attribute name="name" type="xsd:string" use="required"/><xsd:attribute name="value" type="xsd:string" use="required"/></xsd:complexType></xsd:element></xsd:sequence></xsd:complexType></xsd:element></xsd:sequence><!-- **************************************************** --><xsd:attribute name="name" type="xsd:string" use="required"><xsd:annotation><xsd:documentation>Name used in code to reference this persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute><!-- **************************************************** --><xsd:attribute name="transaction-type" type="persistence:persistence-unit-transaction-type"><xsd:annotation><xsd:documentation>Type of transactions used by EntityManagers from this
persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute></xsd:complexType></xsd:element></xsd:sequence><xsd:attribute name="version" type="persistence:versionType" fixed="1.0" use="required"/></xsd:complexType></xsd:element>
Type of transactions used by EntityManagers from this persistence unit.
Source
<xsd:element name="persistence-unit" minOccurs="0" maxOccurs="unbounded"><xsd:complexType><xsd:annotation><xsd:documentation>Configuration of a persistence unit.</xsd:documentation></xsd:annotation><xsd:sequence><!-- **************************************************** --><xsd:element name="description" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Textual description of this persistence unit.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="provider" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Provider class that supplies EntityManagers for this
persistence unit.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of the JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="non-jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of a non-JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="mapping-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>File containing mapping information. Loaded as a resource
by the persistence provider.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="jar-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Jar file that should be scanned for entities.
Not applicable to Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="class" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Class to scan for annotations. It should be annotated
with either @Entity, @Embeddable or @MappedSuperclass.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="exclude-unlisted-classes" type="xsd:boolean" default="false" minOccurs="0"><xsd:annotation><xsd:documentation>When set to true then only listed classes and jars will
be scanned for persistent classes, otherwise the enclosing
jar or directory will also be scanned. Not applicable to
Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element><!-- **************************************************** --><xsd:element name="properties" minOccurs="0"><xsd:annotation><xsd:documentation>A list of vendor-specific properties.</xsd:documentation></xsd:annotation><xsd:complexType><xsd:sequence><xsd:element name="property" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>A name-value pair.</xsd:documentation></xsd:annotation><xsd:complexType><xsd:attribute name="name" type="xsd:string" use="required"/><xsd:attribute name="value" type="xsd:string" use="required"/></xsd:complexType></xsd:element></xsd:sequence></xsd:complexType></xsd:element></xsd:sequence><!-- **************************************************** --><xsd:attribute name="name" type="xsd:string" use="required"><xsd:annotation><xsd:documentation>Name used in code to reference this persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute><!-- **************************************************** --><xsd:attribute name="transaction-type" type="persistence:persistence-unit-transaction-type"><xsd:annotation><xsd:documentation>Type of transactions used by EntityManagers from this
persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute></xsd:complexType></xsd:element>
<xsd:element name="description" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Textual description of this persistence unit.</xsd:documentation></xsd:annotation></xsd:element>
Provider class that supplies EntityManagers for this persistence unit.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
Source
<xsd:element name="provider" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>Provider class that supplies EntityManagers for this
persistence unit.</xsd:documentation></xsd:annotation></xsd:element>
The container-specific name of the JTA datasource to use.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
Source
<xsd:element name="jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of the JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element>
The container-specific name of a non-JTA datasource to use.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
Source
<xsd:element name="non-jta-data-source" type="xsd:string" minOccurs="0"><xsd:annotation><xsd:documentation>The container-specific name of a non-JTA datasource to use.</xsd:documentation></xsd:annotation></xsd:element>
File containing mapping information. Loaded as a resource by the persistence provider.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
maxOccurs:
unbounded
Source
<xsd:element name="mapping-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>File containing mapping information. Loaded as a resource
by the persistence provider.</xsd:documentation></xsd:annotation></xsd:element>
Jar file that should be scanned for entities. Not applicable to Java SE persistence units.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
maxOccurs:
unbounded
Source
<xsd:element name="jar-file" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Jar file that should be scanned for entities.
Not applicable to Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element>
Class to scan for annotations. It should be annotated with either @Entity, @Embeddable or @MappedSuperclass.
Diagram
Type
xsd:string
Properties
content:
simple
minOccurs:
0
maxOccurs:
unbounded
Source
<xsd:element name="class" type="xsd:string" minOccurs="0" maxOccurs="unbounded"><xsd:annotation><xsd:documentation>Class to scan for annotations. It should be annotated
with either @Entity, @Embeddable or @MappedSuperclass.</xsd:documentation></xsd:annotation></xsd:element>
When set to true then only listed classes and jars will be scanned for persistent classes, otherwise the enclosing jar or directory will also be scanned. Not applicable to Java SE persistence units.
Diagram
Type
xsd:boolean
Properties
content:
simple
minOccurs:
0
default:
false
Source
<xsd:element name="exclude-unlisted-classes" type="xsd:boolean" default="false" minOccurs="0"><xsd:annotation><xsd:documentation>When set to true then only listed classes and jars will
be scanned for persistent classes, otherwise the enclosing
jar or directory will also be scanned. Not applicable to
Java SE persistence units.</xsd:documentation></xsd:annotation></xsd:element>
<xs:complexType name="web-appType"><xs:sequence><xs:element ref="sys:environment" minOccurs="0"><xs:annotation><xs:documentation>Reference to environment element defined in imported
"geronimo-module-1.2.xsd"</xs:documentation></xs:annotation></xs:element><xs:element name="context-root" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>This is the first part of the URL used to access the web
application. For example context-root of "Sample-App"
will have URL of http://host:port/Sample-App" and a
context-root of "/" would make this the default web
application to the server.
If the web application is packaged as an EAR that can
use application context in the "application.xml". This
element is necessary unless you want context root to
default to the WAR name.</xs:documentation></xs:annotation></xs:element><xs:element name="work-dir" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>This is the work directory that will be used by this
application. The directory location will be relative
to "catalina.home".</xs:documentation></xs:annotation></xs:element><xs:element ref="app:clustering" minOccurs="0"><xs:annotation><xs:documentation>Reference to abstract clustering element defined in
imported "geronimo-application-2.0.xsd"</xs:documentation></xs:annotation></xs:element><!--<xs:element name="context-priority-classloader" type="xs:boolean" minOccurs="0"/>--><xs:element ref="naming:web-container" minOccurs="0"><xs:annotation><xs:documentation>Reference to web-container element defined in imported
"geronimo-naming-1.2.xsd"</xs:documentation></xs:annotation></xs:element><xs:element name="host" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The host element maps the web application to this
particular host name.</xs:documentation></xs:annotation></xs:element><xs:element name="cross-context" type="tomcat:emptyType" minOccurs="0"><xs:annotation><xs:documentation>The cross-context is an indicative element to specify
that the web application will use dispatch request to
other applications and this cross context should be
enabled.</xs:documentation></xs:annotation></xs:element><xs:element name="disable-cookies" type="tomcat:emptyType" minOccurs="0"><xs:annotation><xs:documentation>The presence of disable-cookies element indicates the
cookies will not be used by tomcat web application and
should be disabled.</xs:documentation></xs:annotation></xs:element><xs:element name="valve-chain" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The valve-chain provides the list of first element
tomcat valves chain for this web application.</xs:documentation></xs:annotation></xs:element><xs:element name="listener-chain" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The listener-chain provides the list of first element
tomcat lifecycle listener chain for this web application.</xs:documentation></xs:annotation></xs:element><xs:element name="tomcat-realm" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The tomcat-realm provides the tomcat security realm used
by this web application.</xs:documentation></xs:annotation></xs:element><xs:element name="manager" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The manager provides the clustering implementation used
by this web application.</xs:documentation></xs:annotation></xs:element><xs:element name="cluster" type="xs:string" minOccurs="0"><xs:annotation><xs:documentation>The cluster provides the name of cluster this web
application belongs to.</xs:documentation></xs:annotation></xs:element><xs:group ref="naming:jndiEnvironmentRefsGroup"><xs:annotation><xs:documentation>Reference to jndiEnvironmentRefsGroup group defined in
imported "geronimo-naming-1.2.xsd"</xs:documentation></xs:annotation></xs:group><xs:element ref="naming:message-destination" minOccurs="0" maxOccurs="unbounded"><xs:annotation><xs:documentation>Reference to message-destination element defined in
imported "geronimo-naming-1.2.xsd"</xs:documentation></xs:annotation></xs:element><xs:sequence minOccurs="0"><xs:element name="security-realm-name" type="xs:string"><xs:annotation><xs:documentation>The security-realm-name element provides the name of
security realm that will be used by JAAS
authentication. The name should match the your
security realm GBean.</xs:documentation></xs:annotation></xs:element><xs:element ref="app:security" minOccurs="0"><xs:annotation><xs:documentation>Reference to security element defined in imported
"geronimo-security-2.0.xsd"</xs:documentation></xs:annotation></xs:element></xs:sequence><xs:choice minOccurs="0" maxOccurs="unbounded"><xs:element ref="sys:service" minOccurs="0" maxOccurs="unbounded"><xs:annotation><xs:documentation>Reference to abstract service element defined in imported
"geronimo-module-1.2.xsd"</xs:documentation></xs:annotation></xs:element><xs:element ref="ee:persistence"/></xs:choice></xs:sequence></xs:complexType>
<xsd:attribute name="name" type="xsd:string" use="required"><xsd:annotation><xsd:documentation>Name used in code to reference this persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute>
<xsd:attribute name="transaction-type" type="persistence:persistence-unit-transaction-type"><xsd:annotation><xsd:documentation>Type of transactions used by EntityManagers from this
persistence unit.</xsd:documentation></xsd:annotation></xsd:attribute>