You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by an...@apache.org on 2015/12/09 17:37:10 UTC

[01/18] tomee git commit: EOL

Repository: tomee
Updated Branches:
  refs/heads/tomee-1.7.x c60044225 -> 48c99a5a5


http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceRef.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceRef.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceRef.java
index 6b11fd3..12397b7 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceRef.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceRef.java
@@ -1,417 +1,417 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The resource-refType contains a declaration of a Deployment Component's
- * reference to an external resource. It consists of an optional description,
- * the resource manager connection factory reference name, the indication of the
- * resource manager connection factory type expected by the Deployment Component
- * code, the type of authentication (Application or Container), and an optional
- * specification of the shareability of connections obtained from the resource
- * (Shareable or Unshareable).
- * <p/>
- * Example:
- * <p/>
- * <p/>
- * <pre>
- * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;resource-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;res-ref-name&gt;jdbc/EmployeeAppDB&lt;/res-ref-name&gt;&lt;res-type&gt;javax.sql.DataSource&lt;/res-type&gt;&lt;res-auth&gt;Container&lt;/res-auth&gt;&lt;res-sharing-scope&gt;Shareable&lt;/res-sharing-scope&gt;
- *
- * 				&lt;/resource-ref&gt;
- * </pre>
- * <p/>
- * <p/>
- * <p/>
- * <p/>
- * Java class for ResourceRef complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="ResourceRef">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="auth" type="{common.xmi}ResAuthTypeBase" />
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="resSharingScope" type="{common.xmi}ResSharingScopeType" />
- *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "ResourceRef", propOrder = {"descriptions", "extensions"})
-public class ResourceRef {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected ResAuthEnum auth;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String link;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected ResSharingScopeEnum resSharingScope;
-    @XmlAttribute(name = "type")
-    protected String resourceRefTypeString;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the auth property.
-     *
-     * @return possible object is {@link ResAuthEnum }
-     */
-    public ResAuthEnum getAuth() {
-        return auth;
-    }
-
-    /**
-     * Sets the value of the auth property.
-     *
-     * @param value allowed object is {@link ResAuthEnum }
-     */
-    public void setAuth(final ResAuthEnum value) {
-        this.auth = value;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the link property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLink() {
-        return link;
-    }
-
-    /**
-     * Sets the value of the link property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLink(final String value) {
-        this.link = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the resSharingScope property.
-     *
-     * @return possible object is {@link ResSharingScopeEnum }
-     */
-    public ResSharingScopeEnum getResSharingScope() {
-        return resSharingScope;
-    }
-
-    /**
-     * Sets the value of the resSharingScope property.
-     *
-     * @param value allowed object is {@link ResSharingScopeEnum }
-     */
-    public void setResSharingScope(final ResSharingScopeEnum value) {
-        this.resSharingScope = value;
-    }
-
-    /**
-     * Gets the value of the resourceRefTypeString property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getResourceRefTypeString() {
-        return resourceRefTypeString;
-    }
-
-    /**
-     * Sets the value of the resourceRefTypeString property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setResourceRefTypeString(final String value) {
-        this.resourceRefTypeString = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * The resource-refType contains a declaration of a Deployment Component's
+ * reference to an external resource. It consists of an optional description,
+ * the resource manager connection factory reference name, the indication of the
+ * resource manager connection factory type expected by the Deployment Component
+ * code, the type of authentication (Application or Container), and an optional
+ * specification of the shareability of connections obtained from the resource
+ * (Shareable or Unshareable).
+ * <p/>
+ * Example:
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;resource-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;res-ref-name&gt;jdbc/EmployeeAppDB&lt;/res-ref-name&gt;&lt;res-type&gt;javax.sql.DataSource&lt;/res-type&gt;&lt;res-auth&gt;Container&lt;/res-auth&gt;&lt;res-sharing-scope&gt;Shareable&lt;/res-sharing-scope&gt;
+ *
+ * 				&lt;/resource-ref&gt;
+ * </pre>
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for ResourceRef complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="ResourceRef">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="auth" type="{common.xmi}ResAuthTypeBase" />
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="resSharingScope" type="{common.xmi}ResSharingScopeType" />
+ *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "ResourceRef", propOrder = {"descriptions", "extensions"})
+public class ResourceRef {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected ResAuthEnum auth;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String link;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected ResSharingScopeEnum resSharingScope;
+    @XmlAttribute(name = "type")
+    protected String resourceRefTypeString;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the auth property.
+     *
+     * @return possible object is {@link ResAuthEnum }
+     */
+    public ResAuthEnum getAuth() {
+        return auth;
+    }
+
+    /**
+     * Sets the value of the auth property.
+     *
+     * @param value allowed object is {@link ResAuthEnum }
+     */
+    public void setAuth(final ResAuthEnum value) {
+        this.auth = value;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the link property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLink() {
+        return link;
+    }
+
+    /**
+     * Sets the value of the link property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLink(final String value) {
+        this.link = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the resSharingScope property.
+     *
+     * @return possible object is {@link ResSharingScopeEnum }
+     */
+    public ResSharingScopeEnum getResSharingScope() {
+        return resSharingScope;
+    }
+
+    /**
+     * Sets the value of the resSharingScope property.
+     *
+     * @param value allowed object is {@link ResSharingScopeEnum }
+     */
+    public void setResSharingScope(final ResSharingScopeEnum value) {
+        this.resSharingScope = value;
+    }
+
+    /**
+     * Gets the value of the resourceRefTypeString property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getResourceRefTypeString() {
+        return resourceRefTypeString;
+    }
+
+    /**
+     * Sets the value of the resourceRefTypeString property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setResourceRefTypeString(final String value) {
+        this.resourceRefTypeString = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/RunAsSpecifiedIdentity.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/RunAsSpecifiedIdentity.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/RunAsSpecifiedIdentity.java
index f14a492..bfe6100 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/RunAsSpecifiedIdentity.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/RunAsSpecifiedIdentity.java
@@ -1,86 +1,86 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlType;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The security-identity element specifies whether the caller's security
- * identity is to be used for the execution of the methods of the enterprise
- * bean or whether a specific run-as identity is to be used. It contains an
- * optional description and a specification of the security identity to be used.
- * <p/>
- * <p/>
- * <p/>
- * Java class for RunAsSpecifiedIdentity complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="RunAsSpecifiedIdentity">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}SecurityIdentity">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element name="identity" type="{common.xmi}Identity"/>
- *       &lt;/choice>
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "RunAsSpecifiedIdentity", propOrder = {"identities"})
-public class RunAsSpecifiedIdentity extends SecurityIdentity {
-
-    @XmlElement(name = "identity")
-    protected List<Identity> identities;
-
-    /**
-     * Gets the value of the identities property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the identities property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getIdentities().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list {@link Identity }
-     */
-    public List<Identity> getIdentities() {
-        if (identities == null) {
-            identities = new ArrayList<Identity>();
-        }
-        return this.identities;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * The security-identity element specifies whether the caller's security
+ * identity is to be used for the execution of the methods of the enterprise
+ * bean or whether a specific run-as identity is to be used. It contains an
+ * optional description and a specification of the security identity to be used.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for RunAsSpecifiedIdentity complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="RunAsSpecifiedIdentity">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}SecurityIdentity">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element name="identity" type="{common.xmi}Identity"/>
+ *       &lt;/choice>
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "RunAsSpecifiedIdentity", propOrder = {"identities"})
+public class RunAsSpecifiedIdentity extends SecurityIdentity {
+
+    @XmlElement(name = "identity")
+    protected List<Identity> identities;
+
+    /**
+     * Gets the value of the identities property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the identities property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getIdentities().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list {@link Identity }
+     */
+    public List<Identity> getIdentities() {
+        if (identities == null) {
+            identities = new ArrayList<Identity>();
+        }
+        return this.identities;
+    }
+
+}


[13/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/util/NetworkUtil.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/util/NetworkUtil.java b/container/openejb-core/src/main/java/org/apache/openejb/util/NetworkUtil.java
index dc0a04e..9c72d5f 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/util/NetworkUtil.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/util/NetworkUtil.java
@@ -1,434 +1,434 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.util;
-
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.IOException;
-import java.io.RandomAccessFile;
-import java.net.InetAddress;
-import java.net.NetworkInterface;
-import java.net.ServerSocket;
-import java.net.SocketException;
-import java.nio.ByteBuffer;
-import java.nio.channels.FileChannel;
-import java.nio.channels.FileLock;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.Properties;
-import java.util.Set;
-import java.util.concurrent.locks.ReentrantLock;
-
-/**
- * TODO: this class is no more an utility class (static)
- * and should be rewritten to get a config + state
- * -> listOfPorts with release(port) method (otherwise caching makes half of usages broken)
- * -> lockFile
- * -> minPort/maxPort
- * -> ...
- */
-public final class NetworkUtil {
-
-    /**
-     * Lock file property name
-     */
-    public static final String TOMEE_LOCK_FILE = "TOMEE_LOCK_FILE";
-    public static final int[] RANDOM = new int[]{0};
-
-    private static final ReentrantLock lock = new ReentrantLock();
-    private static final ByteBuffer buf = ByteBuffer.allocate(512);
-    public static final int PORT_MIN = 1025;
-    public static final int PORT_MAX = 65535;
-    public static final int EVICTION_TIMEOUT = Integer.getInteger("openejb.network.random-port.cache-timeout", 10000);
-    private static File lockFile;
-
-    private NetworkUtil() {
-        // no-op
-    }
-
-    public static synchronized void clearLockFile() {
-        System.clearProperty(NetworkUtil.TOMEE_LOCK_FILE);
-        lockFile = null;
-    }
-
-    public static synchronized int getNextAvailablePortInDefaultRange() {
-        final ReentrantLock l = lock;
-        l.lock();
-        try {
-            return getNextAvailablePort(PORT_MIN, PORT_MAX, null);
-        } finally {
-            l.unlock();
-        }
-    }
-
-    // fully random by default to avoid to get PORT_MIN, PORT_MIN, PORT_MIN locally/on a dev machine
-    public static synchronized int getNextAvailablePort() {
-        final ReentrantLock l = lock;
-        l.lock();
-        try {
-            return getNextAvailablePort(RANDOM);
-        } finally {
-            l.unlock();
-        }
-    }
-
-    public static synchronized int getNextAvailablePort(final int[] portList) {
-
-        final ReentrantLock l = lock;
-        l.lock();
-
-        final int originalRetryCount = Integer.getInteger("openejb.network.random-port.retries", 10);
-        int retry = originalRetryCount;
-        ServerSocket s = null;
-        try {
-            do {
-                try {
-                    s = create(portList, null);
-                    return s.getLocalPort();
-                } catch (final IOException ioe) {
-                    // particular case where iteration is not really the meaning of the config
-                    final boolean isRandom = portList == RANDOM || (portList.length == 1 && portList[0] == 0);
-                    if (isRandom) {
-                        retry--;
-                    } else { // otherwise infinite loop
-                        retry = 0;
-                    }
-                    if (retry <= 0) { // 0 retry -> -1
-                        throw new IllegalStateException("Failed to find a port matching list " + Arrays.toString(portList) + (isRandom ? " with " + originalRetryCount + " retries" : ""));
-                    }
-                } finally {
-                    if (s != null) {
-                        try {
-                            s.close();
-                        } catch (final Throwable e) {
-                            //Ignore
-                        }
-                    }
-                }
-            } while (true);
-        } finally {
-            l.unlock();
-        }
-    }
-
-    public static synchronized int getNextAvailablePort(final int min, final int max, final Collection<Integer> excluded, final Collection<LastPort> lastPorts) {
-        final ReentrantLock l = lock;
-        l.lock();
-
-        try {
-            purgeLast(lastPorts);
-            int port = -1;
-            ServerSocket s = null;
-            for (int i = min; i <= max; i++) {
-
-                if (excluded != null && excluded.contains(i) || i > PORT_MAX || i < PORT_MIN) {
-                    continue;
-                }
-
-                try {
-                    s = create(new int[]{i}, lastPorts);
-                    port = s.getLocalPort();
-                    break;
-
-                } catch (final IOException ioe) {
-                    port = -1;
-                } finally {
-                    if (s != null) {
-                        try {
-                            s.close();
-                        } catch (final Throwable e) {
-                            //Ignore
-                        }
-                    }
-                }
-            }
-
-            return port;
-        } finally {
-            l.unlock();
-        }
-    }
-
-    public static synchronized int getNextAvailablePort(final int min, final int max, final Collection<Integer> excluded) {
-        return getNextAvailablePort(min, max, excluded, null);
-    }
-
-    private static void purgeLast(final Collection<LastPort> lastPort) {
-        if (lastPort == null) {
-            return;
-        }
-        final Iterator<LastPort> it = lastPort.iterator();
-        while (it.hasNext()) {
-            final LastPort last = it.next();
-            if ((System.currentTimeMillis() - last.time) >= EVICTION_TIMEOUT) {
-                it.remove();
-            }
-        }
-    }
-
-    private static ServerSocket create(final int[] ports, final Collection<LastPort> lastPort) throws IOException {
-
-        for (int port : ports) {
-            try {
-
-                final ServerSocket ss = new ServerSocket(port);
-                port = ss.getLocalPort();
-
-                final LastPort lp = new LastPort(port, System.currentTimeMillis());
-
-                if (lastPort != null) {
-                    if (lastPort.contains(lp)) {
-                        try {
-                            ss.close();
-                        } catch (final Exception e) {
-                            //Ignore
-                        }
-                        continue;
-                    }
-                }
-
-                if (!checkLockFile(port)) {
-                    try {
-                        ss.close();
-                    } catch (final Exception e) {
-                        //Ignore
-                    }
-                    continue;
-                }
-
-                if (lastPort != null) {
-                    lastPort.add(lp);
-                }
-
-                return ss;
-
-            } catch (final IOException ex) {
-                // try next port
-            }
-        }
-
-        // If the program gets here, no port in the range was found
-        throw new IOException("No free port found");
-    }
-
-    private static File getLockFile() {
-
-        if (null == lockFile) {
-            String lf = System.getenv("TOMEE_LOCK_FILE");
-            lf = (null != lf ? lf : System.getProperty("TOMEE_LOCK_FILE"));
-
-            if (null != lf) {
-                final File f = new File(lf);
-                try {
-                    lockFile = (!f.exists() && !f.createNewFile() ? null : (f.isFile() ? f : null));
-                } catch (final IOException e) {
-                    //Ignore
-                }
-            }
-        }
-
-        return lockFile;
-    }
-
-    /**
-     * If a lockfile exists then see if we can really reserve this port
-     *
-     * @param port int
-     * @return true if we can reserve else false
-     */
-    private static boolean checkLockFile(final int port) {
-
-        boolean result = true;
-
-        final File lf = getLockFile();
-        if (null != lf) {
-
-            final Properties p = new Properties();
-            RandomAccessFile raf = null;
-            ByteArrayOutputStream baos = null;
-            ByteArrayInputStream bais = null;
-            FileLock lock = null;
-
-            try {
-
-                raf = new RandomAccessFile(lf, "rw");
-                final FileChannel fileChannel = raf.getChannel();
-
-                int i = 0;
-                while ((lock = fileChannel.tryLock()) == null) {
-                    Thread.sleep(10);
-                    i++;
-
-                    if (i > 200) {
-                        return false;
-                    }
-                }
-
-                baos = new ByteArrayOutputStream();
-
-                while (fileChannel.read(buf) > 0) {
-                    baos.write((byte[]) buf.flip().array());
-                    buf.clear();
-                }
-
-                bais = new ByteArrayInputStream(baos.toByteArray());
-                p.load(bais);
-
-                final boolean purged = purgeOld(p);
-
-                if (null != p.getProperty(String.valueOf(port))) {
-                    result = false;
-                    //System.out.println("Locked " + port);
-                } else {
-                    p.setProperty(String.valueOf(port), String.valueOf(System.currentTimeMillis()));
-                    //System.out.println("Reserved " + port);
-                }
-
-                if (result || purged) {
-                    baos.reset();
-                    p.store(baos, "TomEE port locks");
-                    fileChannel.truncate(0);
-                    fileChannel.write(ByteBuffer.wrap(baos.toByteArray()));
-                }
-
-            } catch (final Exception e) {
-                result = false;
-            } finally {
-                if (null != lock) {
-                    try {
-                        lock.release();
-                    } catch (final Exception e) {
-                        //Ignore
-                    }
-                }
-                if (null != baos) {
-                    try {
-                        baos.close();
-                    } catch (final Exception e) {
-                        //Ignore
-                    }
-                }
-                if (null != bais) {
-                    try {
-                        bais.close();
-                    } catch (final Exception e) {
-                        //Ignore
-                    }
-                }
-                if (null != raf) {
-                    try {
-                        raf.close();
-                    } catch (final Exception e) {
-                        //Ignore
-                    }
-                }
-            }
-        }
-
-        return result;
-    }
-
-    /**
-     * Purge keys (ports) older than 30 seconds
-     *
-     * @param p Properties
-     */
-    private static boolean purgeOld(final Properties p) {
-
-        boolean purged = false;
-        final long now = System.currentTimeMillis();
-        final Set<String> names = p.stringPropertyNames();
-
-        for (final String key : names) {
-            final String value = p.getProperty(key);
-
-            if (isOld(now, value)) {
-                purged = true;
-                p.remove(key);
-            }
-        }
-
-        return purged;
-    }
-
-    private static boolean isOld(final long now, final String value) {
-        try {
-            return now - Long.parseLong(value) > 30000;
-        } catch (final Exception e) {
-            return true;
-        }
-    }
-
-    public static String getLocalAddress(final String start, final String end) {
-        return start + "localhost:" + getNextAvailablePort() + end;
-    }
-
-    public static boolean isLocalAddress(final String addr) {
-        try {
-            return isLocalAddress(InetAddress.getByName(addr));
-        } catch (final Exception e) {
-            return false;
-        }
-    }
-
-    public static boolean isLocalAddress(final InetAddress addr) {
-
-        if (addr.isAnyLocalAddress() || addr.isLoopbackAddress()) {
-            return true;
-        }
-
-        // Check if the address is defined on any interface
-        try {
-            return NetworkInterface.getByInetAddress(addr) != null;
-        } catch (final SocketException e) {
-            return false;
-        }
-    }
-
-    public static final class LastPort {
-        private final int port;
-        private final long time;
-
-        private LastPort(final int port, final long time) {
-            this.port = port;
-            this.time = time;
-        }
-
-        @Override
-        public boolean equals(final Object o) {
-            if (this == o) {
-                return true;
-            }
-            if (o == null || getClass() != o.getClass()) {
-                return false;
-            }
-
-            final LastPort lastPort = (LastPort) o;
-
-            return port == lastPort.port;
-
-        }
-
-        @Override
-        public int hashCode() {
-            return port;
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.util;
+
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.RandomAccessFile;
+import java.net.InetAddress;
+import java.net.NetworkInterface;
+import java.net.ServerSocket;
+import java.net.SocketException;
+import java.nio.ByteBuffer;
+import java.nio.channels.FileChannel;
+import java.nio.channels.FileLock;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Properties;
+import java.util.Set;
+import java.util.concurrent.locks.ReentrantLock;
+
+/**
+ * TODO: this class is no more an utility class (static)
+ * and should be rewritten to get a config + state
+ * -> listOfPorts with release(port) method (otherwise caching makes half of usages broken)
+ * -> lockFile
+ * -> minPort/maxPort
+ * -> ...
+ */
+public final class NetworkUtil {
+
+    /**
+     * Lock file property name
+     */
+    public static final String TOMEE_LOCK_FILE = "TOMEE_LOCK_FILE";
+    public static final int[] RANDOM = new int[]{0};
+
+    private static final ReentrantLock lock = new ReentrantLock();
+    private static final ByteBuffer buf = ByteBuffer.allocate(512);
+    public static final int PORT_MIN = 1025;
+    public static final int PORT_MAX = 65535;
+    public static final int EVICTION_TIMEOUT = Integer.getInteger("openejb.network.random-port.cache-timeout", 10000);
+    private static File lockFile;
+
+    private NetworkUtil() {
+        // no-op
+    }
+
+    public static synchronized void clearLockFile() {
+        System.clearProperty(NetworkUtil.TOMEE_LOCK_FILE);
+        lockFile = null;
+    }
+
+    public static synchronized int getNextAvailablePortInDefaultRange() {
+        final ReentrantLock l = lock;
+        l.lock();
+        try {
+            return getNextAvailablePort(PORT_MIN, PORT_MAX, null);
+        } finally {
+            l.unlock();
+        }
+    }
+
+    // fully random by default to avoid to get PORT_MIN, PORT_MIN, PORT_MIN locally/on a dev machine
+    public static synchronized int getNextAvailablePort() {
+        final ReentrantLock l = lock;
+        l.lock();
+        try {
+            return getNextAvailablePort(RANDOM);
+        } finally {
+            l.unlock();
+        }
+    }
+
+    public static synchronized int getNextAvailablePort(final int[] portList) {
+
+        final ReentrantLock l = lock;
+        l.lock();
+
+        final int originalRetryCount = Integer.getInteger("openejb.network.random-port.retries", 10);
+        int retry = originalRetryCount;
+        ServerSocket s = null;
+        try {
+            do {
+                try {
+                    s = create(portList, null);
+                    return s.getLocalPort();
+                } catch (final IOException ioe) {
+                    // particular case where iteration is not really the meaning of the config
+                    final boolean isRandom = portList == RANDOM || (portList.length == 1 && portList[0] == 0);
+                    if (isRandom) {
+                        retry--;
+                    } else { // otherwise infinite loop
+                        retry = 0;
+                    }
+                    if (retry <= 0) { // 0 retry -> -1
+                        throw new IllegalStateException("Failed to find a port matching list " + Arrays.toString(portList) + (isRandom ? " with " + originalRetryCount + " retries" : ""));
+                    }
+                } finally {
+                    if (s != null) {
+                        try {
+                            s.close();
+                        } catch (final Throwable e) {
+                            //Ignore
+                        }
+                    }
+                }
+            } while (true);
+        } finally {
+            l.unlock();
+        }
+    }
+
+    public static synchronized int getNextAvailablePort(final int min, final int max, final Collection<Integer> excluded, final Collection<LastPort> lastPorts) {
+        final ReentrantLock l = lock;
+        l.lock();
+
+        try {
+            purgeLast(lastPorts);
+            int port = -1;
+            ServerSocket s = null;
+            for (int i = min; i <= max; i++) {
+
+                if (excluded != null && excluded.contains(i) || i > PORT_MAX || i < PORT_MIN) {
+                    continue;
+                }
+
+                try {
+                    s = create(new int[]{i}, lastPorts);
+                    port = s.getLocalPort();
+                    break;
+
+                } catch (final IOException ioe) {
+                    port = -1;
+                } finally {
+                    if (s != null) {
+                        try {
+                            s.close();
+                        } catch (final Throwable e) {
+                            //Ignore
+                        }
+                    }
+                }
+            }
+
+            return port;
+        } finally {
+            l.unlock();
+        }
+    }
+
+    public static synchronized int getNextAvailablePort(final int min, final int max, final Collection<Integer> excluded) {
+        return getNextAvailablePort(min, max, excluded, null);
+    }
+
+    private static void purgeLast(final Collection<LastPort> lastPort) {
+        if (lastPort == null) {
+            return;
+        }
+        final Iterator<LastPort> it = lastPort.iterator();
+        while (it.hasNext()) {
+            final LastPort last = it.next();
+            if ((System.currentTimeMillis() - last.time) >= EVICTION_TIMEOUT) {
+                it.remove();
+            }
+        }
+    }
+
+    private static ServerSocket create(final int[] ports, final Collection<LastPort> lastPort) throws IOException {
+
+        for (int port : ports) {
+            try {
+
+                final ServerSocket ss = new ServerSocket(port);
+                port = ss.getLocalPort();
+
+                final LastPort lp = new LastPort(port, System.currentTimeMillis());
+
+                if (lastPort != null) {
+                    if (lastPort.contains(lp)) {
+                        try {
+                            ss.close();
+                        } catch (final Exception e) {
+                            //Ignore
+                        }
+                        continue;
+                    }
+                }
+
+                if (!checkLockFile(port)) {
+                    try {
+                        ss.close();
+                    } catch (final Exception e) {
+                        //Ignore
+                    }
+                    continue;
+                }
+
+                if (lastPort != null) {
+                    lastPort.add(lp);
+                }
+
+                return ss;
+
+            } catch (final IOException ex) {
+                // try next port
+            }
+        }
+
+        // If the program gets here, no port in the range was found
+        throw new IOException("No free port found");
+    }
+
+    private static File getLockFile() {
+
+        if (null == lockFile) {
+            String lf = System.getenv("TOMEE_LOCK_FILE");
+            lf = (null != lf ? lf : System.getProperty("TOMEE_LOCK_FILE"));
+
+            if (null != lf) {
+                final File f = new File(lf);
+                try {
+                    lockFile = (!f.exists() && !f.createNewFile() ? null : (f.isFile() ? f : null));
+                } catch (final IOException e) {
+                    //Ignore
+                }
+            }
+        }
+
+        return lockFile;
+    }
+
+    /**
+     * If a lockfile exists then see if we can really reserve this port
+     *
+     * @param port int
+     * @return true if we can reserve else false
+     */
+    private static boolean checkLockFile(final int port) {
+
+        boolean result = true;
+
+        final File lf = getLockFile();
+        if (null != lf) {
+
+            final Properties p = new Properties();
+            RandomAccessFile raf = null;
+            ByteArrayOutputStream baos = null;
+            ByteArrayInputStream bais = null;
+            FileLock lock = null;
+
+            try {
+
+                raf = new RandomAccessFile(lf, "rw");
+                final FileChannel fileChannel = raf.getChannel();
+
+                int i = 0;
+                while ((lock = fileChannel.tryLock()) == null) {
+                    Thread.sleep(10);
+                    i++;
+
+                    if (i > 200) {
+                        return false;
+                    }
+                }
+
+                baos = new ByteArrayOutputStream();
+
+                while (fileChannel.read(buf) > 0) {
+                    baos.write((byte[]) buf.flip().array());
+                    buf.clear();
+                }
+
+                bais = new ByteArrayInputStream(baos.toByteArray());
+                p.load(bais);
+
+                final boolean purged = purgeOld(p);
+
+                if (null != p.getProperty(String.valueOf(port))) {
+                    result = false;
+                    //System.out.println("Locked " + port);
+                } else {
+                    p.setProperty(String.valueOf(port), String.valueOf(System.currentTimeMillis()));
+                    //System.out.println("Reserved " + port);
+                }
+
+                if (result || purged) {
+                    baos.reset();
+                    p.store(baos, "TomEE port locks");
+                    fileChannel.truncate(0);
+                    fileChannel.write(ByteBuffer.wrap(baos.toByteArray()));
+                }
+
+            } catch (final Exception e) {
+                result = false;
+            } finally {
+                if (null != lock) {
+                    try {
+                        lock.release();
+                    } catch (final Exception e) {
+                        //Ignore
+                    }
+                }
+                if (null != baos) {
+                    try {
+                        baos.close();
+                    } catch (final Exception e) {
+                        //Ignore
+                    }
+                }
+                if (null != bais) {
+                    try {
+                        bais.close();
+                    } catch (final Exception e) {
+                        //Ignore
+                    }
+                }
+                if (null != raf) {
+                    try {
+                        raf.close();
+                    } catch (final Exception e) {
+                        //Ignore
+                    }
+                }
+            }
+        }
+
+        return result;
+    }
+
+    /**
+     * Purge keys (ports) older than 30 seconds
+     *
+     * @param p Properties
+     */
+    private static boolean purgeOld(final Properties p) {
+
+        boolean purged = false;
+        final long now = System.currentTimeMillis();
+        final Set<String> names = p.stringPropertyNames();
+
+        for (final String key : names) {
+            final String value = p.getProperty(key);
+
+            if (isOld(now, value)) {
+                purged = true;
+                p.remove(key);
+            }
+        }
+
+        return purged;
+    }
+
+    private static boolean isOld(final long now, final String value) {
+        try {
+            return now - Long.parseLong(value) > 30000;
+        } catch (final Exception e) {
+            return true;
+        }
+    }
+
+    public static String getLocalAddress(final String start, final String end) {
+        return start + "localhost:" + getNextAvailablePort() + end;
+    }
+
+    public static boolean isLocalAddress(final String addr) {
+        try {
+            return isLocalAddress(InetAddress.getByName(addr));
+        } catch (final Exception e) {
+            return false;
+        }
+    }
+
+    public static boolean isLocalAddress(final InetAddress addr) {
+
+        if (addr.isAnyLocalAddress() || addr.isLoopbackAddress()) {
+            return true;
+        }
+
+        // Check if the address is defined on any interface
+        try {
+            return NetworkInterface.getByInetAddress(addr) != null;
+        } catch (final SocketException e) {
+            return false;
+        }
+    }
+
+    public static final class LastPort {
+        private final int port;
+        private final long time;
+
+        private LastPort(final int port, final long time) {
+            this.port = port;
+            this.time = time;
+        }
+
+        @Override
+        public boolean equals(final Object o) {
+            if (this == o) {
+                return true;
+            }
+            if (o == null || getClass() != o.getClass()) {
+                return false;
+            }
+
+            final LastPort lastPort = (LastPort) o;
+
+            return port == lastPort.port;
+
+        }
+
+        @Override
+        public int hashCode() {
+            return port;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStream.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStream.java b/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStream.java
index e347015..fbc0e23 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStream.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStream.java
@@ -1,109 +1,109 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.util;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * Log the output to Slf4j
- */
-
-public class Slf4jLogStream implements LogStream {
-    private Logger log;
-
-    public Slf4jLogStream(final LogCategory logCategory) {
-        log = LoggerFactory.getLogger(logCategory.getName());
-    }
-
-    @Override
-    public boolean isFatalEnabled() {
-        return log.isErrorEnabled();
-    }
-
-    @Override
-    public void fatal(final String message) {
-        log.error(message);
-    }
-
-    @Override
-    public void fatal(final String message, final Throwable t) {
-        log.error(message, t);
-    }
-
-    @Override
-    public boolean isErrorEnabled() {
-        return log.isErrorEnabled();
-    }
-
-    @Override
-    public void error(final String message) {
-        log.error(message);
-    }
-
-    @Override
-    public void error(final String message, final Throwable t) {
-        log.error(message, t);
-    }
-
-    @Override
-    public boolean isWarnEnabled() {
-        return log.isWarnEnabled();
-    }
-
-    @Override
-    public void warn(final String message) {
-        log.warn(message);
-    }
-
-    @Override
-    public void warn(final String message, final Throwable t) {
-        log.warn(message, t);
-    }
-
-    @Override
-    public boolean isInfoEnabled() {
-        return log.isInfoEnabled();
-    }
-
-    @Override
-    public void info(final String message) {
-        log.info(message);
-    }
-
-    @Override
-    public void info(final String message, final Throwable t) {
-        log.info(message, t);
-    }
-
-    @Override
-    public boolean isDebugEnabled() {
-        return log.isDebugEnabled();
-    }
-
-    @Override
-    public void debug(final String message) {
-        log.debug(message);
-    }
-
-    @Override
-    public void debug(final String message, final Throwable t) {
-        log.debug(message, t);
-    }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.util;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Log the output to Slf4j
+ */
+
+public class Slf4jLogStream implements LogStream {
+    private Logger log;
+
+    public Slf4jLogStream(final LogCategory logCategory) {
+        log = LoggerFactory.getLogger(logCategory.getName());
+    }
+
+    @Override
+    public boolean isFatalEnabled() {
+        return log.isErrorEnabled();
+    }
+
+    @Override
+    public void fatal(final String message) {
+        log.error(message);
+    }
+
+    @Override
+    public void fatal(final String message, final Throwable t) {
+        log.error(message, t);
+    }
+
+    @Override
+    public boolean isErrorEnabled() {
+        return log.isErrorEnabled();
+    }
+
+    @Override
+    public void error(final String message) {
+        log.error(message);
+    }
+
+    @Override
+    public void error(final String message, final Throwable t) {
+        log.error(message, t);
+    }
+
+    @Override
+    public boolean isWarnEnabled() {
+        return log.isWarnEnabled();
+    }
+
+    @Override
+    public void warn(final String message) {
+        log.warn(message);
+    }
+
+    @Override
+    public void warn(final String message, final Throwable t) {
+        log.warn(message, t);
+    }
+
+    @Override
+    public boolean isInfoEnabled() {
+        return log.isInfoEnabled();
+    }
+
+    @Override
+    public void info(final String message) {
+        log.info(message);
+    }
+
+    @Override
+    public void info(final String message, final Throwable t) {
+        log.info(message, t);
+    }
+
+    @Override
+    public boolean isDebugEnabled() {
+        return log.isDebugEnabled();
+    }
+
+    @Override
+    public void debug(final String message) {
+        log.debug(message);
+    }
+
+    @Override
+    public void debug(final String message, final Throwable t) {
+        log.debug(message, t);
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStreamFactory.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStreamFactory.java b/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStreamFactory.java
index a1b3f4d..a96407b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStreamFactory.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/util/Slf4jLogStreamFactory.java
@@ -1,40 +1,40 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.util;
-
-/**
- * Simple Slf4jLogStream, not much configuration needed, as slf4j is just a facade
- */
-
-public class Slf4jLogStreamFactory implements LogStreamFactory {
-    @Override
-    public LogStream createLogStream(final LogCategory logCategory) {
-        return new Slf4jLogStream(logCategory);
-    }
-
-    public Slf4jLogStreamFactory() {
-        System.setProperty("openjpa.Log", "slf4j");
-        System.setProperty("org.apache.cxf.Logger", "org.apache.cxf.common.logging.Slf4jLogger");
-        System.setProperty("openwebbeans.logging.factory", "org.apache.openejb.cdi.logging.Slf4jLoggerFactory");
-
-        // no need to configure internals:
-        // by default we are using JUL
-        // if the user set log4j he wants to configure it himself
-        // so let him doing
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.util;
+
+/**
+ * Simple Slf4jLogStream, not much configuration needed, as slf4j is just a facade
+ */
+
+public class Slf4jLogStreamFactory implements LogStreamFactory {
+    @Override
+    public LogStream createLogStream(final LogCategory logCategory) {
+        return new Slf4jLogStream(logCategory);
+    }
+
+    public Slf4jLogStreamFactory() {
+        System.setProperty("openjpa.Log", "slf4j");
+        System.setProperty("org.apache.cxf.Logger", "org.apache.cxf.common.logging.Slf4jLogger");
+        System.setProperty("openwebbeans.logging.factory", "org.apache.openejb.cdi.logging.Slf4jLoggerFactory");
+
+        // no need to configure internals:
+        // by default we are using JUL
+        // if the user set log4j he wants to configure it himself
+        // so let him doing
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/resources/META-INF/ejb-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/resources/META-INF/ejb-jar.xml b/container/openejb-core/src/main/resources/META-INF/ejb-jar.xml
index 7dd3541..7e42c45 100644
--- a/container/openejb-core/src/main/resources/META-INF/ejb-jar.xml
+++ b/container/openejb-core/src/main/resources/META-INF/ejb-jar.xml
@@ -1,21 +1,21 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-  Licensed to the Apache Software Foundation (ASF) under one or more
-  contributor license agreements.  See the NOTICE file distributed with
-  this work for additional information regarding copyright ownership.
-  The ASF licenses this file to You under the Apache License, Version 2.0
-  (the "License"); you may not use this file except in compliance with
-  the License.  You may obtain a copy of the License at
-
-      http://www.apache.org/licenses/LICENSE-2.0
-
-  Unless required by applicable law or agreed to in writing, software
-  distributed under the License is distributed on an "AS IS" BASIS,
-  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-  See the License for the specific language governing permissions and
-  limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <ejb-jar/>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/resources/META-INF/openejb-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/resources/META-INF/openejb-jar.xml b/container/openejb-core/src/main/resources/META-INF/openejb-jar.xml
index 724999c..7a7499e 100644
--- a/container/openejb-core/src/main/resources/META-INF/openejb-jar.xml
+++ b/container/openejb-core/src/main/resources/META-INF/openejb-jar.xml
@@ -1,26 +1,26 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-  ~ Licensed to the Apache Software Foundation (ASF) under one or more
-  ~ contributor license agreements.  See the NOTICE file distributed with
-  ~ this work for additional information regarding copyright ownership.
-  ~ The ASF licenses this file to You under the Apache License, Version 2.0
-  ~ (the "License"); you may not use this file except in compliance with
-  ~ the License.  You may obtain a copy of the License at
-  ~
-  ~     http://www.apache.org/licenses/LICENSE-2.0
-  ~
-  ~ Unless required by applicable law or agreed to in writing, software
-  ~ distributed under the License is distributed on an "AS IS" BASIS,
-  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-  ~ See the License for the specific language governing permissions and
-  ~ limitations under the License.
-  -->
-
-<!-- $Rev$ $Date$ -->
-
-<openejb-jar>
-  <properties>
-    openejb.deploymentId.format = {ejbName}
-    openejb.jndiname.format = {deploymentId}{interfaceType.openejbLegacyName}
-  </properties>
-</openejb-jar>
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one or more
+  ~ contributor license agreements.  See the NOTICE file distributed with
+  ~ this work for additional information regarding copyright ownership.
+  ~ The ASF licenses this file to You under the Apache License, Version 2.0
+  ~ (the "License"); you may not use this file except in compliance with
+  ~ the License.  You may obtain a copy of the License at
+  ~
+  ~     http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing, software
+  ~ distributed under the License is distributed on an "AS IS" BASIS,
+  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~ See the License for the specific language governing permissions and
+  ~ limitations under the License.
+  -->
+
+<!-- $Rev$ $Date$ -->
+
+<openejb-jar>
+  <properties>
+    openejb.deploymentId.format = {ejbName}
+    openejb.jndiname.format = {deploymentId}{interfaceType.openejbLegacyName}
+  </properties>
+</openejb-jar>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/resources/META-INF/org.apache.openejb.cli/validate.examples
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/resources/META-INF/org.apache.openejb.cli/validate.examples b/container/openejb-core/src/main/resources/META-INF/org.apache.openejb.cli/validate.examples
index 6b65463..ed3e20c 100644
--- a/container/openejb-core/src/main/resources/META-INF/org.apache.openejb.cli/validate.examples
+++ b/container/openejb-core/src/main/resources/META-INF/org.apache.openejb.cli/validate.examples
@@ -1,51 +1,51 @@
-Usage: openejb validate [options] JARFILES...
-
-Example: Multiple jar files
-
- openejb validate myapp\fooEjbs.jar myapp\barEjbs.jar
-
- Validates the beans in the fooEjbs.jar first, then validates the 
- beans in the barEjbs.jar.  Wildcards can be used as well.
-
- openejb validate myapp\*.jar
-
-Example: -v 
-
- openejb validate -v myapp\myEjbs.jar
-
- Validates the beans in the jar, outputting just the minumum details
- on each failure.
-
-Example: -vv 
-
- openejb validate -vv myapp\myEjbs.jar
-
- Validates the beans in the jar, outputting one line summaries of 
- each failure. This is the default output level.
-
-Example: -vvv 
-
- openejb validate -vv myapp\myEjbs.jar
-
- Validates the beans in the jar, outputting verbose details on each
- failure, usually with details on how to correct the failures.
-
-Example: -nowarn
-
- openejb validate -nowarn myapp\myEjbs.jar
- 
- Outputs only the failures and errors, no warnings.
-
-Example: -xml
-
- openejb validate -xml myapp\myEjbs.jar
- 
- Outputs the validation information in XML format.
- 
-Example: Combinations of options 
-
- openejb validate -vv -nowarn C:\foo\bar.jar D:\my\beans\*.jar
- openejb validate -vvv /foo/bar.jar
- openejb validate -xml /home/dblevins/mybeans/*.jar
-
-Bug Reports to <us...@tomee.apache.org>
+Usage: openejb validate [options] JARFILES...
+
+Example: Multiple jar files
+
+ openejb validate myapp\fooEjbs.jar myapp\barEjbs.jar
+
+ Validates the beans in the fooEjbs.jar first, then validates the 
+ beans in the barEjbs.jar.  Wildcards can be used as well.
+
+ openejb validate myapp\*.jar
+
+Example: -v 
+
+ openejb validate -v myapp\myEjbs.jar
+
+ Validates the beans in the jar, outputting just the minumum details
+ on each failure.
+
+Example: -vv 
+
+ openejb validate -vv myapp\myEjbs.jar
+
+ Validates the beans in the jar, outputting one line summaries of 
+ each failure. This is the default output level.
+
+Example: -vvv 
+
+ openejb validate -vv myapp\myEjbs.jar
+
+ Validates the beans in the jar, outputting verbose details on each
+ failure, usually with details on how to correct the failures.
+
+Example: -nowarn
+
+ openejb validate -nowarn myapp\myEjbs.jar
+ 
+ Outputs only the failures and errors, no warnings.
+
+Example: -xml
+
+ openejb validate -xml myapp\myEjbs.jar
+ 
+ Outputs the validation information in XML format.
+ 
+Example: Combinations of options 
+
+ openejb validate -vv -nowarn C:\foo\bar.jar D:\my\beans\*.jar
+ openejb validate -vvv /foo/bar.jar
+ openejb validate -xml /home/dblevins/mybeans/*.jar
+
+Bug Reports to <us...@tomee.apache.org>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/resources/openejb-version.properties
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/resources/openejb-version.properties b/container/openejb-core/src/main/resources/openejb-version.properties
index caf510a..0baa7cd 100644
--- a/container/openejb-core/src/main/resources/openejb-version.properties
+++ b/container/openejb-core/src/main/resources/openejb-version.properties
@@ -1,21 +1,21 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-copyright=Copyright 1999-2015 (C) Apache OpenEJB/TomEE Project, All Rights Reserved.
-url=http://tomee.apache.org/
-version=${pom.version}
-date=@DATE-REPLACED-BY-MAVEN@
-time=@TIME-REPLACED-BY-MAVEN@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+copyright=Copyright 1999-2015 (C) Apache OpenEJB/TomEE Project, All Rights Reserved.
+url=http://tomee.apache.org/
+version=${pom.version}
+date=@DATE-REPLACED-BY-MAVEN@
+time=@TIME-REPLACED-BY-MAVEN@


[10/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckAnnotationTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckAnnotationTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckAnnotationTest.java
index 221885c..39b9642 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckAnnotationTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckAnnotationTest.java
@@ -1,87 +1,87 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.ManagedBean;
-import org.apache.openejb.jee.MessageDrivenBean;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.test.annotated.Green;
-import org.apache.openejb.test.annotated.Red;
-import org.apache.openejb.test.annotated.Yellow;
-import org.apache.xbean.finder.AnnotationFinder;
-import org.apache.xbean.finder.archive.ClassesArchive;
-import org.junit.runner.RunWith;
-
-import javax.ejb.Local;
-import javax.ejb.Stateless;
-
-@RunWith(ValidationRunner.class)
-public class CheckAnnotationTest {
-
-    @Keys({@Key(value = "annotation.invalid.stateful.webservice", type = KeyType.WARNING)})
-    public AppModule testWebServiceWithStateful() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatefulBean(Green.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Green.class)).link());
-
-        final AppModule appModule = new AppModule(ejbModule);
-        return appModule;
-    }
-
-    @Keys({@Key(value = "annotation.invalid.messagedriven.webservice", type = KeyType.WARNING)})
-    public AppModule testWebServiceWithMessageDriven() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new MessageDrivenBean(Yellow.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Yellow.class)).link());
-
-        final AppModule appModule = new AppModule(ejbModule);
-        return appModule;
-    }
-
-
-    @Keys({@Key(value = "annotation.invalid.managedbean.webservice", type = KeyType.WARNING)})
-    public AppModule testWebServiceWithManagedBean() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new ManagedBean(Red.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Red.class)).link());
-
-        final AppModule appModule = new AppModule(ejbModule);
-        return appModule;
-    }
-
-    @Keys({@Key(value = "ann.local.forLocalBean", type = KeyType.WARNING)})
-    public EjbModule shouldWarnForLocalAnnotationOnBeanWithNoInterface() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(EjbWithoutInterface.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(EjbWithoutInterface.class)).link());
-        return ejbModule;
-    }
-
-    @Local
-    @Stateless
-    public static class EjbWithoutInterface {
-    }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.ManagedBean;
+import org.apache.openejb.jee.MessageDrivenBean;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.test.annotated.Green;
+import org.apache.openejb.test.annotated.Red;
+import org.apache.openejb.test.annotated.Yellow;
+import org.apache.xbean.finder.AnnotationFinder;
+import org.apache.xbean.finder.archive.ClassesArchive;
+import org.junit.runner.RunWith;
+
+import javax.ejb.Local;
+import javax.ejb.Stateless;
+
+@RunWith(ValidationRunner.class)
+public class CheckAnnotationTest {
+
+    @Keys({@Key(value = "annotation.invalid.stateful.webservice", type = KeyType.WARNING)})
+    public AppModule testWebServiceWithStateful() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatefulBean(Green.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Green.class)).link());
+
+        final AppModule appModule = new AppModule(ejbModule);
+        return appModule;
+    }
+
+    @Keys({@Key(value = "annotation.invalid.messagedriven.webservice", type = KeyType.WARNING)})
+    public AppModule testWebServiceWithMessageDriven() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new MessageDrivenBean(Yellow.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Yellow.class)).link());
+
+        final AppModule appModule = new AppModule(ejbModule);
+        return appModule;
+    }
+
+
+    @Keys({@Key(value = "annotation.invalid.managedbean.webservice", type = KeyType.WARNING)})
+    public AppModule testWebServiceWithManagedBean() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new ManagedBean(Red.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(Red.class)).link());
+
+        final AppModule appModule = new AppModule(ejbModule);
+        return appModule;
+    }
+
+    @Keys({@Key(value = "ann.local.forLocalBean", type = KeyType.WARNING)})
+    public EjbModule shouldWarnForLocalAnnotationOnBeanWithNoInterface() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(EjbWithoutInterface.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        ejbModule.setFinder(new AnnotationFinder(new ClassesArchive(EjbWithoutInterface.class)).link());
+        return ejbModule;
+    }
+
+    @Local
+    @Stateless
+    public static class EjbWithoutInterface {
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckCdiEnabledTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckCdiEnabledTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckCdiEnabledTest.java
index f064a33..945eec6 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckCdiEnabledTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckCdiEnabledTest.java
@@ -1,43 +1,43 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.xbean.finder.AnnotationFinder;
-import org.apache.xbean.finder.archive.ClassesArchive;
-import org.junit.runner.RunWith;
-
-import javax.inject.Inject;
-
-@RunWith(ValidationRunner.class)
-public class CheckCdiEnabledTest {
-    @Keys(@Key(value = "cdi.notEnabled", type = KeyType.WARNING))
-    public EjbModule cdiShouldBeOn() throws OpenEJBException {
-        return new EjbModule(new EjbJar())
-            .finder(new AnnotationFinder(new ClassesArchive(Bean1.class, Bean2.class)));
-    }
-
-    public static class Bean1 {
-    }
-
-    public static class Bean2 {
-        @Inject
-        private Bean1 bean1;
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.xbean.finder.AnnotationFinder;
+import org.apache.xbean.finder.archive.ClassesArchive;
+import org.junit.runner.RunWith;
+
+import javax.inject.Inject;
+
+@RunWith(ValidationRunner.class)
+public class CheckCdiEnabledTest {
+    @Keys(@Key(value = "cdi.notEnabled", type = KeyType.WARNING))
+    public EjbModule cdiShouldBeOn() throws OpenEJBException {
+        return new EjbModule(new EjbJar())
+            .finder(new AnnotationFinder(new ClassesArchive(Bean1.class, Bean2.class)));
+    }
+
+    public static class Bean1 {
+    }
+
+    public static class Bean2 {
+        @Inject
+        private Bean1 bean1;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckDependsOnTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckDependsOnTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckDependsOnTest.java
index 9c76064..c159207 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckDependsOnTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckDependsOnTest.java
@@ -1,76 +1,76 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.SingletonBean;
-import org.junit.runner.RunWith;
-
-import javax.ejb.DependsOn;
-import javax.ejb.Singleton;
-
-@RunWith(ValidationRunner.class)
-public class CheckDependsOnTest {
-    @Keys({@Key(value = "dependsOn.circuit", count = 2), @Key(value = "dependsOn.noSuchEjb", count = 2)})
-    public EjbJar dependsOn() throws OpenEJBException {
-        final EjbJar ejbJar = new EjbJar();
-        final SingletonBean one = new SingletonBean(One.class);
-        final SingletonBean two = new SingletonBean(Two.class);
-        final SingletonBean three = new SingletonBean(Three.class);
-        final SingletonBean four = new SingletonBean(Four.class);
-        final SingletonBean five = new SingletonBean(Five.class);
-        final SingletonBean six = new SingletonBean(Six.class);
-        ejbJar.addEnterpriseBean(one);
-        ejbJar.addEnterpriseBean(two);
-        ejbJar.addEnterpriseBean(three);
-        ejbJar.addEnterpriseBean(four);
-        ejbJar.addEnterpriseBean(five);
-        ejbJar.addEnterpriseBean(six);
-        return ejbJar;
-    }
-
-    @Singleton
-    @DependsOn("Two")
-    private static class One {
-    }
-
-    @Singleton
-    @DependsOn("One")
-    private static class Two {
-    }
-
-    @Singleton
-    @DependsOn("Four")
-    private static class Three {
-    }
-
-    @Singleton
-    @DependsOn("Three")
-    private static class Four {
-    }
-
-    @Singleton
-    @DependsOn("WrongOne")
-    private static class Five {
-    }
-
-    @Singleton
-    @DependsOn("WrongOne")
-    private static class Six {
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.SingletonBean;
+import org.junit.runner.RunWith;
+
+import javax.ejb.DependsOn;
+import javax.ejb.Singleton;
+
+@RunWith(ValidationRunner.class)
+public class CheckDependsOnTest {
+    @Keys({@Key(value = "dependsOn.circuit", count = 2), @Key(value = "dependsOn.noSuchEjb", count = 2)})
+    public EjbJar dependsOn() throws OpenEJBException {
+        final EjbJar ejbJar = new EjbJar();
+        final SingletonBean one = new SingletonBean(One.class);
+        final SingletonBean two = new SingletonBean(Two.class);
+        final SingletonBean three = new SingletonBean(Three.class);
+        final SingletonBean four = new SingletonBean(Four.class);
+        final SingletonBean five = new SingletonBean(Five.class);
+        final SingletonBean six = new SingletonBean(Six.class);
+        ejbJar.addEnterpriseBean(one);
+        ejbJar.addEnterpriseBean(two);
+        ejbJar.addEnterpriseBean(three);
+        ejbJar.addEnterpriseBean(four);
+        ejbJar.addEnterpriseBean(five);
+        ejbJar.addEnterpriseBean(six);
+        return ejbJar;
+    }
+
+    @Singleton
+    @DependsOn("Two")
+    private static class One {
+    }
+
+    @Singleton
+    @DependsOn("One")
+    private static class Two {
+    }
+
+    @Singleton
+    @DependsOn("Four")
+    private static class Three {
+    }
+
+    @Singleton
+    @DependsOn("Three")
+    private static class Four {
+    }
+
+    @Singleton
+    @DependsOn("WrongOne")
+    private static class Five {
+    }
+
+    @Singleton
+    @DependsOn("WrongOne")
+    private static class Six {
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNameTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNameTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNameTest.java
index 2d5c63e..8e37feb 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNameTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNameTest.java
@@ -1,50 +1,50 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.loader.SystemInstance;
-import org.junit.runner.RunWith;
-
-import javax.interceptor.AroundInvoke;
-
-@RunWith(ValidationRunner.class)
-public class CheckIncorrectPropertyNameTest {
-
-
-    @Keys({@Key(value = "incorrect.property.name", type = KeyType.WARNING)})
-    public AppModule testSystemPropertyNames() {
-        //SystemInstance.get().setProperty("java.persistence.provider", "test");
-        SystemInstance.get().setProperty("javax.naming.referral", "test");
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatefulBean(Green.class));
-        return new AppModule(new EjbModule(ejbJar));
-    }
-}
-
-
-class Green {
-
-    // need to add this @AroundInvoke to cause validation to fail. Validation does not
-    // fail on warnings, which causes this framework to not work properly
-    @AroundInvoke
-    public void sayCheese() {
-    }
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.loader.SystemInstance;
+import org.junit.runner.RunWith;
+
+import javax.interceptor.AroundInvoke;
+
+@RunWith(ValidationRunner.class)
+public class CheckIncorrectPropertyNameTest {
+
+
+    @Keys({@Key(value = "incorrect.property.name", type = KeyType.WARNING)})
+    public AppModule testSystemPropertyNames() {
+        //SystemInstance.get().setProperty("java.persistence.provider", "test");
+        SystemInstance.get().setProperty("javax.naming.referral", "test");
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatefulBean(Green.class));
+        return new AppModule(new EjbModule(ejbJar));
+    }
+}
+
+
+class Green {
+
+    // need to add this @AroundInvoke to cause validation to fail. Validation does not
+    // fail on warnings, which causes this framework to not work properly
+    @AroundInvoke
+    public void sayCheese() {
+    }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckMissingClassTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckMissingClassTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckMissingClassTest.java
index f591370..5393bb9 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckMissingClassTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckMissingClassTest.java
@@ -1,184 +1,184 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.EntityBean;
-import org.apache.openejb.jee.PersistenceType;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.jee.StatelessBean;
-import org.junit.runner.RunWith;
-
-import javax.ejb.EJBException;
-import javax.ejb.EntityContext;
-import javax.ejb.RemoveException;
-import javax.ejb.SessionBean;
-import javax.ejb.SessionContext;
-import java.rmi.RemoteException;
-
-@RunWith(ValidationRunner.class)
-public class CheckMissingClassTest {
-    @Keys(@Key(value = "missing.class", count = 16))
-    public EjbJar wrongClassType() throws OpenEJBException {
-        System.setProperty("openejb.validation.output.level", "VERBOSE");
-        final EjbJar ejbJar = new EjbJar();
-        final StatelessBean stateless = new StatelessBean(FooStateless.class);
-        stateless.setHomeAndRemote("WrongHome", "WrongRemote");
-        stateless.setLocal("WrongLocal");
-        stateless.setLocalHome("WrongLocalHome");
-        ejbJar.addEnterpriseBean(stateless);
-        final StatefulBean stateful = new StatefulBean(FooStateful.class);
-        stateful.setHomeAndRemote("WrongHome", "WrongRemote");
-        stateful.setLocal("WrongLocal");
-        stateful.setLocalHome("WrongLocalHome");
-        ejbJar.addEnterpriseBean(stateful);
-        final EntityBean bmpEntityBean = new EntityBean(FooEntityBMP.class, PersistenceType.BEAN);
-        bmpEntityBean.setHome("WrongHome");
-        bmpEntityBean.setLocalHome("WrongLocalHome");
-        bmpEntityBean.setRemote("WrongRemote");
-        bmpEntityBean.setLocal("WrongLocal");
-        ejbJar.addEnterpriseBean(bmpEntityBean);
-        final EntityBean cmpEntityBean = new EntityBean(FooEntityCMP.class, PersistenceType.CONTAINER);
-        cmpEntityBean.setHome("WrongHome");
-        cmpEntityBean.setLocalHome("WrongLocalHome");
-        cmpEntityBean.setRemote("WrongRemote");
-        cmpEntityBean.setLocal("WrongLocal");
-        ejbJar.addEnterpriseBean(cmpEntityBean);
-        return ejbJar;
-    }
-
-    private static class FooStateless implements SessionBean {
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static class FooStateful implements SessionBean {
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static class FooEntityBMP implements javax.ejb.EntityBean {
-        public String ejbCreate(final String id) {
-            return null;
-        }
-
-        public void ejbPostCreate(final String id) {
-        }
-
-        ;
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbLoad() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbStore() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void unsetEntityContext() throws EJBException, RemoteException {
-        }
-    }
-
-    private static class FooEntityCMP implements javax.ejb.EntityBean {
-        public String ejbCreate(final String id) {
-            return null;
-        }
-
-        public void ejbPostCreate(final String id) {
-        }
-
-        ;
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbLoad() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbStore() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void unsetEntityContext() throws EJBException, RemoteException {
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.EntityBean;
+import org.apache.openejb.jee.PersistenceType;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.jee.StatelessBean;
+import org.junit.runner.RunWith;
+
+import javax.ejb.EJBException;
+import javax.ejb.EntityContext;
+import javax.ejb.RemoveException;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+import java.rmi.RemoteException;
+
+@RunWith(ValidationRunner.class)
+public class CheckMissingClassTest {
+    @Keys(@Key(value = "missing.class", count = 16))
+    public EjbJar wrongClassType() throws OpenEJBException {
+        System.setProperty("openejb.validation.output.level", "VERBOSE");
+        final EjbJar ejbJar = new EjbJar();
+        final StatelessBean stateless = new StatelessBean(FooStateless.class);
+        stateless.setHomeAndRemote("WrongHome", "WrongRemote");
+        stateless.setLocal("WrongLocal");
+        stateless.setLocalHome("WrongLocalHome");
+        ejbJar.addEnterpriseBean(stateless);
+        final StatefulBean stateful = new StatefulBean(FooStateful.class);
+        stateful.setHomeAndRemote("WrongHome", "WrongRemote");
+        stateful.setLocal("WrongLocal");
+        stateful.setLocalHome("WrongLocalHome");
+        ejbJar.addEnterpriseBean(stateful);
+        final EntityBean bmpEntityBean = new EntityBean(FooEntityBMP.class, PersistenceType.BEAN);
+        bmpEntityBean.setHome("WrongHome");
+        bmpEntityBean.setLocalHome("WrongLocalHome");
+        bmpEntityBean.setRemote("WrongRemote");
+        bmpEntityBean.setLocal("WrongLocal");
+        ejbJar.addEnterpriseBean(bmpEntityBean);
+        final EntityBean cmpEntityBean = new EntityBean(FooEntityCMP.class, PersistenceType.CONTAINER);
+        cmpEntityBean.setHome("WrongHome");
+        cmpEntityBean.setLocalHome("WrongLocalHome");
+        cmpEntityBean.setRemote("WrongRemote");
+        cmpEntityBean.setLocal("WrongLocal");
+        ejbJar.addEnterpriseBean(cmpEntityBean);
+        return ejbJar;
+    }
+
+    private static class FooStateless implements SessionBean {
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static class FooStateful implements SessionBean {
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static class FooEntityBMP implements javax.ejb.EntityBean {
+        public String ejbCreate(final String id) {
+            return null;
+        }
+
+        public void ejbPostCreate(final String id) {
+        }
+
+        ;
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbLoad() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbStore() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void unsetEntityContext() throws EJBException, RemoteException {
+        }
+    }
+
+    private static class FooEntityCMP implements javax.ejb.EntityBean {
+        public String ejbCreate(final String id) {
+            return null;
+        }
+
+        public void ejbPostCreate(final String id) {
+        }
+
+        ;
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbLoad() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbStore() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void unsetEntityContext() throws EJBException, RemoteException {
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoBusinessMethodTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoBusinessMethodTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoBusinessMethodTest.java
index 180c6e1..f591735 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoBusinessMethodTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoBusinessMethodTest.java
@@ -1,198 +1,198 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.jee.StatelessBean;
-import org.junit.runner.RunWith;
-
-import javax.ejb.CreateException;
-import javax.ejb.EJBException;
-import javax.ejb.EJBHome;
-import javax.ejb.EJBLocalHome;
-import javax.ejb.EJBLocalObject;
-import javax.ejb.EJBObject;
-import javax.ejb.SessionBean;
-import javax.ejb.SessionContext;
-import java.rmi.RemoteException;
-
-@RunWith(ValidationRunner.class)
-public class CheckNoBusinessMethodTest {
-    @Keys({@Key(value = "no.busines.method.case", count = 4), @Key(value = "no.busines.method.args", count = 4), @Key(value = "no.busines.method", count = 4)})
-    public EjbJar noBusinessMethod() throws OpenEJBException {
-        // System.setProperty("openejb.validation.output.level", "VERBOSE");
-        final EjbJar ejbJar = new EjbJar();
-        final StatelessBean stateLessLocal = new StatelessBean(FooStatelessSession.class);
-        stateLessLocal.setLocalHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocalHome");
-        stateLessLocal.setLocal("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocal");
-        final StatefulBean statefulLocal = new StatefulBean(FooStatefulSession.class);
-        statefulLocal.setLocalHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocalHome");
-        statefulLocal.setLocal("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocal");
-        final StatelessBean stateLessRemote = new StatelessBean(FooRemoteStatelessSession.class);
-        stateLessRemote.setHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemoteHome");
-        stateLessRemote.setRemote("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemote");
-        final StatefulBean statefulRemote = new StatefulBean(FooRemoteStatefulSession.class);
-        statefulRemote.setHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemoteHome");
-        statefulRemote.setRemote("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemote");
-        ejbJar.addEnterpriseBean(stateLessLocal);
-        ejbJar.addEnterpriseBean(statefulLocal);
-        ejbJar.addEnterpriseBean(stateLessRemote);
-        ejbJar.addEnterpriseBean(statefulRemote);
-        return ejbJar;
-    }
-
-    private static interface FooLocalHome extends EJBLocalHome {
-        FooLocal create() throws CreateException;
-    }
-
-    private static interface FooLocal extends EJBLocalObject {
-        void foo(String x, String y);
-
-        // this method is not implemented by the bean class
-        void foo1();
-    }
-
-    private static class FooStatelessSession implements SessionBean {
-        // method name is same as in the Local interface, except arguments are different
-        public void foo(final int x, final String y) {
-        }
-
-        // method name has a different case
-        public void Foo(final String x, final String y) {
-        }
-
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static class FooStatefulSession implements SessionBean {
-        // method name is same as in the Local interface, except arguments are different
-        public void foo(final int x, final String y) {
-        }
-
-        // method name has a different case
-        public void Foo(final String x, final String y) {
-        }
-
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    // =================
-    private static interface FooRemoteHome extends EJBHome {
-        FooRemote create() throws RemoteException, CreateException;
-    }
-
-    private static interface FooRemote extends EJBObject {
-        void foo(String x, String y) throws RemoteException;
-
-        // This method is not implemented by the bean class
-        void foo1() throws RemoteException;
-    }
-
-    private static class FooRemoteStatelessSession implements SessionBean {
-        // method name is same as in the Remote interface, except arguments are different
-        public void foo(final int x, final String y) {
-        }
-
-        // method name has a different case
-        public void Foo(final String x, final String y) {
-        }
-
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static class FooRemoteStatefulSession implements SessionBean {
-        // method name is same as in the Remote interface, except arguments are different
-        public void foo(final int x, final String y) {
-        }
-
-        // method name has a different case
-        public void Foo(final String x, final String y) {
-        }
-
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.jee.StatelessBean;
+import org.junit.runner.RunWith;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBException;
+import javax.ejb.EJBHome;
+import javax.ejb.EJBLocalHome;
+import javax.ejb.EJBLocalObject;
+import javax.ejb.EJBObject;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+import java.rmi.RemoteException;
+
+@RunWith(ValidationRunner.class)
+public class CheckNoBusinessMethodTest {
+    @Keys({@Key(value = "no.busines.method.case", count = 4), @Key(value = "no.busines.method.args", count = 4), @Key(value = "no.busines.method", count = 4)})
+    public EjbJar noBusinessMethod() throws OpenEJBException {
+        // System.setProperty("openejb.validation.output.level", "VERBOSE");
+        final EjbJar ejbJar = new EjbJar();
+        final StatelessBean stateLessLocal = new StatelessBean(FooStatelessSession.class);
+        stateLessLocal.setLocalHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocalHome");
+        stateLessLocal.setLocal("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocal");
+        final StatefulBean statefulLocal = new StatefulBean(FooStatefulSession.class);
+        statefulLocal.setLocalHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocalHome");
+        statefulLocal.setLocal("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooLocal");
+        final StatelessBean stateLessRemote = new StatelessBean(FooRemoteStatelessSession.class);
+        stateLessRemote.setHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemoteHome");
+        stateLessRemote.setRemote("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemote");
+        final StatefulBean statefulRemote = new StatefulBean(FooRemoteStatefulSession.class);
+        statefulRemote.setHome("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemoteHome");
+        statefulRemote.setRemote("org.apache.openejb.config.rules.CheckNoBusinessMethodTest$FooRemote");
+        ejbJar.addEnterpriseBean(stateLessLocal);
+        ejbJar.addEnterpriseBean(statefulLocal);
+        ejbJar.addEnterpriseBean(stateLessRemote);
+        ejbJar.addEnterpriseBean(statefulRemote);
+        return ejbJar;
+    }
+
+    private static interface FooLocalHome extends EJBLocalHome {
+        FooLocal create() throws CreateException;
+    }
+
+    private static interface FooLocal extends EJBLocalObject {
+        void foo(String x, String y);
+
+        // this method is not implemented by the bean class
+        void foo1();
+    }
+
+    private static class FooStatelessSession implements SessionBean {
+        // method name is same as in the Local interface, except arguments are different
+        public void foo(final int x, final String y) {
+        }
+
+        // method name has a different case
+        public void Foo(final String x, final String y) {
+        }
+
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static class FooStatefulSession implements SessionBean {
+        // method name is same as in the Local interface, except arguments are different
+        public void foo(final int x, final String y) {
+        }
+
+        // method name has a different case
+        public void Foo(final String x, final String y) {
+        }
+
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    // =================
+    private static interface FooRemoteHome extends EJBHome {
+        FooRemote create() throws RemoteException, CreateException;
+    }
+
+    private static interface FooRemote extends EJBObject {
+        void foo(String x, String y) throws RemoteException;
+
+        // This method is not implemented by the bean class
+        void foo1() throws RemoteException;
+    }
+
+    private static class FooRemoteStatelessSession implements SessionBean {
+        // method name is same as in the Remote interface, except arguments are different
+        public void foo(final int x, final String y) {
+        }
+
+        // method name has a different case
+        public void Foo(final String x, final String y) {
+        }
+
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static class FooRemoteStatefulSession implements SessionBean {
+        // method name is same as in the Remote interface, except arguments are different
+        public void foo(final int x, final String y) {
+        }
+
+        // method name has a different case
+        public void Foo(final String x, final String y) {
+        }
+
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoCreateMethodsTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoCreateMethodsTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoCreateMethodsTest.java
index d5f3144..554ce09 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoCreateMethodsTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckNoCreateMethodsTest.java
@@ -1,280 +1,280 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.PersistenceType;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.jee.StatelessBean;
-import org.junit.runner.RunWith;
-
-import javax.ejb.CreateException;
-import javax.ejb.EJBException;
-import javax.ejb.EJBLocalHome;
-import javax.ejb.EJBLocalObject;
-import javax.ejb.EntityBean;
-import javax.ejb.EntityContext;
-import javax.ejb.FinderException;
-import javax.ejb.LocalHome;
-import javax.ejb.RemoteHome;
-import javax.ejb.RemoveException;
-import javax.ejb.SessionBean;
-import javax.ejb.SessionContext;
-import java.rmi.RemoteException;
-
-@RunWith(ValidationRunner.class)
-public class CheckNoCreateMethodsTest {
-    @Keys({@Key(value = "no.home.create", count = 4), @Key(value = "unused.ejb.create", count = 2, type = KeyType.WARNING),
-        @Key(value = "unused.ejbPostCreate", type = KeyType.WARNING), @Key("entity.no.ejb.create"), @Key(value = "session.no.ejb.create", count = 2)})
-    public EjbJar noCreateMethod() throws OpenEJBException {
-        System.setProperty("openejb.validation.output.level", "VERBOSE");
-        final EjbJar ejbJar = new EjbJar();
-        final StatelessBean stateless = new StatelessBean(FooStateless.class);
-        stateless.setHomeAndRemote(FooStatelessHome.class, FooStatelessRemote.class);
-        stateless.setHomeAndLocal(FooStatelessLocalHome.class, FooStatelessLocal.class);
-        ejbJar.addEnterpriseBean(stateless);
-        final StatefulBean stateful = new StatefulBean(FooStateful.class);
-        stateful.setHomeAndRemote(FooStatefulHome.class, FooStatefulRemote.class);
-        stateful.setHomeAndLocal(FooStatefulLocalHome.class, FooStatefulLocal.class);
-        ejbJar.addEnterpriseBean(stateful);
-        final org.apache.openejb.jee.EntityBean bean = new org.apache.openejb.jee.EntityBean(MyEntity.class, PersistenceType.BEAN);
-        bean.setLocalHome(MyLocalHome.class.getName());
-        bean.setLocal(MyLocal.class.getName());
-        ejbJar.addEnterpriseBean(bean);
-        final org.apache.openejb.jee.EntityBean bean1 = new org.apache.openejb.jee.EntityBean(YourEntity.class, PersistenceType.BEAN);
-        bean1.setLocalHome(MyLocalHome.class.getName());
-        bean1.setLocal(MyLocal.class.getName());
-        ejbJar.addEnterpriseBean(bean1);
-        final StatelessBean bar = new StatelessBean(BarStateless.class);
-        bar.setHomeAndRemote(BarStatelessHome.class, BarStatelessRemote.class);
-        ejbJar.addEnterpriseBean(bar);
-        final StatefulBean bazStateful = new StatefulBean(BazStateful.class);
-        ejbJar.addEnterpriseBean(bazStateful);
-        return ejbJar;
-    }
-
-    private static interface FooStatelessHome extends javax.ejb.EJBHome {
-    }
-
-    private static interface FooStatelessRemote extends javax.ejb.EJBObject {
-    }
-
-    private static interface FooStatelessLocalHome extends javax.ejb.EJBLocalHome {
-    }
-
-    private static interface FooStatelessLocal extends javax.ejb.EJBLocalObject {
-    }
-
-    private static class FooStateless implements SessionBean {
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static interface FooStatefulHome extends javax.ejb.EJBHome {
-    }
-
-    private static interface FooStatefulRemote extends javax.ejb.EJBObject {
-    }
-
-    private static interface FooStatefulLocalHome extends javax.ejb.EJBLocalHome {
-    }
-
-    private static interface FooStatefulLocal extends javax.ejb.EJBLocalObject {
-    }
-
-    private static class FooStateful implements SessionBean {
-        public void ejbCreate() {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static interface MyLocalHome extends EJBLocalHome {
-        public MyLocal create(Integer pk) throws CreateException;
-
-        public MyLocal findByPrimaryKey(Integer pk) throws FinderException;
-    }
-
-    private static interface MyLocal extends EJBLocalObject {
-    }
-
-    private static class MyEntity implements EntityBean {
-        public Integer ejbCreate(final Integer pk) throws CreateException {
-            return null;
-        }
-
-        public void ejbPostCreate(final String str) {
-        }
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbLoad() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbStore() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void unsetEntityContext() throws EJBException, RemoteException {
-        }
-    }
-
-    private static class YourEntity implements EntityBean {
-//        public Integer ejbCreate(Integer pk) throws CreateException {
-//            return null;
-//        }
-
-//        public void ejbPostCreate(Integer pk) {}
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbLoad() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbStore() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void unsetEntityContext() throws EJBException, RemoteException {
-        }
-    }
-
-    private static interface BarStatelessHome extends javax.ejb.EJBHome {
-        public BarStatelessRemote create() throws CreateException, RemoteException;
-    }
-
-    private static interface BarStatelessRemote extends javax.ejb.EJBObject {
-    }
-
-    private static class BarStateless implements SessionBean {
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-
-    private static interface BazStatefulHome extends javax.ejb.EJBHome {
-        public BazStatefulRemote create() throws CreateException, RemoteException;
-    }
-
-    private static interface BazStatefulRemote extends javax.ejb.EJBObject {
-    }
-
-    private static interface BazStatefulLocalHome extends javax.ejb.EJBLocalHome {
-        public BazStatefulLocal create() throws CreateException;
-    }
-
-    private static interface BazStatefulLocal extends javax.ejb.EJBLocalObject {
-    }
-
-    @RemoteHome(BazStatefulHome.class)
-    @LocalHome(BazStatefulLocalHome.class)
-    private static class BazStateful implements SessionBean {
-        // missing ejbCreate method
-
-        @Override
-        public void ejbActivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbPassivate() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void ejbRemove() throws EJBException, RemoteException {
-        }
-
-        @Override
-        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.PersistenceType;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.jee.StatelessBean;
+import org.junit.runner.RunWith;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBException;
+import javax.ejb.EJBLocalHome;
+import javax.ejb.EJBLocalObject;
+import javax.ejb.EntityBean;
+import javax.ejb.EntityContext;
+import javax.ejb.FinderException;
+import javax.ejb.LocalHome;
+import javax.ejb.RemoteHome;
+import javax.ejb.RemoveException;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+import java.rmi.RemoteException;
+
+@RunWith(ValidationRunner.class)
+public class CheckNoCreateMethodsTest {
+    @Keys({@Key(value = "no.home.create", count = 4), @Key(value = "unused.ejb.create", count = 2, type = KeyType.WARNING),
+        @Key(value = "unused.ejbPostCreate", type = KeyType.WARNING), @Key("entity.no.ejb.create"), @Key(value = "session.no.ejb.create", count = 2)})
+    public EjbJar noCreateMethod() throws OpenEJBException {
+        System.setProperty("openejb.validation.output.level", "VERBOSE");
+        final EjbJar ejbJar = new EjbJar();
+        final StatelessBean stateless = new StatelessBean(FooStateless.class);
+        stateless.setHomeAndRemote(FooStatelessHome.class, FooStatelessRemote.class);
+        stateless.setHomeAndLocal(FooStatelessLocalHome.class, FooStatelessLocal.class);
+        ejbJar.addEnterpriseBean(stateless);
+        final StatefulBean stateful = new StatefulBean(FooStateful.class);
+        stateful.setHomeAndRemote(FooStatefulHome.class, FooStatefulRemote.class);
+        stateful.setHomeAndLocal(FooStatefulLocalHome.class, FooStatefulLocal.class);
+        ejbJar.addEnterpriseBean(stateful);
+        final org.apache.openejb.jee.EntityBean bean = new org.apache.openejb.jee.EntityBean(MyEntity.class, PersistenceType.BEAN);
+        bean.setLocalHome(MyLocalHome.class.getName());
+        bean.setLocal(MyLocal.class.getName());
+        ejbJar.addEnterpriseBean(bean);
+        final org.apache.openejb.jee.EntityBean bean1 = new org.apache.openejb.jee.EntityBean(YourEntity.class, PersistenceType.BEAN);
+        bean1.setLocalHome(MyLocalHome.class.getName());
+        bean1.setLocal(MyLocal.class.getName());
+        ejbJar.addEnterpriseBean(bean1);
+        final StatelessBean bar = new StatelessBean(BarStateless.class);
+        bar.setHomeAndRemote(BarStatelessHome.class, BarStatelessRemote.class);
+        ejbJar.addEnterpriseBean(bar);
+        final StatefulBean bazStateful = new StatefulBean(BazStateful.class);
+        ejbJar.addEnterpriseBean(bazStateful);
+        return ejbJar;
+    }
+
+    private static interface FooStatelessHome extends javax.ejb.EJBHome {
+    }
+
+    private static interface FooStatelessRemote extends javax.ejb.EJBObject {
+    }
+
+    private static interface FooStatelessLocalHome extends javax.ejb.EJBLocalHome {
+    }
+
+    private static interface FooStatelessLocal extends javax.ejb.EJBLocalObject {
+    }
+
+    private static class FooStateless implements SessionBean {
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static interface FooStatefulHome extends javax.ejb.EJBHome {
+    }
+
+    private static interface FooStatefulRemote extends javax.ejb.EJBObject {
+    }
+
+    private static interface FooStatefulLocalHome extends javax.ejb.EJBLocalHome {
+    }
+
+    private static interface FooStatefulLocal extends javax.ejb.EJBLocalObject {
+    }
+
+    private static class FooStateful implements SessionBean {
+        public void ejbCreate() {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static interface MyLocalHome extends EJBLocalHome {
+        public MyLocal create(Integer pk) throws CreateException;
+
+        public MyLocal findByPrimaryKey(Integer pk) throws FinderException;
+    }
+
+    private static interface MyLocal extends EJBLocalObject {
+    }
+
+    private static class MyEntity implements EntityBean {
+        public Integer ejbCreate(final Integer pk) throws CreateException {
+            return null;
+        }
+
+        public void ejbPostCreate(final String str) {
+        }
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbLoad() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbStore() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void unsetEntityContext() throws EJBException, RemoteException {
+        }
+    }
+
+    private static class YourEntity implements EntityBean {
+//        public Integer ejbCreate(Integer pk) throws CreateException {
+//            return null;
+//        }
+
+//        public void ejbPostCreate(Integer pk) {}
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbLoad() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws RemoveException, EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbStore() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setEntityContext(final EntityContext arg0) throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void unsetEntityContext() throws EJBException, RemoteException {
+        }
+    }
+
+    private static interface BarStatelessHome extends javax.ejb.EJBHome {
+        public BarStatelessRemote create() throws CreateException, RemoteException;
+    }
+
+    private static interface BarStatelessRemote extends javax.ejb.EJBObject {
+    }
+
+    private static class BarStateless implements SessionBean {
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+
+    private static interface BazStatefulHome extends javax.ejb.EJBHome {
+        public BazStatefulRemote create() throws CreateException, RemoteException;
+    }
+
+    private static interface BazStatefulRemote extends javax.ejb.EJBObject {
+    }
+
+    private static interface BazStatefulLocalHome extends javax.ejb.EJBLocalHome {
+        public BazStatefulLocal create() throws CreateException;
+    }
+
+    private static interface BazStatefulLocal extends javax.ejb.EJBLocalObject {
+    }
+
+    @RemoteHome(BazStatefulHome.class)
+    @LocalHome(BazStatefulLocalHome.class)
+    private static class BazStateful implements SessionBean {
+        // missing ejbCreate method
+
+        @Override
+        public void ejbActivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbPassivate() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void ejbRemove() throws EJBException, RemoteException {
+        }
+
+        @Override
+        public void setSessionContext(final SessionContext arg0) throws EJBException, RemoteException {
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceContextUsageTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceContextUsageTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceContextUsageTest.java
index fbd9e3a..ec84ba7 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceContextUsageTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceContextUsageTest.java
@@ -1,99 +1,99 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.config.PersistenceModule;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
-import org.junit.runner.RunWith;
-
-import javax.persistence.EntityManager;
-import javax.persistence.EntityManagerFactory;
-import javax.persistence.PersistenceContext;
-import javax.persistence.PersistenceContextType;
-
-@RunWith(ValidationRunner.class)
-public class CheckPersistenceContextUsageTest {
-    @Keys({@Key(value = "persistenceContextExtented.nonStateful"), @Key(value = "persistenceContextRef.noPersistenceUnits", count = 3),
-        @Key(value = "persistenceContextAnnotation.onClassWithNoName"), @Key(value = "persistenceContextAnnotation.onEntityManagerFactory"),
-        @Key(value = "persistenceContextAnnotation.onNonEntityManager")})
-    public EjbJar wrongUsage() throws OpenEJBException {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
-        return ejbJar;
-    }
-
-    @Keys({@Key(value = "persistenceContextRef.noUnitName"), @Key(value = "persistenceContextRef.noMatches")})
-    public AppModule noUnitName() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessOne.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
-        appModule.getEjbModules().add(ejbModule);
-        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
-        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit1");
-        final PersistenceUnit pu2 = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu, pu1, pu2);
-        final PersistenceModule pm = new PersistenceModule("foo", p);
-        appModule.addPersistenceModule(pm);
-        return appModule;
-    }
-
-    @Keys({@Key(value = "persistenceContextRef.vagueMatches")})
-    public AppModule vagueMatches() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessTwo.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
-        appModule.getEjbModules().add(ejbModule);
-        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu);
-        final PersistenceModule pm = new PersistenceModule("foo", p);
-        appModule.getPersistenceModules().add(pm);
-        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p1 = new org.apache.openejb.jee.jpa.unit.Persistence(pu1);
-        final PersistenceModule pm1 = new PersistenceModule("foo1", p1);
-        appModule.addPersistenceModule(pm1);
-        return appModule;
-    }
-
-    @PersistenceContext
-    private static class FooStateless {
-        @PersistenceContext(type = PersistenceContextType.EXTENDED)
-        EntityManager em;
-        @PersistenceContext
-        EntityManagerFactory emf;
-        @PersistenceContext
-        String nonEntityManager;
-    }
-
-    private static class FooStatelessOne {
-        @PersistenceContext
-        EntityManager em;
-        @PersistenceContext(unitName = "wrongName")
-        EntityManager em1;
-    }
-
-    private static class FooStatelessTwo {
-        @PersistenceContext(unitName = "fooUnit")
-        EntityManager em1;
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.config.PersistenceModule;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
+import org.junit.runner.RunWith;
+
+import javax.persistence.EntityManager;
+import javax.persistence.EntityManagerFactory;
+import javax.persistence.PersistenceContext;
+import javax.persistence.PersistenceContextType;
+
+@RunWith(ValidationRunner.class)
+public class CheckPersistenceContextUsageTest {
+    @Keys({@Key(value = "persistenceContextExtented.nonStateful"), @Key(value = "persistenceContextRef.noPersistenceUnits", count = 3),
+        @Key(value = "persistenceContextAnnotation.onClassWithNoName"), @Key(value = "persistenceContextAnnotation.onEntityManagerFactory"),
+        @Key(value = "persistenceContextAnnotation.onNonEntityManager")})
+    public EjbJar wrongUsage() throws OpenEJBException {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
+        return ejbJar;
+    }
+
+    @Keys({@Key(value = "persistenceContextRef.noUnitName"), @Key(value = "persistenceContextRef.noMatches")})
+    public AppModule noUnitName() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessOne.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
+        appModule.getEjbModules().add(ejbModule);
+        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
+        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit1");
+        final PersistenceUnit pu2 = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu, pu1, pu2);
+        final PersistenceModule pm = new PersistenceModule("foo", p);
+        appModule.addPersistenceModule(pm);
+        return appModule;
+    }
+
+    @Keys({@Key(value = "persistenceContextRef.vagueMatches")})
+    public AppModule vagueMatches() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessTwo.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
+        appModule.getEjbModules().add(ejbModule);
+        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu);
+        final PersistenceModule pm = new PersistenceModule("foo", p);
+        appModule.getPersistenceModules().add(pm);
+        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p1 = new org.apache.openejb.jee.jpa.unit.Persistence(pu1);
+        final PersistenceModule pm1 = new PersistenceModule("foo1", p1);
+        appModule.addPersistenceModule(pm1);
+        return appModule;
+    }
+
+    @PersistenceContext
+    private static class FooStateless {
+        @PersistenceContext(type = PersistenceContextType.EXTENDED)
+        EntityManager em;
+        @PersistenceContext
+        EntityManagerFactory emf;
+        @PersistenceContext
+        String nonEntityManager;
+    }
+
+    private static class FooStatelessOne {
+        @PersistenceContext
+        EntityManager em;
+        @PersistenceContext(unitName = "wrongName")
+        EntityManager em1;
+    }
+
+    private static class FooStatelessTwo {
+        @PersistenceContext(unitName = "fooUnit")
+        EntityManager em1;
+    }
+}


[12/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/resources/org/apache/openejb/config/rules/Messages_hi.properties
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/resources/org/apache/openejb/config/rules/Messages_hi.properties b/container/openejb-core/src/main/resources/org/apache/openejb/config/rules/Messages_hi.properties
index e261afa..919c195 100644
--- a/container/openejb-core/src/main/resources/org/apache/openejb/config/rules/Messages_hi.properties
+++ b/container/openejb-core/src/main/resources/org/apache/openejb/config/rules/Messages_hi.properties
@@ -1,856 +1,856 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# Format for the different levels follows this spirit:
-#
-# 1. Should be short and fixed such that someone could search/grep for it
-#    without having to know/use regular expressions.  These tend to be similar
-#    to the message key.
-#
-# 2. Intended to contain the issue expressed in 1 with only the essential
-#    details, should not line wrap if possible.  Be terse.
-#
-# 3. Teacher's assistant.  A much more conversational and possibly more detailed
-#    explanation of the issue, should tell the user what to do to fix the problem.
-#    I.e. don't just point out what is wrong, also point out what is right.  Use
-#    several lines if needed.
-#
-
-
-# 0 - Error Message
-# 1 - Stack Trace
-1.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947
-2.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947: {0}
-3.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947: {0}
-
-# 0 - Class name
-# 1 - Element (home, ejb-class, remote)
-# 2 - Bean name
-1.missing.class           \u0932\u093e\u092a\u0924\u093e \u0915\u094d\u0932\u093e\u0938
-2.missing.class           \u0932\u093e\u092a\u0924\u093e \u0915\u094d\u0932\u093e\u0938 <{1}> {0}
-3.missing.class           \u0915\u094d\u0932\u093e\u0938 {0} \u0928\u0939\u0940\u0902 \u092e\u093f\u0932\u0940 . \u091c\u093e\u0902\u091a \u0915\u0930\u0947\u0902 \u0915\u0940 \u092c\u0940\u0928 {2} \u0915\u0947 {1} \u090f\u0932\u0947\u092e\u0947\u0928\u094d\u091f \u092e\u0947\u0902 \u0928\u093f\u0930\u094d\u0926\u093f\u0937\u094d\u091f \u0915\u094d\u0932\u093e\u0938 \u0915\u0940 \u0935\u0930\u094d\u0924\u0928\u0940 \u0920\u0940\u0915 \u0939\u0948 \u0914\u0930 \u0915\u094d\u0932\u093e\u0938 \u091c\u0930 \u092e\u0947\u0902 \u092e\u094c\u091c\u0942\u0926 \u0939\u0948 
-
-# 0 - Class name
-# 1 - EJB Class name
-1.wrong.class.type        \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0915\u094d\u0932\u093e\u0938
-2.wrong.class.type        \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0915\u094d\u0932\u093e\u0938 {0}
-3.wrong.class.type        \u0915\u094d\u0932\u093e\u0938 {0 } \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0939\u0948, \u092f\u0939 {1 } \u0915\u094b \u090f\u0915\u094d\u0938\u091f\u0947\u0902\u0921 \u0928\u0939\u0940\u0902 \u0915\u0930\u0924\u0940
-# 0 - method name
-# 1 - full method
-# 2 - remote|home
-# 3 - interface name
-# 4 - EJB Class name
-1.no.busines.method       \u0910\u0938\u093e \u0915\u094b\u0908 \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 \u0928\u0939\u0940\u0902
-2.no.busines.method       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {0 } \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e .
-3.no.busines.method       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {1 } \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f(\u0932\u093e\u0917\u0942) \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e . \u092f\u0939 \u092e\u0947\u0925\u0921 {2 } \u0907\u0902\u091f\u0930\u092b\u0947\u0938 {3 } \u092e\u0947\u0902 \u0918\u094b\u0937\u093f\u0924 \u0915\u093f\u092f\u093e \u0917\u092f\u093e \u0925\u093e \u0932\u0947\u0915\u093f\u0928 \u0908.\u091c.\u092c\u0940 \u0915\u094d\u0932\u093e\u0938 \u092e\u0947\u0902 \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f(\u0932\u093e\u0917\u0942) \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e 
-
-# fail(b, "no.busines.method.args", interfaceMethods[i].getName(), interfaceMethods[i].toString(), "local", intrface.getName(), beanClass.getName(), differentArgs.size());
-1.no.busines.method.args       \u0910\u0938\u093e \u0915\u094b\u0908 \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921  \u0928\u0939\u0940\u0902 \u0939\u0948. \u0917\u0932\u0924 \u0906\u0930\u094d\u0917\u0941\u092e\u0947\u0902\u091f\u094d\u0938 \u0907\u0938\u094d\u0924\u0947\u092e\u093e\u0932 \u0915\u093f\u092f\u0947 \u0939\u0948 .
-2.no.busines.method.args       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {0 } \u0915\u0947 \u0906\u0930\u094d\u0917\u0941\u092e\u0947\u0902\u091f\u094d\u0938 \u092e\u0948\u091a \u0928\u0939\u0940\u0902 \u0915\u0930\u0924\u0947 .
-3.no.busines.method.args       Business method {1} not implemented. The method was declared in the {2} interface {3}, but not implemented in the ejb class {4}.  There are {5} method that have the same name but different arguments.
-
-# fail(b, "no.busines.method.case", interfaceMethods[i].getName(), interfaceMethods[i].toString(), "local", intrface.getName(), beanClass.getName(), differentCase.size());
-1.no.busines.method.case       No such business method.  Possible case-sensitive mismatch.
-2.no.busines.method.case       Business method {0} not implemented.  Possible case-sensitive mismatch.
-3.no.busines.method.case       Business method {1} not implemented. The method was declared in the {2} interface {3}, but not implemented in the ejb class {4}.  There are {5} method that have the same name but using a different case.
-
-# 0 - home interface
-# 1 - remote interface
-1.no.home.create          No create method.
-2.no.home.create          No create method in {0}.
-3.no.home.create          The home interface {0} must declare at least one create method. Example:\n\n\tpublic {1} create() throws javax.ejb.CreateException, java.rmi.RemoteException;
-
-# 1 - EJB Class name
-# 2 - create name
-# 3 - create params
-1.session.no.ejb.create     Create method not implemented.
-2.session.no.ejb.create     Create method not implemented: {1}({2}).
-3.session.no.ejb.create     There should be a create method in the bean class {0} with the following signature:\n\n\tpublic void {1}({2}) throws javax.ejb.CreateException
-
-# 1 - EJB Class name
-# 2 - create name
-# 3 - primary key class
-# 4 - create params
-1.entity.no.ejb.create    Create method not implemented.
-2.entity.no.ejb.create    Create method not implemented: {2}({3}).
-3.entity.no.ejb.create    There should be a create method in the bean class {0} with the following signature:\n\n\tpublic {1} {2}({3}) throws javax.ejb.CreateException
-
-#This is being used in a method which is not called by any other method -- commenting out for now
-# 1 - EJB Class name
-# 2 - create name
-# 3 - create params
-#1.no.ejb.post.create      No ejbPostCreate method
-#2.no.ejb.post.create      Missing create method: {1}({2})
-#3.no.ejb.post.create      Entity create method with no matching ejbPostCreate.  There should be an ejbPostCreate method in the bean class {0} with the following signature:\n\n\tpublic void {1}({2}) throws javax.ejb.CreateException
-
-# warn(b, "unused.ejb.create", b.getEjbClass(), ejbCreate.getName(), paramString, create.toString());
-1.unused.ejb.create       Unused ejbCreate method
-2.unused.ejb.create       Unused ejbCreate method: {1}({2})
-3.unused.ejb.create       Create method will never be called.  The bean class {0} defines the create method {1}({2}), but there is no matching {3}({2}) method in the home or local-home interfaces.
-
-# warn(b, "unused.ejbPostCreate", b.getEjbClass(), postCreate.getName(), paramString, ejbCreate.toString());
-1.unused.ejbPostCreate       Unused ejbPostCreate method
-2.unused.ejbPostCreate       Unused ejbPostCreate method: {1}({2})
-3.unused.ejbPostCreate       PostCreate method will never be called.  The bean class {0} defines the create method {1}({2}), but there is no matching {3}({2}) method defined in the bean class.
-
-
-# 0 - Class name
-# 1 - Element (home, ejb-class, remote)
-# 2 - Bean name
-# 3 - Dependent Class name
-1.misslocated.class           Misslocated class
-2.misslocated.class           Misslocated class {0}
-3.misslocated.class           The class {0} was found in a parent classloader and was loaded from there rather than this jar.  However, a dependent class {3} was not found in the parent classloader.  \n\nThere are two ways to fix this:\n\nOne, remove the class {0} from the jar in the parent classloader to ensure the class is only loaded from this jar.\n\nTwo, move the dependent class {3} and any other dependent classes into the jar in the parent classloader.
-
-# 0 - Referring Class name
-# 1 - Dependent Class name
-# 2 - Element (home, ejb-class, remote)
-# 3 - Bean name
-# fail(b, "missing.dependent.class", className, missingClass, type, b.getEjbName());
-1.missing.dependent.class           Missing dependent class or library
-2.missing.dependent.class           Missing dependent class or library: {1} needed by {0}
-3.missing.dependent.class           The class {1} not found and is referenced by the <{2}> class {0}.  The Check that the class or related library is available in the classpath
-
-
-# CheckAssemblyBindings.java
-# fail("InterceptorBinding", "interceptorBinding.noSuchEjbName", binding.getEjbName(), join(interceptorClasses, ","));
-1.interceptorBinding.noSuchEjbName = Referenced EJB does not exist
-2.interceptorBinding.noSuchEjbName = Referenced EJB does not exist: {0}
-3.interceptorBinding.noSuchEjbName = Binding refers to an EJB, {0}, that does not exist.  Interceptors listed in binding: {1}
-
-# fail("InterceptorBinding", "interceptorBinding.ejbNameRequiredWithMethod", binding.getMethod().getMethodName(), join(interceptorClasses, ","));
-1.interceptorBinding.ejbNameRequiredWithMethod = ejb-name required with method binding
-2.interceptorBinding.ejbNameRequiredWithMethod = ejb-name required with binding on method "{0}".
-3.interceptorBinding.ejbNameRequiredWithMethod = Binding an interceptor to a specific method requires the ejb-name of the bean to also be specified.  Fix binding on method "{0}" for interceptors {1}.
-
-# fail("MethodPermission", "methodPermission.ejbNameRequired", method.getMethodName(), join(permission.getRoleName(), ","));
-1.methodPermission.ejbNameRequired =  ejb-name required for method-permission
-2.methodPermission.ejbNameRequired =  ejb-name required for method-permission: {0}
-3.methodPermission.ejbNameRequired =  Assinging a method-permission requires the ejb-name of the bean to also be specified.  Fix method-permission on method "{0}" for security roles {1}.
-
-# fail("MethodPermission", "methodPermission.noSuchEjbName", method.getEjbName(), method.getMethodName(), join(permission.getRoleName(), ","));
-1.methodPermission.noSuchEjbName = Referenced EJB does not exist
-2.methodPermission.noSuchEjbName = Referenced EJB does not exist: {0} on method "{1}".
-3.methodPermission.noSuchEjbName = Method-permission refers to an EJB, {0}, that does not exist.  Fix method-permission on method "{0}" for security roles {1}.
-
-# fail("ContainerTransaction", "containerTransaction.ejbNameRequired", method.getMethodName(), transaction.getTransAttribute());
-1.containerTransaction.ejbNameRequired = ejb-name required for container-transaction
-2.containerTransaction.ejbNameRequired = ejb-name required for container-transaction: {0}
-3.containerTransaction.ejbNameRequired = Assinging a container-transaction requires the ejb-name of the bean to also be specified.  Fix container-transaction on method "{0}" with transaction attribute {1}.
-
-# fail("ContainerTransaction", "containerTransaction.noSuchEjbName", method.getMethodName(), method.getEjbName(), transaction.getTransAttribute());
-1.containerTransaction.noSuchEjbName = Referenced EJB does not exist
-2.containerTransaction.noSuchEjbName = Referenced EJB does not exist: {0} on method "{1}".
-3.containerTransaction.noSuchEjbName = Container-transaction refers to an EJB, {0}, that does not exist.  Fix container-transaction on method "{0}" with transaction attribute {1}.
-
-# CheckCallbacks.java
-# fail(componentName, "aroundInvoke.badReturnType", aroundType, aroundInvoke.getMethodName(), returnType.getName(), aroundInvoke.getClassName());
-1.aroundInvoke.badReturnType = {0} method must return java.lang.Object
-2.aroundInvoke.badReturnType = {0} method must return java.lang.Object: method "{1}" returns "{2}"
-3.aroundInvoke.badReturnType = {0} method "{1}" in class {3} illegally returns {2} instead of java.lang.Object.  Change the method signature to "java.lang.Object {1}(javax.ejb.InvocationContext) throws java.lang.Exception"
-
-# fail(componentName, "aroundInvoke.mustThrowException", aroundType, aroundInvoke.getMethodName(), aroundInvoke.getClassName());
-1.aroundInvoke.mustThrowException = {0} method must declare 'throws Exception'
-2.aroundInvoke.mustThrowException = {0} method must declare 'throws Exception': method "{1}"
-3.aroundInvoke.mustThrowException = {0} method "{1}" must declare java.lang.Exception in the throws clause.  Change the method signature to "java.lang.Object {1}(javax.ejb.InvocationContext) throws java.lang.Exception"
-
-# fail(componentName, "aroundInvoke.missing", aroundType, aroundInvoke.getMethodName(), aroundInvoke.getClassName());
-1.aroundInvoke.missing = {0} method missing
-2.aroundInvoke.missing = {0} method missing: "{1}" in class {2}
-3.aroundInvoke.missing = {0} method "{1}" not found in class {2}.  The required method signature is "java.lang.Object {1}(javax.ejb.InvocationContext) throws java.lang.Exception"
-
-# fail(componentName, "aroundInvoke.invalidArguments", aroundType, aroundInvoke.getMethodName(), getParameters(possibleMethods.get(0)), aroundInvoke.getClassName());
-1.aroundInvoke.invalidArguments = Invalid {0} arguments
-2.aroundInvoke.invalidArguments = Invalid {0} arguments: {1}({2})
-3.aroundInvoke.invalidArguments = {0} method signature "{1}({2})" in class {3} has invalid arguments.  The required method signature is "java.lang.Object {1}(javax.ejb.InvocationContext) throws java.lang.Exception"
-
-# fail(componentName, "aroundInvoke.missing.possibleTypo", aroundType, aroundInvoke.getMethodName(), possibleMethods.size(), aroundInvoke.getClassName());
-1.aroundInvoke.missing.possibleTypo = {0} method missing or invalid
-2.aroundInvoke.missing.possibleTypo = {0} method missing or invalid: looked for "{1}(javax.ejb.InvocationContext)" in class {3}
-3.aroundInvoke.missing.possibleTypo = {0} method missing or invalid.  There are {2} methods with the name "{1}" visible in class {3}, none have the required signature of "java.lang.Object {1}(javax.ejb.InvocationContext) throws java.lang.Exception"
-
-# fail(bean, "callback.badReturnType", type, callback.getMethodName(), returnType.getName(), callback.getClassName());
-1.callback.badReturnType = {0} method must return 'void'
-2.callback.badReturnType = {0} method must return 'void': method {1} returns {2}
-3.callback.badReturnType = {0} method "{1}" in class {3} illegally returns {2} instead of void.  Change the method signature to "void {1}()"
-
-# fail(bean, "callback.badModifier", type, callback.getMethodName(), callback.getClassName());
-1.callback.badModifier = {0} method must not be final and static
-2.callback.badModifier = {0} method must not be final and static : method {1}
-3.callback.badModifier = {0} method "{1}" in class {2} must not be final and static
-
-# fail(bean, "callback.missing", type, callback.getMethodName(), callback.getClassName());
-1.callback.missing = {0} method missing
-2.callback.missing = {0} method missing: "{1}" in class {2}
-3.callback.missing = {0} method "{1}" not found in class {2}.  The required method signature is "void {1}()"
-
-# fail(bean, "callback.invalidArguments", type, callback.getMethodName(), getParameters(possibleMethods.get(0)), callback.getClassName());
-1.callback.invalidArguments = Invalid {0} arguments
-2.callback.invalidArguments = Invalid {0} arguments. Found: {1}({2}). Required: {1}({4}) 
-3.callback.invalidArguments = {0} method signature "{1}({2})" in class {3} has invalid arguments.  The required method signature is "void {1}(4)"
-
-# fail(bean, "callback.missing.possibleTypo", type, callback.getMethodName(), possibleMethods.size(), callback.getClassName());
-1.callback.missing.possibleTypo = {0} method missing or invalid
-2.callback.missing.possibleTypo = {0} method missing or invalid: looked for "void {1}({4})" in class {3}
-3.callback.missing.possibleTypo = {0} method missing or invalid.  There are {2} methods with the name "{1}" visible in class {3}, none have the required signature of "void {1}(4)"
-
-# fail(bean, "callback.sessionSynchronization.invalidUse", class)
-1.callback.sessionSynchronization.invalidUse = Session synchronization annotations and configurations in deployment plan should not be used while SessionSynchronization interface is implemented by the bean class.
-2.callback.sessionSynchronization.invalidUse = Session synchronization annotations and configurations in deployment plan should not be used while SessionSynchronization interface is implemented by the bean class {0}.
-3.callback.sessionSynchronization.invalidUse = Session synchronization annotations and configurations in deployment plan should not be used while SessionSynchronization interface is implemented by the bean class {0}.
-
-# fail(bean, "callback.missing.possibleTypo", type, callback.getMethodName(), possibleMethods.size(), callback.getClassName());
-1.callback.sessionbean.invalidusage = Invalid usage of @{0} in a class which implements javax.ejb.SessionBean
-2.callback.sessionbean.invalidusage = Invalid usage of @{0} in a class which implements javax.ejb.SessionBean
-3.callback.sessionbean.invalidusage = Invalid usage of @{0} in {2} which implements javax.ejb.SessionBean. @{0} was wrongly used on the method {1}(). The usage would have been correct if {2} did not implement javax.ejb.SessionBean.
-
-# fail(bean, "timeout.badReturnType", callback.getMethodName(), returnType.getName());
-1.timeout.badReturnType = Timeout method must return 'void'
-2.timeout.badReturnType = Timeout method must return 'void': method {0} returns {1}
-3.timeout.badReturnType = Timeout method "{0}" illegally returns {1} instead of void.  Change the method signature to "void {0}(javax.ejb.Timer)"
-
-#Don't think this is ever going to be used, commenting it out for now. If there is a case where this key can be used, please uncomment it and write a test for it
-# fail(bean, "timeout.missing", timeout.getMethodName());
-#1.timeout.missing = Timeout method missing
-#2.timeout.missing = Timeout method missing: "{0}" in class {1}
-#3.timeout.missing = Timeout method "{0}" not found in class {1}.  The required method signature is "void {0}(javax.ejb.Timer)"
-
-# fail(bean, "timeout.invalidArguments", timeout.getMethodName(), getParameters(possibleMethods.get(0)));
-1.timeout.invalidArguments = Invalid Timeout arguments
-2.timeout.invalidArguments = Invalid Timeout arguments: {0}({1})
-3.timeout.invalidArguments = Timeout method signature "{0}({1})" has invalid arguments.  The required method signature is "void {0}(javax.ejb.Timer)"
-
-# fail(bean, "timeout.missing.possibleTypo", timeout.getMethodName(), possibleMethods.size());
-1.timeout.missing.possibleTypo = Timeout method missing or invalid
-2.timeout.missing.possibleTypo = Timeout method missing or invalid: looked for "void {0}(javax.ejb.Timer)"
-3.timeout.missing.possibleTypo = Timeout method missing or invalid.  There are {1} methods with the name "{0}" visible, either the wrong one has been annotated with @Timeout or none have the required signature of "void {0}(javax.ejb.Timer). A bean should have only one method annotated with @Timeout and the method signature must match void {0}(javax.ejb.Timer)"
-
-# fail(componentName,"timeout.tooManyMethods",timeoutMethods.size(),Join.join(",", timeoutMethods));
-1.timeout.tooManyMethods = More than one method annotated with @Timeout
-2.timeout.tooManyMethods = More than one method annotated with @Timeout
-3.timeout.tooManyMethods = More than one method annotated with @Timeout.  There are {0} methods annotated with @Timeout. Make sure you have only one method annotated with @Timeout. Methods annotated with @Timeout are {1}
-# fail("Interceptor", "interceptor.callback.badReturnType", type, callback.getMethodName(), returnType.getName(), interceptorClass.getName());
-1.interceptor.callback.badReturnType = {0} method must return "void"
-2.interceptor.callback.badReturnType = {0} method must return "void": method {2} returns {3} instead
-3.interceptor.callback.badReturnType = method "{2}" in class {0} illegally returns {3} instead of void.  Change the method signature to "void {2}(javax.ejb.InvocationContext)"
-
-# fail("Interceptor", "interceptor.callback.missing", type, callback.getMethodName(), interceptorClass.getName());
-1.interceptor.callback.missing = {0} method missing
-2.interceptor.callback.missing = {0} method missing: "{1}" in class {2}
-3.interceptor.callback.missing = {0} method "{1}" not found in class {2}.  The required method signature is "void {1}(javax.ejb.InvocationContext)"
-
-# fail("Interceptor", "interceptor.callback.invalidArguments", type, callback.getMethodName(), getParameters(possibleMethods.get(0)), interceptorClass.getName());
-1.interceptor.callback.invalidArguments = Invalid {0} arguments
-2.interceptor.callback.invalidArguments = Invalid {0} arguments: {1}({2}) in class {3}
-3.interceptor.callback.invalidArguments = {0} method signature "{1}({2})" in class {3} has invalid arguments.  The required method signature is "void {1}(javax.ejb.InvocationContext)"
-
-# fail("Interceptor", "interceptor.callback.missing.possibleTypo", type, callback.getMethodName(), possibleMethods.size(), interceptorClass.getName());
-1.interceptor.callback.missing.possibleTypo = {0} method missing or invalid
-2.interceptor.callback.missing.possibleTypo = {0} method missing or invalid: looked for "void {1}(javax.ejb.InvocationContext)" in class {3}
-3.interceptor.callback.missing.possibleTypo = {0} method missing or invalid.  There are {2} methods with the name "{1}" visible in class {3}, none have the required signature of "void {1}()"
-
-#CheckAssemblyBindings.java
-# warn("Interceptors", "interceptor.unused", clazz);
-1.interceptor.unused = {0} is not intercepting any bean
-2.interceptor.unused = {0} is not intercepting any bean. It should be used in one of the interceptor-binding elements of the deployment descriptor.
-3.interceptor.unused = {0} is not intercepting any bean. It should be used in one of the interceptor-binding elements of the deployment descriptor. An example usage might be:\r\n\
-<interceptor-binding>\r\n\
-\u0020\u0020<ejb-name>Your ejb name here</ejb-name>\r\n\
-\u0020\u0020<interceptor-class>{0}</interceptor-class>\r\n\
-<interceptor-binding>
-
-# CheckInjectionTargets.java
-# warn(bean, "injectionTarget.nameContainsSet", target.getInjectionTargetName(), shortNameInvalid, shortNameCorrect, correctName, reference.getName(), reference.getClass().getSimpleName());
-1.injectionTarget.nameContainsSet = Corrected invalid injection-target-name
-2.injectionTarget.nameContainsSet = Corrected invalid injection-target-name: {0}
-3.injectionTarget.nameContainsSet = The injection-target-name "{0}" for setter methods should not begin with "set".  The last portion of the name "{1}" has been automatically corrected to "{2}".  Update the descriptor with the correct injection-target-name of "{3}" to avoid receiving this warning.  Resource to be injected is "{4}".
-
-# fail("Asynchronous", "asynchronous.badReturnType", asyncMethod.getMethodName(), returnType.getName(), beanClass.getName());
-1.asynchronous.badReturnType = asynchronous method must return "void" or "Future<V>"
-2.asynchronous.badReturnType = asynchronous} method must return "void" or "Future<V>" : method {0} returns {1} in class {2}
-3.asynchronous.badReturnType = asynchronous method "{0}" in class {2} illegally returns {1} instead of void or Future<V>.  Change the method signature to "void|Future<V> {0}(...)"
-
-# fail("Asynchronous", "asynchronous.missing", asyncMethod.getMethodName(), beanClass.getName(), getParamters(asyncMethod));
-1.asynchronous.missing = asynchronous method {0} missing
-2.asynchronous.missing = asynchronous method missing: "{0}" in class {1}
-3.asynchronous.missing = asynchronous method "{1}" not found in class {1}.  The required method signature is "void|Future<V> {0}({2})"
-
-# fail("Asynchronous", "asynchronous.missing", asyncMethod.getMethodName(), beanClass.getName(), getParamters(asyncMethod));
-1.asynchronous.badExceptionType = asynchronous method {0} should not throw any ApplicationException while its return type is void.
-2.asynchronous.badExceptionType = asynchronous method {0} in class {1} should not throw any ApplicationException while its return type is void.
-3.asynchronous.badExceptionType = asynchronous method {0} in class {1} should not throw ApplicationException "{2}" while its return type is void.
-
-# warn("Asynchronous", "asynchronous.methodignored", beanClass.getName(), methodName);
-1.asynchronous.methodignored = non-public method {1} in class {0} is ignored, although the class is annoated with @Asynchronous
-2.asynchronous.methodignored = non-public method {1} in class {0} is ignored, although the class is annoated with @Asynchronous
-3.asynchronous.methodignored = non-public method {1} in class {0} is ignored, although the class is annoated with @Asynchronous
-
-# AnnotationDeployer.java
-# warn("client.missingMainClass", className)
-# fail("client.missingMainClass", className)
-1.client.missingMainClass = Missing Main-Class
-2.client.missingMainClass = Missing Main-Class: {0}
-3.client.missingMainClass = The Main-Class {0} specified in the MANIFEST.MF file does not exist in the jar.
-
-# fail(ejbName, "xml.localRemote.conflict", interfce);
-1.xml.localRemote.conflict = Interface illegally declared as both <business-local> and <business-remote>.
-2.xml.localRemote.conflict = Interface illegally declared as both <business-local> and <business-remote>: {0}
-3.xml.localRemote.conflict = When declaring business interface as <business-local> in an ejb-jar.xml file, the same interface cannot be listed as <business-remote>.  Revise the declaration of business interface "{0}" so that it is either local or remote, not both.
-
-# fail(ejbName, "xml.localRemote.conflict", interfce);
-1.ann.localRemote.generalconflict = Interface illegally declared as both local and remote in some combination of xml and annotations.
-2.ann.localRemote.generalconflict = Interface illegally declared as both local and remote in some combination of xml and annotations: {0}
-3.ann.localRemote.generalconflict = When declaring business interface as local in xml or annotations, the same interface cannot be listed as remote.  Revise the declaration of business interface "{0}" so that it is either local or remote, not both.
-
-# fail(ejbName, "ann.remote.noAttributes", join(", ", interfaces));
-1.ann.remote.noAttributes = Ambiguous @Remote() usage on bean class
-2.ann.remote.noAttributes = Ambiguous @Remote() usage on bean class.  Must list interfaces explicitly in annotation.
-3.ann.remote.noAttributes = When annotating a bean class as @Remote with no annotation attributes, the bean must implement exactly one business interface, no more and no less.  List the remote interfaces explicitly in the annotation, such as @Remote('{'{0}'}').  Alternatively, apply the @Remote annotation to the individual interfaces and remove it from the bean class.
-
-#This one is the same as ann.localremote.ambiguous -- commenting it out for now
-# fail(ejbName, "ann.remoteLocal.ambiguous", join(", ", interfaces));
-#1.ann.remoteLocal.ambiguous = Ambiguous @Remote and @Local usage on bean class.
-#2.ann.remoteLocal.ambiguous = Ambiguous @Remote and @Local usage on bean class.  Must list interfaces explicitly in @Remote annotation.
-#3.ann.remoteLocal.ambiguous = When annotating a bean class as @Remote with no annotation attributes you must not also annotate it with @Local with no attributes.  List the remote interfaces explicitly in the annotation, such as @Remote(\{{0}\}).  Alternatively, apply the @Remote annotation to the individual interfaces and remove it from the bean class.
-
-# This one is not used anywhere in code and is the same as ann.localRemote.conflict -- commenting it out for now
-# fail(ejbName, "ann.remoteLocal.conflict", join(", ", interfaces));
-#1.ann.remoteLocal.conflict = @Remote annotation in bean class conflicts with @Local in interface.
-#2.ann.remoteLocal.conflict = @Remote annotation in bean class conflicts with @Local in interface "{0}".
-#3.ann.remoteLocal.conflict = When annotating a bean class as @Remote, the corresponding business interfaces cannot be annotated with @Local.  Revise the business interface "{0}".
-
-# fail(ejbName, "ann.local.noAttributes", join(", ", interfaces));
-1.ann.local.noAttributes = Ambiguous @Local() usage on bean class
-2.ann.local.noAttributes = Ambiguous @Local() usage on bean class.  Must list interfaces explicitly in annotation.
-3.ann.local.noAttributes = When annotating a bean class as @Local with no annotation attributes, the bean must implement exactly one business interface, no more and no less.  List the local interfaces explicitly in the annotation, such as @Local('{'{0}'}').  Alternatively, apply the @Local annotation to the individual interfaces and remove it from the bean class.
-
-# fail(ejbName, "ann.localRemote.ambiguous", join(", ", interfaces));
-1.ann.localRemote.ambiguous = Ambiguous @Local and @Remote usage on bean class.
-2.ann.localRemote.ambiguous = Ambiguous @Local and @Remote usage on bean class.  Must list interfaces explicitly in @Local annotation.
-3.ann.localRemote.ambiguous = When annotating a bean class as @Local with no annotation attributes you must not also annotate it with @Remote.  List the local interfaces explicitly in the annotation, such as @Local('{'{0}'}').  Alternatively, apply the @Local annotation to the individual interfaces and remove it from the bean class.
-
-# fail(ejbName, "ann.localRemote.conflict", join(", ", interfaces));
-1.ann.localRemote.conflict = @Local annotation in bean class conflicts with @Remote in interface.
-2.ann.localRemote.conflict = @Local annotation in bean class conflicts with @Remote in interface "{0}".
-3.ann.localRemote.conflict = When annotating a bean class as @Local, the corresponding business interfaces cannot be annotated with @Remote.  Revise the business interface "{0}".
-
-# fail(ejbName, "ann.remoteOrLocal.ejbHome", annotationName, interfce.getName());
-1.ann.remoteOrLocal.ejbHome = @{0} used in bean class lists a javax.ejb.EJBHome interface.
-2.ann.remoteOrLocal.ejbHome = @{0} used in bean class lists a javax.ejb.EJBHome interface. Use @RemoteHome({1})
-3.ann.remoteOrLocal.ejbHome = When applied to a bean class, the @{0} annotation must only list business interfaces and cannot list legacy EJBHome interfaces.  EJBHome interfaces can be annotated on the bean class with @RemoteHome({1})
-
-# fail(ejbName, "ann.remoteOrLocal.ejbLocalHome", annotationName, interfce.getName());
-1.ann.remoteOrLocal.ejbLocalHome = @{0} used in bean class lists a javax.ejb.EJBLocalHome interface.
-2.ann.remoteOrLocal.ejbLocalHome = @{0} used in bean class lists a javax.ejb.EJBLocalHome interface. Use @LocalHome({1})
-3.ann.remoteOrLocal.ejbLocalHome = When applied to a bean class, the @{0} annotation must only list business interfaces and cannot list legacy EJBLocalHome interfaces.  EJBLocalHome interfaces can be annotated on the bean class with @LocalHome({1})
-
-# fail(ejbName, "ann.remoteOrLocal.ejbObject", annotationName, interfce.getName());
-1.ann.remoteOrLocal.ejbObject = @{0} used in bean class lists a javax.ejb.EJBObject interface.
-2.ann.remoteOrLocal.ejbObject = @{0} used in bean class lists a javax.ejb.EJBObject interface. Use @RemoteHome with home interface of "{1}".
-3.ann.remoteOrLocal.ejbObject = When applied to a bean class, the @{0} annotation must only list business interfaces and cannot list legacy EJBObject interfaces.  The EJBHome of interface for "{1}" can be annotated on the bean class with @RemoteHome
-
-# fail(ejbName, "ann.remoteOrLocal.ejbLocalObject", annotationName, interfce.getName());
-1.ann.remoteOrLocal.ejbLocalObject = @{0} used in bean class lists a javax.ejb.EJBLocalObject interface.
-2.ann.remoteOrLocal.ejbLocalObject = @{0} used in bean class lists a javax.ejb.EJBLocalObject interface. Use @LocalHome with home interface of "{1}".
-3.ann.remoteOrLocal.ejbLocalObject = When applied to a bean class, the @{0} annotation must only list business interfaces and cannot list legacy EJBLocalObject interfaces.  The EJBLocalHome of interface for "{1}" can be annotated on the bean class with @LocalHome
-
-# fail(ejbName, "ann.remoteOrLocal.ejbLocalObject", annotationName, interfce.getName());
-1.ann.remoteOrLocal.converse.parent = Interface annotated @Local or @Remote is annotated conversely in parent interface.
-2.ann.remoteOrLocal.converse.parent = Interface annotated @Local or @Remote is annotated conversely in parent interface. Fix it by annotating both the interfaces with the same annotation
-3.ann.remoteOrLocal.converse.parent = Interface {0} is annotated with @{1} whereas its parent interface {2} is annotated with @{3}. Ensure that both the interfaces are either annotated with @{1} or @{3}. An example would be:\r\n\
-@{1}\r\n\
-public interface {2}'{}'\r\n\
-@{1}\r\n\
-public interface {0} extends {2}'{}'
-
-# warn(bean, "ignoredMethodAnnotation", annotationType, beanType, className, methodName);
-1.ignoredMethodAnnotation = @{0} is ignored for beans of type {1}
-2.ignoredMethodAnnotation = @{0} is ignored for beans of type {1}.  Class: {2} Method: {3}
-3.ignoredMethodAnnotation = Beans of type {1} are not allowed to use the @{0} annotation.  This annotation is only permitted on {1} beans.  The usage of @{0} on bean class {2} method {3} will be ignored and the annotation should be removed.
-
-# warn(bean, "ignoredClassAnnotation", annotationType, beanType, className);
-1.ignoredClassAnnotation = @{0} is ignored for beans of type {1}
-2.ignoredClassAnnotation = @{0} is ignored for beans of type {1}.  Class: {2}
-3.ignoredClassAnnotation = Beans of type {1} are not allowed to use the @{0} annotation.  This annotation is only permitted on {1} beans.  The usage of @{0} on bean class {2} will be ignored and the annotation should be removed.
-
-# fail(bean, "persistenceContextExtented.nonStateful", refName, beanType);
-1.persistenceContextExtented.nonStateful = Non-Stateful use of PersistenceContextType.EXTENDED
-2.persistenceContextExtented.nonStateful = Non-Stateful use of PersistenceContextType.EXTENDED in ref {0}
-3.persistenceContextExtented.nonStateful = {1} ejbs are not capable of using EntityManagers with EXTENTED persistence.  Convert your bean to a Stateful ejb or update the "{0}" PersistenceContext reference to PersistenceContextType.TRANSACTION.
-
-# fail(consumer.getJndiConsumerName(), "resourceRef.onEntityManager", refName);
-1.resourceRef.onEntityManager = Mistaken use of @Resource on an EntityManager reference.  Use @PersistenceContext.
-2.resourceRef.onEntityManager = Mistaken use of @Resource on an EntityManager reference.  Use @PersistenceContext for ref "{0}"
-3.resourceRef.onEntityManager = The @Resource annotation cannot be used on references to javax.persistence.EntityManager.  Change the annotation to @PersistenceContext for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "resourceRef.onEntityManagerFactory", refName);
-1.resourceRef.onEntityManagerFactory = Mistaken use of @Resource on an EntityManagerFactory reference.  Use @PersistenceUnit.
-2.resourceRef.onEntityManagerFactory = Mistaken use of @Resource on an EntityManagerFactory reference.  Use @PersistenceUnit for ref "{0}"
-3.resourceRef.onEntityManagerFactory = The @Resource annotation cannot be used on references to javax.persistence.EntityManagerFactory.  Change the annotation to @PersistenceUnit for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "ejbAnnotation.onClassWithNoBeanInterface");
-1.ejbAnnotation.onClassWithNoBeanInterface = Missing required "beanInterface" attribute on class-level @EJB usage
-2.ejbAnnotation.onClassWithNoBeanInterface = Missing required "beanInterface" attribute on class-level @EJB usage
-3.ejbAnnotation.onClassWithNoBeanInterface = The "beanInterface" attribute was not specified for the class level annotation @EJB. It is mandatory for all class level @EJB annotations.
-
-# fail(consumer.getJndiConsumerName(), "ejbAnnotation.onClassWithNoName");
-1.ejbAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @EJB usage
-2.ejbAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @EJB usage
-3.ejbAnnotation.onClassWithNoName = The "name" attribute was not specified for the class level annotation @EJB. It is mandatory for all class level @EJB annotations.
-
-# fail(consumer.getJndiConsumerName(), "persistenceContextAnnotation.onEntityManagerFactory", persistenceContextRef.getName());
-1.persistenceContextAnnotation.onEntityManagerFactory = Mistaken use of @PersistenceContext on an EntityManagerFactory reference.  Use @PersistenceUnit.
-2.persistenceContextAnnotation.onEntityManagerFactory = Mistaken use of @PersistenceContext on an EntityManagerFactory reference.  Use @PersistenceUnit for ref "{0}"
-3.persistenceContextAnnotation.onEntityManagerFactory =  The @PersistenceContext annotation only applies to javax.persistence.EntityManager and cannot be used on references to javax.persistence.EntityManagerFactory.  Change the annotation to @PersistenceUnit for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "persistenceContextAnnotation.onNonEntityManager", persistenceContextRef.getName());
-1.persistenceContextAnnotation.onNonEntityManager = Use of @PersistenceContext only applies to EntityManager references
-2.persistenceContextAnnotation.onNonEntityManager = Use of @PersistenceContext only applies to EntityManager references.  Fix ref "{0}"
-3.persistenceContextAnnotation.onNonEntityManager = The @PersistenceContext annotation only applies to javax.persistence.EntityManager and cannot be used on references of other types.  Change the annotation for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "persistenceUnitAnnotation.onEntityManager", persistenceUnitRef.getName());
-1.persistenceUnitAnnotation.onEntityManager = Mistaken use of @PersistenceUnit on an EntityManager reference.  Use @PersistenceContext
-2.persistenceUnitAnnotation.onEntityManager = Mistaken use of @PersistenceUnit on an EntityManager reference.  Use @PersistenceContext for ref "{0}"
-3.persistenceUnitAnnotation.onEntityManager = The @PersistenceUnit annotation only applies to javax.persistence.EntityManagerFactory and cannot be used on references to javax.persistence.EntityManager.  Change the annotation to @PersistenceContext for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "persistenceUnitAnnotation.onNonEntityManagerFactory", persistenceUnitRef.getName());
-1.persistenceUnitAnnotation.onNonEntityManagerFactory = Use of @PersistenceUnit only applies to EntityManager references
-2.persistenceUnitAnnotation.onNonEntityManagerFactory = Use of @PersistenceUnit only applies to EntityManager references.  Fix ref "{0}"
-3.persistenceUnitAnnotation.onNonEntityManagerFactory = The @PersistenceUnit annotation only applies to javax.persistence.EntityManagerFactory and cannot be used on references of other types.  Change the annotation for ref "{0}"
-
-# fail(consumer.getJndiConsumerName(), "resourceAnnotation.onClassWithNoName");
-1.resourceAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @Resource usage
-2.resourceAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @Resource usage
-3.resourceAnnotation.onClassWithNoName = The "name" attribute was not specified for the class level annotation @Resource. It is mandatory for all class level @Resource annotations.
-
-# fail(consumer.getJndiConsumerName(), "resourceAnnotation.onClassWithNoType");
-1.resourceAnnotation.onClassWithNoType = Missing required "type" attribute on class-level @Resource usage
-2.resourceAnnotation.onClassWithNoType = Missing required "type" attribute on class-level @Resource usage
-3.resourceAnnotation.onClassWithNoType = The "type" attribute was not specified for the class level annotation @Resource. It is mandatory for all class level @Resource annotations.
-
-# fail(consumer.getJndiConsumerName(), "persistenceContextAnnotation.onClassWithNoName", persistenceContext.unitName());
-1.persistenceContextAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @PersistenceContext usage
-2.persistenceContextAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @PersistenceContext usage.
-3.persistenceContextAnnotation.onClassWithNoName = The "name" attribute was not specified for the class level annotation @PersistenceContext with unitName="{0}". It is mandatory for all class level @PersistenceContext annotations.
-
-# fail(consumer.getJndiConsumerName(), "persistenceUnitAnnotation.onClassWithNoName", persistenceUnit.unitName());
-1.persistenceUnitAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @PersistenceUnit usage
-2.persistenceUnitAnnotation.onClassWithNoName = Missing required "name" attribute on class-level @PersistenceUnit usage.
-3.persistenceUnitAnnotation.onClassWithNoName = The "name" attribute was not specified for the class level annotation @PersistenceUnit with unitName="{0}". It is mandatory for all class level @PersistenceUnit annotations.
-
-
-# AutoConfig.java
-# fail(componentName, "persistenceContextRef.noPersistenceUnits", refShortName, unitName);
-1.persistenceContextRef.noPersistenceUnits = Missing required persistence.xml for @PersistenceContext ref
-2.persistenceContextRef.noPersistenceUnits = Missing required persistence.xml for @PersistenceContext ref "{0}" to unit "{1}"
-3.persistenceContextRef.noPersistenceUnits = A persistence unit must be defined via META-INF/persistence.xml to satisfy @PersistenceContext ref "{0}" to unit "{1}".  An example of a suitable persistence.xml might be:\
-  <persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0">\
-    <persistence-unit name="{1}">\
-      <jta-data-source>java:openejb/Resource/myDataSource</jta-data-source>\
-      <non-jta-data-source>java:openejb/Resource/myUnmanagedDataSource</non-jta-data-source>\
-\
-        <properties>\
-        <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>\
-      </properties>\
-    </persistence-unit>\
-  </persistence>\
-
-
-# fail(componentName, "persistenceContextRef.noUnitName", refShortName, join(", ", availableUnits), sampleUnitName );
-1.persistenceContextRef.noUnitName = @PersistenceContext unitName required, multiple units available.
-2.persistenceContextRef.noUnitName = @PersistenceContext unitName required, multiple units available: ref "{0}", available units [{1}]
-3.persistenceContextRef.noUnitName = Use of @PersistenceContext without a unitName is only allowed when there is only a single persistence.xml in the entire application defining exactly one persistence-unit.  Available units for ref {0} are [{1}].  Add the unitName to your declaration, for example:\
-    @PersistenceContext(name="{0}", unitName = "{2}")
-
-# fail(componentName, "persistenceContextRef.vagueMatches", refShortName, unitName, possibleUnits.size(), join(", ", possibleUnits));
-1.persistenceContextRef.vagueMatches = @PersistenceContext unitName has multiple matches.
-2.persistenceContextRef.vagueMatches = @PersistenceContext unitName has multiple matches: unitName "{1}" has {2} possible matches.
-3.persistenceContextRef.vagueMatches = The reference @PersistenceContext(name="{0}", unitName="{1}") cannot be resolved as there are {2} units with the same name.  Update your unitName to one of the following:\
-{3}
-
-# fail(componentName, "persistenceContextRef.noMatches", refShortName, unitName, join(", ", availableUnits));
-1.persistenceContextRef.noMatches = Persistence unit not found
-2.persistenceContextRef.noMatches = Persistence unit not found for @PersistenceContext(name="{0}", unitName="{1}").  Available units [{2}]
-3.persistenceContextRef.noMatches = The persistence unit "{1}" does not exist.  Update the "{0}" PersistenceContext ref to one of the available units [{2}] or declare the unit in a persistence.xml like the following:\
-  <persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0">\
-    <persistence-unit name="{1}">\
-      <jta-data-source>java:openejb/Resource/myDataSource</jta-data-source>\
-      <non-jta-data-source>java:openejb/Resource/myUnmanagedDataSource</non-jta-data-source>\
-\
-        <properties>\
-        <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>\
-      </properties>\
-    </persistence-unit>\
-  </persistence>\
-
-
-# fail(componentName, "persistenceUnitRef.noPersistenceUnits", refShortName, unitName);
-1.persistenceUnitRef.noPersistenceUnits = Missing required persistence.xml for @PersistenceUnit ref
-2.persistenceUnitRef.noPersistenceUnits = Missing required persistence.xml for @PersistenceUnit ref "{0}" to unit "{1}"
-3.persistenceUnitRef.noPersistenceUnits = A persistence unit must be defined via META-INF/persistence.xml to satisfy @PersistenceUnit ref "{0}" to unit "{1}".  An example of a suitable persistence.xml might be:\
-  <persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0">\
-    <persistence-unit name="{1}">\
-      <jta-data-source>java:openejb/Resource/myDataSource</jta-data-source>\
-      <non-jta-data-source>java:openejb/Resource/myUnmanagedDataSource</non-jta-data-source>\
-\
-        <properties>\
-        <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>\
-      </properties>\
-    </persistence-unit>\
-  </persistence>\
-
-
-# fail(componentName, "persistenceUnitRef.noUnitName", refShortName, join(", ", availableUnits), sampleUnitName );
-1.persistenceUnitRef.noUnitName = @PersistenceUnit unitName required, multiple units available.
-2.persistenceUnitRef.noUnitName = @PersistenceUnit unitName required, multiple units available: ref "{0}", available units [{1}]
-3.persistenceUnitRef.noUnitName = Use of @PersistenceUnit witout a unitName is only allowed when there is only a single persistence.xml in the entire application defining exactly one persistence-unit.  Available units for ref {0} are [{1}].  Add the unitName to your declaration, for example:\
-    @PersistenceUnit(name="{0}", unitName = "{2}")
-
-# fail(componentName, "persistenceUnitRef.vagueMatches", refShortName, unitName, possibleUnits.size(), join(", ", possibleUnits));
-1.persistenceUnitRef.vagueMatches = @PersistenceUnit unitName has multiple matches.
-2.persistenceUnitRef.vagueMatches = @PersistenceUnit unitName has multiple matches: unitName "{1}" has {2} possible matches.
-3.persistenceUnitRef.vagueMatches = The reference @PersistenceUnit(name="{0}", unitName="{1}") cannot be resolved as there are {2} units with the same name.  Update your unitName to one of the following:\
-{3}
-
-# fail(componentName, "persistenceUnitRef.noMatches", refShortName, unitName, join(", ", availableUnits));
-1.persistenceUnitRef.noMatches = Persistence unit not found
-2.persistenceUnitRef.noMatches = Persistence unit not found for ref @PersistenceUnit(name="{0}", unitName="{1}").  Available units [{2}]
-3.persistenceUnitRef.noMatches = The persistence unit "{1}" does not exist.  Update the "{0}" PersistenceUnit ref to one of the available units [{2}] or declare the unit in a persistence.xml like the following:\
-  <persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0">\
-    <persistence-unit name="{1}">\
-      <jta-data-source>java:openejb/Resource/myDataSource</jta-data-source>\
-      <non-jta-data-source>java:openejb/Resource/myUnmanagedDataSource</non-jta-data-source>\
-\
-        <properties>\
-        <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>\
-      </properties>\
-    </persistence-unit>\
-  </persistence>\
-
-
-# fail(ejbName, "interfaceAnnotatedAsBean", annotationClass.getSimpleName(), beanClass.getName());
-1.interfaceAnnotatedAsBean = @{0} cannot be applied to an interface.
-2.interfaceAnnotatedAsBean = @{0} cannot be applied to an interface: {1}
-3.interfaceAnnotatedAsBean = Only concrete classes, not interfaces, are allowed to use the @{0} annotation.  Either convert the interface {1} to a class so that it may be used as a valid bean or move the @{0} annotation to the classes that implement this interface.
-
-# fail(ejbName, "abstractAnnotatedAsBean", annotationClass.getSimpleName(), beanClass.getName());
-1.abstractAnnotatedAsBean = @{0} cannot be applied to abstract classes.
-2.abstractAnnotatedAsBean = @{0} cannot be applied to an abstract class: {1}
-3.abstractAnnotatedAsBean = Only concrete classes, not abstract classes, are allowed to use the @{0} annotation.  Either convert the abstract class {1} to a concrete class so that it may be used as a valid bean or move the @{0} annotation to the classes that subclass from this class.
-
-# fail(ejbName, "multiplyAnnotatedAsBean", annotationClass.getSimpleName(), secondAnnotation.getSimpleName(), ejbName, beanClass.getName())
-1.multiplyAnnotatedAsBean = Identical 'name' used in both @{0} and @{1} annotations.
-2.multiplyAnnotatedAsBean = Identical 'name' used in both @{0} and @{1} annotations: name={2}
-3.multiplyAnnotatedAsBean = When attempting to deploy a bean as both @{0} and @{1} different values must be used for the 'name' attributes as all ejb-names must be unique within a given ejb-jar.  Update the @{1} annotation to explicitly set the 'name' attribute to a different value.  For example: @{1}(name = "{1}{2}")
-
-# fail(b, "noInterfaceDeclared.entity", ejbClass.getSimpleName());
-1.noInterfaceDeclared.entity = EJBHome or EJBLocalHome interface required.
-2.noInterfaceDeclared.entity = EJBHome or EJBLocalHome interface required.
-3.noInterfaceDeclared.entity = EJB 2.x and 1.x entity beans require EJBHome or EJBLocalHome interfaces to be accessed.  An example of valid component (i.e. pre-EJB 3.0) interfaces for this bean might be:\
-    public interface {0}Home extends javax.ejb.EJBLocalHome '\u007B' \
-        {0}Object create() throws javax.ejb.CreateException;        \
-    '\u007D' \
-\
-    public interface {0}Object extends javax.ejb.EJBLocalObject '\u007B' \
-        \
-    '\u007D' \
-
-#This is no longer used in code -- commenting out for now
-# fail(b, "noInterfaceDeclared.session", ejbClass.getSimpleName());
-#1.noInterfaceDeclared.session = Business Interface or @WebService annotation required.
-#2.noInterfaceDeclared.session = Business Interface or @WebService annotation required.
-#3.noInterfaceDeclared.session = All EJB 3.0 and earlier Session beans must either implement an interface, declare one via annotation or xml, or be annotated with @javax.jws.WebService.  An example interface for this bean might be:\
-#    @Local\
-#    public interface {0}Local '\u007B' \
-#        // add the methods from {0} you'd like to expose  \
-#    '\u007D' \
-#\
-#Which can then be implemented by the {0} class.\
-
-
-# fail(ejbName, "ann.notAnInterface", annotationName, interfce.getName());
-1.ann.notAnInterface = @{0} lists a non-interface.
-2.ann.notAnInterface = @{0} lists a non-interface: {1}
-3.ann.notAnInterface = All business remote and business local views must be java interfaces.  Classes, abstract classes or enums are not allowed.  Either convert {1} to an interface or remove it from the @{0} list in the bean class.
-
-# warn(b, "interface.beanOnlyAnnotation", annotation.getSimpleName(), interfce.getName(), b.getEjbClass());
-1.interface.beanOnlyAnnotation = Ignoring @{0}.  Annotation only usable on the bean class.
-2.interface.beanOnlyAnnotation = Ignoring @{0} used on interface {1}.  Annotation only usable on the bean class.
-3.interface.beanOnlyAnnotation = @{0} is only usable on the bean classes, not its interfaces.  This annotation will be ignored unless it is moved to the bean class {2}.
-
-# warn(b, "interfaceMethod.beanOnlyAnnotation", annotation.getSimpleName(), interfce.getName(), method.getName(), b.getEjbClass());
-1.interfaceMethod.beanOnlyAnnotation = Ignoring @{0}.  Annotation only usable on the bean class.
-2.interfaceMethod.beanOnlyAnnotation = Ignoring @{0} used on interface {1} method {2}.  Annotation only usable on the bean class.
-3.interfaceMethod.beanOnlyAnnotation = @{0} is only usable on the bean classes, not its interfaces.  This annotation will be ignored unless it is moved to the {2} method in the bean class {3}.
-
-# fail(ejbName, "permitAllAndRolesAllowedOnClass", clazz.getName());
-1.permitAllAndRolesAllowedOnClass = @RolesAllowed and @PermitAll cannot be used on the same class
-2.permitAllAndRolesAllowedOnClass = @RolesAllowed and @PermitAll cannot be used on the same class: {0}
-3.permitAllAndRolesAllowedOnClass = The @RolesAllowed and @PermitAll annotations are mutually exclussive and cannot be used together on the same class.  Choose between @RolesAllowed, which will restrict access to the listed authenticated roles, and @PermitAll, which will allow access to anyone authenticated or not, then update class {0} by deleting the annotation you do not wish to use.  Alternatively, @RolesAllowed can be used at the class level and @PermitAll can be used on individual methods and vice versa.
-
-# fail(ejbName, "conflictingSecurityAnnotations", method.getName(), join(" and ", annotations), method.getDeclaringClass());
-1.conflictingSecurityAnnotations = Method has conflicting security annotations.
-2.conflictingSecurityAnnotations = Method has conflicting security annotations: "{0}" uses {1}
-3.conflictingSecurityAnnotations = The {1} annotations are mutually exclussive and cannot be used together on the same method.  Choose the security annotation you want and delete the others from method {0} in class {2}.  @RolesAllowed will restrict access to the listed authenticated roles.  @PermitAll will allow access to anyone authenticated or not.  @DenyAll will deny access to anyone authenticated or not.
-
-# warn(ejbName, "xml.invalidTransactionAttribute", count);
-1.xml.invalidTransactionAttribute = Ignoring invalid <container-transaction> declarations.  Bean not using Container-Managed Transactions.
-2.xml.invalidTransactionAttribute = Ignoring {0} invalid <container-transaction> declarations.  Bean not using Container-Managed Transactions.
-3.xml.invalidTransactionAttribute = The <container-transaction> element applies only to beans using Container-Managed Transactions.  Beans marked as <transaction-type>Bean</transaction-type> are responsible for their own transactions and may not use the <container-transaction> element.  There are {0} such invalid declarations in the deployment descriptor that will be ignored and should be removed.
-
-# warn(ejbName, "ann.invalidTransactionAttribute", count);
-1.ann.invalidTransactionAttribute = Ignoring invalid @TransactionAttribute annotations.  Bean not using Container-Managed Transactions.
-2.ann.invalidTransactionAttribute = Ignoring {0} invalid @TransactionAttribute annotations.  Bean not using Container-Managed Transactions.
-3.ann.invalidTransactionAttribute = The @TransactionAttribute annotation applies only to beans using Container-Managed Transactions.  Beans marked as @TransactionManagement(BEAN) are responsible for their own transactions and may not use the @TransactionAttribute annotation.  There are {0} such invalid annotations in the bean class that will be ignored and should be removed.
-#TODO
-# warn(ejbName, "xml.invalidConcurrencyAttribute", count);
-#1.xml.invalidConcurrencyAttribute = Ignoring invalid <container-concurrency> declarations.  Bean not using Container-Managed Concurrency.
-#2.xml.invalidConcurrencyAttribute = Ignoring {0} invalid <container-concurrency> declarations.  Bean not using Container-Managed Concurrency.
-#3.xml.invalidConcurrencyAttribute = The <container-concurrency> element applies only to beans using Container-Managed Concurrency.  Beans marked as <concurrency-type>Bean</concurrency-type> are responsible for thier own concurrency and may not use the <container-concurrency> element.  There are {0} such invalid declarations in the deployment descriptor that will be ignored and should be removed.
-
-# warn(ejbName, "ann.invalidConcurrencyAttribute", count);
-1.ann.invalidConcurrencyAttribute = Ignoring invalid @Lock annotations.  Bean not using Container-Managed Concurrencys.
-2.ann.invalidConcurrencyAttribute = Ignoring {0} invalid @Lock annotations.  Bean not using Container-Managed Concurrencys.
-3.ann.invalidConcurrencyAttribute = The @Lock annotation applies only to beans using Container-Managed Concurrencys.  Beans marked as @ConcurrencyManagement(BEAN) are responsible for thier own concurrency and may not use the @Lock annotation.  There are {0} such invalid annotations in the bean class that will be ignored and should be removed.
-
-
-1.xml.home.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <home>. Use <local-home>{0}</local-home>
-2.xml.home.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <home>. Use <local-home>{0}</local-home>
-3.xml.home.ejbLocalHome = The <home> element is for interfaces extending javax.ejb.EJBHome.  The interface supplied is a javax.ejb.EJBLocalHome and should be declared with the <local-home> element as in: <local-home>{0}</local-home>
-
-1.xml.home.ejbObject = javax.ejb.EJBObject interface declared as <home>. Use <remote>{0}</remote>
-2.xml.home.ejbObject = javax.ejb.EJBObject interface declared as <home>. Use <remote>{0}</remote>
-3.xml.home.ejbObject = The <home> element is for interfaces extending javax.ejb.EJBHome.  The interface supplied is a javax.ejb.EJBObject and should be declared with the <remote> element as in: <remote>{0}</remote>
-
-1.xml.home.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <home>. Use <local>{0}</local>
-2.xml.home.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <home>. Use <local>{0}</local>
-3.xml.home.ejbLocalObject = The <home> element is for interfaces extending javax.ejb.EJBHome.  The interface supplied is a javax.ejb.EJBLocalObject and should be declared with the <local> element as in: <local>{0}</local>
-
-1.xml.home.businessLocal = EJB 3.0 business interface declared as <home>. Use <business-local>{0}</business-local>
-2.xml.home.businessLocal = EJB 3.0 business interface declared as <home>. Use <business-local>{0}</business-local>
-3.xml.home.businessLocal = The <home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBHome.  EJB 3.0 simplified business interfaces can be decalred via <business-local>{0}</business-local> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.home.businessRemote = EJB 3.0 business interface declared as <home>. Use <business-remote>{0}</business-remote>
-2.xml.home.businessRemote = EJB 3.0 business interface declared as <home>. Use <business-remote>{0}</business-remote>
-3.xml.home.businessRemote = The <home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBHome.  EJB 3.0 simplified business interfaces can be decalred via <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.home.beanClass = Bean class mistakenly declared as <home>
-2.xml.home.beanClass = Bean class mistakenly declared as <home>
-3.xml.home.beanClass = The <home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBHome.  The bean class cannot be used as a home interface.
-
-1.xml.home.notInterface = The value of <home> is not an interface
-2.xml.home.notInterface = The value of <home> is not an interface: {0}
-3.xml.home.notInterface = The <home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBHome.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <home> xml tag from your ejb-jar.xml
-
-1.xml.home.unknown = The value of <home> must be an interface extending javax.ejb.EJBHome
-2.xml.home.unknown = The value of <home> must be an interface extending javax.ejb.EJBHome
-3.xml.home.unknown = The <home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBHome.  If this interface is intended to be an EJB 3.0 business remote view, declare this interface as <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-
-
-1.xml.remote.ejbHome = javax.ejb.EJBHome interface declared as <remote>. Use <home>{0}</home>
-2.xml.remote.ejbHome = javax.ejb.EJBHome interface declared as <remote>. Use <home>{0}</home>
-3.xml.remote.ejbHome = The <remote> element is for interfaces extending javax.ejb.EJBObject.  The interface supplied is a javax.ejb.EJBHome and should be declared with the <home> element as in: <home>{0}</home>
-
-1.xml.remote.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <remote>. Use <local-home>{0}</local-home>
-2.xml.remote.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <remote>. Use <local-home>{0}</local-home>
-3.xml.remote.ejbLocalHome = The <remote> element is for interfaces extending javax.ejb.EJBHome.  The interface supplied is a javax.ejb.EJBLocalHome and should be declared with the <local-home> element as in: <local-home>{0}</local-home>
-
-1.xml.remote.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <remote>. Use <local>{0}</local>
-2.xml.remote.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <remote>. Use <local>{0}</local>
-3.xml.remote.ejbLocalObject = The <remote> element is for interfaces extending javax.ejb.EJBObject.  The interface supplied is a javax.ejb.EJBLocalObject and should be declared with the <local> element as in: <local>{0}</local>
-
-# must be attempting an override
-1.xml.remote.businessLocal = EJB 3.0 business interface declared as <remote>. Use <business-remote>{0}</business-remote>
-2.xml.remote.businessLocal = EJB 3.0 business interface declared as <remote>. Use <business-remote>{0}</business-remote>
-3.xml.remote.businessLocal = The <remote> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBObject.  EJB 3.0 simplified business interfaces can be decalred via <business-local>{0}</business-local> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.remote.businessRemote = EJB 3.0 business interface declared as <remote>. Use <business-remote>{0}</business-remote>
-2.xml.remote.businessRemote = EJB 3.0 business interface declared as <remote>. Use <business-remote>{0}</business-remote>
-3.xml.remote.businessRemote = The <remote> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBObject.  EJB 3.0 simplified business interfaces can be decalred via <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.remote.beanClass = Bean class mistakenly declared as <remote>
-2.xml.remote.beanClass = Bean class mistakenly declared as <remote>
-3.xml.remote.beanClass = The <remote> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBObject.  The bean class cannot be used as a home interface.
-
-1.xml.remote.notInterface = The value of <remote> is not an interface
-2.xml.remote.notInterface = The value of <remote> is not an interface: {0}
-3.xml.remote.notInterface = The <remote> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBObject.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <remote> xml tag from your ejb-jar.xml
-
-1.xml.remote.unknown = The value of <remote> must be an interface extending javax.ejb.EJBObject
-2.xml.remote.unknown = The value of <remote> must be an interface extending javax.ejb.EJBObject.  Perhaps you meant to use <business-remote>{0}</business-remote>
-3.xml.remote.unknown = The <remote> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBObject.  If this interface is intended to be an EJB 3.0 business remote view, declare this interface as <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-
-
-
-1.xml.localHome.ejbHome = javax.ejb.EJBHome interface declared as <local-home>. Use <home>{0}</home>
-2.xml.localHome.ejbHome = javax.ejb.EJBHome interface declared as <local-home>. Use <home>{0}</home>
-3.xml.localHome.ejbHome = The <local-home> element is for interfaces extending javax.ejb.EJBLocalHome.  The interface supplied is a javax.ejb.EJBHome and should be declared with the <home> element as in: <home>{0}</home>
-
-1.xml.localHome.ejbObject = javax.ejb.EJBObject interface declared as <local-home>. Use <remote>{0}</remote>
-2.xml.localHome.ejbObject = javax.ejb.EJBObject interface declared as <local-home>. Use <remote>{0}</remote>
-3.xml.localHome.ejbObject = The <local-home> element is for interfaces extending javax.ejb.EJBLocalHome.  The interface supplied is a javax.ejb.EJBObject and should be declared with the <remote> element as in: <remote>{0}</remote>
-
-1.xml.localHome.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <local-home>. Use <local>{0}</local>
-2.xml.localHome.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <local-home>. Use <local>{0}</local>
-3.xml.localHome.ejbLocalObject = The <local-home> element is for interfaces extending javax.ejb.EJBLocalHome.  The interface supplied is a javax.ejb.EJBLocalObject and should be declared with the <local> element as in: <local>{0}</local>
-
-1.xml.localHome.businessLocal = EJB 3.0 business interface declared as <local-home>. Use <business-local>{0}</business-local>
-2.xml.localHome.businessLocal = EJB 3.0 business interface declared as <local-home>. Use <business-local>{0}</business-local>
-3.xml.localHome.businessLocal = The <local-home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalHome.  EJB 3.0 simplified business interfaces can be decalred via <business-local>{0}</business-local> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.localHome.businessRemote = EJB 3.0 business interface declared as <local-home>. Use <business-remote>{0}</business-remote>
-2.xml.localHome.businessRemote = EJB 3.0 business interface declared as <local-home>. Use <business-remote>{0}</business-remote>
-3.xml.localHome.businessRemote = The <local-home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalHome.  EJB 3.0 simplified business interfaces can be decalred via <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.localHome.beanClass = Bean class mistakenly declared as <local-home>
-2.xml.localHome.beanClass = Bean class mistakenly declared as <local-home>
-3.xml.localHome.beanClass = The <local-home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalHome.  The bean class cannot be used as a home interface.
-
-1.xml.localHome.notInterface = The value of <local-home> is not an interface
-2.xml.localHome.notInterface = The value of <local-home> is not an interface: {0}
-3.xml.localHome.notInterface = The <local-home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalHome.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <local-home> xml tag from your ejb-jar.xml
-
-1.xml.localHome.unknown = The value of <local-home> must be an interface extending javax.ejb.EJBLocalHome
-2.xml.localHome.unknown = The value of <local-home> must be an interface extending javax.ejb.EJBLocalHome
-3.xml.localHome.unknown =  The <local-home> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalHome.  If this interface is intended to be an EJB 3.0 business local view, declare this interface as <business-local>{0}</business-local> or via the @Local annotation on the bean class or interface class.
-
-
-
-
-1.xml.local.ejbHome = javax.ejb.EJBHome interface declared as <local>. Use <home>{0}</home>
-2.xml.local.ejbHome = javax.ejb.EJBHome interface declared as <local>. Use <home>{0}</home>
-3.xml.local.ejbHome = The <local> element is for interfaces extending javax.ejb.EJBLocalObject.  The interface supplied is a javax.ejb.EJBHome and should be declared with the <home> element as in: <home>{0}</home>
-
-1.xml.local.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <local>. Use <local-home>{0}</local-home>
-2.xml.local.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <local>. Use <local-home>{0}</local-home>
-3.xml.local.ejbLocalHome = The <local> element is for interfaces extending javax.ejb.EJBLocalObject.  The interface supplied is a javax.ejb.EJBLocalHome and should be declared with the <local-home> element as in: <local-home>{0}</local-home>
-
-1.xml.local.ejbObject = javax.ejb.EJBObject interface declared as <local>. Use <remote>{0}</remote>
-2.xml.local.ejbObject = javax.ejb.EJBObject interface declared as <local>. Use <remote>{0}</remote>
-3.xml.local.ejbObject = The <local> element is for interfaces extending javax.ejb.EJBLocalObject.  The interface supplied is a javax.ejb.EJBObject and should be declared with the <remote> element as in: <remote>{0}</remote>
-
-1.xml.local.businessLocal = EJB 3.0 business interface declared as <local>. Use <business-local>{0}</business-local>
-2.xml.local.businessLocal = EJB 3.0 business interface declared as <local>. Use <business-local>{0}</business-local>
-3.xml.local.businessLocal = The <local> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalObject.  EJB 3.0 simplified business interfaces can be decalred via <business-local>{0}</business-local> or via the @Remote annotation on the bean class or interface class.
-
-# must be attempting an override
-1.xml.local.businessRemote = EJB 3.0 business interface declared as <local>. Use <business-local>{0}</business-local>
-2.xml.local.businessRemote = EJB 3.0 business interface declared as <local>. Use <business-local>{0}</business-local>
-3.xml.local.businessRemote = The <local> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalObject.  EJB 3.0 simplified business interfaces can be decalred via <business-remote>{0}</business-remote> or via the @Remote annotation on the bean class or interface class.
-
-1.xml.local.beanClass = Bean class mistakenly declared as <local>
-2.xml.local.beanClass = Bean class mistakenly declared as <local>
-3.xml.local.beanClass = The <local> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalObject.  The bean class cannot be used as a home interface.
-
-1.xml.local.notInterface = The value of <local> is not an interface
-2.xml.local.notInterface = The value of <local> is not an interface: {0}
-3.xml.local.notInterface = The <local> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalObject.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <local> xml tag from your ejb-jar.xml
-
-1.xml.local.unknown = The value of <local> must be an interface extending javax.ejb.EJBLocalObject
-2.xml.local.unknown = The value of <local> must be an interface extending javax.ejb.EJBLocalObject.  Perhaps you meant to use <business-local>{0}</business-local>
-3.xml.local.unknown = The <local> element of the ejb-jar.xml is for interfaces extending javax.ejb.EJBLocalObject.  If this interface is intended to be an EJB 3.0 business local view, declare this interface as <business-local>{0}</business-local> or via the @Local annotation on the bean class or interface class.
-
-
-
-
-1.xml.businessRemote.ejbHome = javax.ejb.EJBHome interface declared as <business-remote>. Use <home>{0}</home>
-2.xml.businessRemote.ejbHome = javax.ejb.EJBHome interface declared as <business-remote>. Use <home>{0}</home>
-3.xml.businessRemote.ejbHome = Interfaces extending javax.ejb.EJBHome must use the <home> tag, not the <business-remote> tag, when declared in the ejb-jar.xml.  Declare this interface as <home>{0}</home> or alternatively add @RemoteHome({0}.class) to the top of your bean class.
-
-1.xml.businessRemote.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <business-remote>. Use <local-home>{0}</local-home>
-2.xml.businessRemote.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <business-remote>. Use <local-home>{0}</local-home>
-3.xml.businessRemote.ejbLocalHome = Interfaces extending javax.ejb.EJBLocalHome must use the <local-home> tag, not the <business-remote> tag, when declared in the ejb-jar.xml.  Declare this interface as <local-home>{0}</local-home> or alternatively add @LocalHome({0}.class) to the top of your bean class.
-
-1.xml.businessRemote.ejbObject = javax.ejb.EJBObject interface declared as <business-remote>. Use <remote>{0}</remote>
-2.xml.businessRemote.ejbObject = javax.ejb.EJBObject interface declared as <business-remote>. Use <remote>{0}</remote>
-3.xml.businessRemote.ejbObject = Interfaces extending javax.ejb.EJBObject must use the <remote> tag, not the <business-remote> tag, when declared in the ejb-jar.xml.  Declare this interface as <remote>{0}</remote>.
-
-1.xml.businessRemote.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <business-remote>. Use <local>{0}</local>
-2.xml.businessRemote.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <business-remote>. Use <local>{0}</local>
-3.xml.businessRemote.ejbLocalObject = Interfaces extending javax.ejb.EJBLocalObject must use the <local> tag, not the <business-remote> tag, when declared in the ejb-jar.xml.  Declare this interface as <local>{0}</local>.
-
-1.xml.businessRemote.beanClass = Bean class mistakenly declared as <business-remote>
-2.xml.businessRemote.beanClass = Bean class mistakenly declared as <business-remote>
-3.xml.businessRemote.beanClass = The bean class cannot itself be used as the value of the <business-remote> element of the ejb-jar.xml.  Either list a valid java interface or delete this element and annotate the intended interface with the @Remote annotation.
-
-1.xml.businessRemote.notInterface = The value of <business-remote> is not an interface
-2.xml.businessRemote.notInterface = The value of <business-remote> is not an interface: {0}
-3.xml.businessRemote.notInterface = The <business-remote> element of the ejb-jar.xml must be an interface.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <business-remote> xml tag from your ejb-jar.xml
-
-1.xml.businessLocal.ejbHome = javax.ejb.EJBHome interface declared as <business-local>. Use <home>{0}</home>
-2.xml.businessLocal.ejbHome = javax.ejb.EJBHome interface declared as <business-local>. Use <home>{0}</home>
-3.xml.businessLocal.ejbHome = Interfaces extending javax.ejb.EJBHome must use the <home> tag, not the <business-local> tag, when declared in the ejb-jar.xml.  Declare this interface as <home>{0}</home> or alternatively add @RemoteHome({0}.class) to the top of your bean class.
-
-1.xml.businessLocal.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <business-local>. Use <local-home>{0}</local-home>
-2.xml.businessLocal.ejbLocalHome = javax.ejb.EJBLocalHome interface declared as <business-local>. Use <local-home>{0}</local-home>
-3.xml.businessLocal.ejbLocalHome = Interfaces extending javax.ejb.EJBLocalHome must use the <local-home> tag, not the <business-local> tag, when declared in the ejb-jar.xml.  Declare this interface as <local-home>{0}</local-home> or alternatively add @LocalHome({0}.class) to the top of your bean class.
-
-1.xml.businessLocal.ejbObject = javax.ejb.EJBObject interface declared as <business-local>. Use <remote>{0}</remote>
-2.xml.businessLocal.ejbObject = javax.ejb.EJBObject interface declared as <business-local>. Use <remote>{0}</remote>
-3.xml.businessLocal.ejbObject = Interfaces extending javax.ejb.EJBObject must use the <remote> tag, not the <business-local> tag, when declared in the ejb-jar.xml.  Declare this interface as <remote>{0}</remote>.
-
-1.xml.businessLocal.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <business-local>. Use <local>{0}</local>
-2.xml.businessLocal.ejbLocalObject = javax.ejb.EJBLocalObject interface declared as <business-local>. Use <local>{0}</local>
-3.xml.businessLocal.ejbLocalObject = Interfaces extending javax.ejb.EJBLocalObject must use the <local> tag, not the <business-local> tag, when declared in the ejb-jar.xml.  Declare this interface as <local>{0}</local>.
-
-1.xml.businessLocal.beanClass = Bean class mistakenly declared as <business-local>
-2.xml.businessLocal.beanClass = Bean class mistakenly declared as <business-local>
-3.xml.businessLocal.beanClass = The bean class cannot itself be used as the value of the <business-local> element of the ejb-jar.xml.  Either 1) list a valid java interface or 2) delete this element and annotate the intended interface with the @Local annotation.
-
-1.xml.businessLocal.notInterface = The value of <business-local> is not an interface
-2.xml.businessLocal.notInterface = The value of <business-local> is not an interface: {0}
-3.xml.businessLocal.notInterface = The <business-local> element of the ejb-jar.xml must be an interface.  Classes, abstract classes or enums are not allowed.  Either convert {0} to an interface or remove the related <business-local> xml tag from your ejb-jar.xml
-
-
-# TODO: add the apostrophes back in "beans"
-1.ann.ejb.ejbObject = @EJB mistakenly refers to a beans javax.ejb.EJBObject interface
-2.ann.ejb.ejbObject = @EJB mistakenly refers to a beans javax.ejb.EJBObject interface {0}.  Use the EJBHome interface instead.
-3.ann.ejb.ejbObject = When using the @EJB annotation to refer to older EJB 2.x component interfaces, it is the the home interface should be referenced/injected via @EJB.  The home interface is then used in code to create a reference to the {0} interface.  Change the reference type of {1} to the beans home interface.
-
-1.ann.ejb.ejbLocalObject = @EJB mistakenly refers to a beans javax.ejb.EJBLocalObject interface
-2.ann.ejb.ejbLocalObject = @EJB mistakenly refers to a beans javax.ejb.EJBLocalObject interface {0}.  Use the EJBLocalHome interface instead.
-3.ann.ejb.ejbLocalObject = When using the @EJB annotation to refer to older EJB 2.x component interfaces, it is the the local home interface should be referenced/injected via @EJB.  The local home interface is then used in code to create a reference to the {0} interface.  Change the reference type of {1} to the beans local home interface.
-
-1.ann.ejb.beanClass = @EJB mistakenly refers to a bean class
-2.ann.ejb.beanClass = @EJB mistakenly refers to a bean class {0}.  Use the beans business interface instead
-3.ann.ejb.beanClass = The @EJB annotation cannot be used to directly refer to the bean class itself and must instead refer to the bean using one of its business interfaces.  Change the type of the {1} reference from {0} to a business interface of that bean.
-
-1.ann.ejb.notInterface = @EJB mistakenly refers to a non-interface
-2.ann.ejb.notInterface = @EJB mistakenly refers to a non-interface.  Use the beans business interface instead
-3.ann.ejb.notInterface = The @EJB annotation cannot be used to directly refer to the bean class itself and must instead refer to the bean using one of its business interfaces.  Change the type of the {1} reference from {0} to a business interface of that bean.
-
-# fail(enterpriseBean.getEjbName(), "dependsOn.noSuchEjb", ejbName);
-1.dependsOn.noSuchEjb = Singleton @DependsOn refers to non-existant EJB:
-2.dependsOn.noSuchEjb = Singleton @DependsOn refers to non-existant EJB: {0}
-3.dependsOn.noSuchEjb = The @DependsOn annotation or <depends-on> descriptor data for this Singeton bean lists an EJB "{0}" which does not exist in any of the modules of the ear.
-
-# fail("EAR", "dependsOn.circuit", Join.join(" -> ", ejbNames), ejbNames.get(0));
-1.dependsOn.circuit = Singleton circular dependency detected
-2.dependsOn.circuit = Singleton circular dependency detected: {0}
-3.dependsOn.circuit = A Singleton circular dependency has been detected in the application.  Bean "{1}" refers to one or more other singleton beans via @DependsOn which directly or indirectly refer back to bean "{1}".  This circle must be broken befor the application can be built: {0}
-
-# CheckUserTransactionRefs.java
-# warn(bean, "userResourceRef.forbiddenForCmtdBeans", resRef.getResourceEnvRefName());
-1.userTransactionRef.forbiddenForCmtdBeans = Container-Managed Transaction beans cannot use UserTransaction
-2.userTransactionRef.forbiddenForCmtdBeans = Container-Managed Transaction beans cannot use UserTransaction: fix ref {0}
-3.userTransactionRef.forbiddenForCmtdBeans = Only session and message-driven beans with bean-managed transaction demarcation are allowed to use UserTransaction.  Fix @Resource or resource-env-ref {0}
-
-1.xml.noEjbClass = Element <ejb-class> unspecified.
-2.xml.noEjbClass = Element <ejb-class> unspecified.  No annotated bean discovered with <ejb-name>{0}</ejb-name>
-3.xml.noEjbClass = The <ejb-class> element is only optional if there is a matching annotated bean in the module with the bean name {0}.  No such bean was found.  Other beans in this module are: {1}  
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# Format for the different levels follows this spirit:
+#
+# 1. Should be short and fixed such that someone could search/grep for it
+#    without having to know/use regular expressions.  These tend to be similar
+#    to the message key.
+#
+# 2. Intended to contain the issue expressed in 1 with only the essential
+#    details, should not line wrap if possible.  Be terse.
+#
+# 3. Teacher's assistant.  A much more conversational and possibly more detailed
+#    explanation of the issue, should tell the user what to do to fix the problem.
+#    I.e. don't just point out what is wrong, also point out what is right.  Use
+#    several lines if needed.
+#
+
+
+# 0 - Error Message
+# 1 - Stack Trace
+1.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947
+2.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947: {0}
+3.cannot.validate        \u091c\u093e\u0930 \u0915\u094b \u092e\u093e\u0928\u094d\u092f \u0928\u0939\u0940\u0902 \u0915\u0930 \u0938\u0915\u0924\u0947: {0}
+
+# 0 - Class name
+# 1 - Element (home, ejb-class, remote)
+# 2 - Bean name
+1.missing.class           \u0932\u093e\u092a\u0924\u093e \u0915\u094d\u0932\u093e\u0938
+2.missing.class           \u0932\u093e\u092a\u0924\u093e \u0915\u094d\u0932\u093e\u0938 <{1}> {0}
+3.missing.class           \u0915\u094d\u0932\u093e\u0938 {0} \u0928\u0939\u0940\u0902 \u092e\u093f\u0932\u0940 . \u091c\u093e\u0902\u091a \u0915\u0930\u0947\u0902 \u0915\u0940 \u092c\u0940\u0928 {2} \u0915\u0947 {1} \u090f\u0932\u0947\u092e\u0947\u0928\u094d\u091f \u092e\u0947\u0902 \u0928\u093f\u0930\u094d\u0926\u093f\u0937\u094d\u091f \u0915\u094d\u0932\u093e\u0938 \u0915\u0940 \u0935\u0930\u094d\u0924\u0928\u0940 \u0920\u0940\u0915 \u0939\u0948 \u0914\u0930 \u0915\u094d\u0932\u093e\u0938 \u091c\u0930 \u092e\u0947\u0902 \u092e\u094c\u091c\u0942\u0926 \u0939\u0948 
+
+# 0 - Class name
+# 1 - EJB Class name
+1.wrong.class.type        \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0915\u094d\u0932\u093e\u0938
+2.wrong.class.type        \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0915\u094d\u0932\u093e\u0938 {0}
+3.wrong.class.type        \u0915\u094d\u0932\u093e\u0938 {0 } \u0917\u0932\u0924 \u092a\u094d\u0930\u0915\u093e\u0930 \u0915\u0940 \u0939\u0948, \u092f\u0939 {1 } \u0915\u094b \u090f\u0915\u094d\u0938\u091f\u0947\u0902\u0921 \u0928\u0939\u0940\u0902 \u0915\u0930\u0924\u0940
+# 0 - method name
+# 1 - full method
+# 2 - remote|home
+# 3 - interface name
+# 4 - EJB Class name
+1.no.busines.method       \u0910\u0938\u093e \u0915\u094b\u0908 \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 \u0928\u0939\u0940\u0902
+2.no.busines.method       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {0 } \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e .
+3.no.busines.method       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {1 } \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f(\u0932\u093e\u0917\u0942) \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e . \u092f\u0939 \u092e\u0947\u0925\u0921 {2 } \u0907\u0902\u091f\u0930\u092b\u0947\u0938 {3 } \u092e\u0947\u0902 \u0918\u094b\u0937\u093f\u0924 \u0915\u093f\u092f\u093e \u0917\u092f\u093e \u0925\u093e \u0932\u0947\u0915\u093f\u0928 \u0908.\u091c.\u092c\u0940 \u0915\u094d\u0932\u093e\u0938 \u092e\u0947\u0902 \u0907\u092e\u094d\u092a\u094d\u0932\u0947\u092e\u0947\u0902\u091f(\u0932\u093e\u0917\u0942) \u0928\u0939\u0940\u0902 \u0915\u093f\u092f\u093e \u0917\u092f\u093e 
+
+# fail(b, "no.busines.method.args", interfaceMethods[i].getName(), interfaceMethods[i].toString(), "local", intrface.getName(), beanClass.getName(), differentArgs.size());
+1.no.busines.method.args       \u0910\u0938\u093e \u0915\u094b\u0908 \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921  \u0928\u0939\u0940\u0902 \u0939\u0948. \u0917\u0932\u0924 \u0906\u0930\u094d\u0917\u0941\u092e\u0947\u0902\u091f\u094d\u0938 \u0907\u0938\u094d\u0924\u0947\u092e\u093e\u0932 \u0915\u093f\u092f\u0947 \u0939\u0948 .
+2.no.busines.method.args       \u092c\u093f\u091c\u093c\u0928\u0938 \u092e\u0947\u0925\u0921 {0 } \u0915\u0947 \u0906\u0930\u094d\u0917\u0941\u092e\u0947\u0902\u091f\u094d\u0938 \u092e\u0948

<TRUNCATED>

[15/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
index 9f7da52..50c0fa9 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
@@ -1,714 +1,714 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.config;
-
-import org.apache.openejb.OpenEJBRuntimeException;
-import org.apache.openejb.loader.Options;
-import org.apache.openejb.util.Join;
-import org.apache.openejb.util.Pipe;
-
-import java.io.File;
-import java.io.IOException;
-import java.io.OutputStream;
-import java.lang.reflect.Field;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.TimeUnit;
-import java.util.concurrent.atomic.AtomicReference;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-//import org.apache.openejb.loader.IO;
-
-/**
- * NOTE: Do not add inner or anonymous classes or a dependency without updating ExecMojo
- *
- * @version $Rev$ $Date$
- */
-@SuppressWarnings("UseOfSystemOutOrSystemErr")
-public class RemoteServer {
-
-    private static final Options options = new Options(System.getProperties());
-    public static final String SERVER_DEBUG_PORT = "server.debug.port";
-    public static final String SERVER_SHUTDOWN_PORT = "server.shutdown.port";
-    public static final String SERVER_SHUTDOWN_HOST = "server.shutdown.host";
-    public static final String SERVER_SHUTDOWN_COMMAND = "server.shutdown.command";
-    public static final String OPENEJB_SERVER_DEBUG = "openejb.server.debug";
-    public static final String START = "start";
-    public static final String STOP = "stop";
-
-    private final boolean debug = options.get(OPENEJB_SERVER_DEBUG, false);
-    private final boolean profile = options.get("openejb.server.profile", false);
-    private final boolean tomcat;
-    private final String javaOpts = System.getProperty("java.opts");
-    private String additionalClasspath;
-
-    /**
-     * Has the remote server's instance been already running ?
-     */
-    private boolean serverHasAlreadyBeenStarted = true;
-
-    private Properties properties;
-    private final AtomicReference<Process> server = new AtomicReference<Process>();
-    private final int tries;
-    private final boolean verbose;
-    private final int portShutdown;
-    private final String host;
-    private final String command;
-    private File home;
-    private int portStartup;
-
-    public RemoteServer() {
-        this(options.get("connect.tries", 60), options.get("verbose", false));
-    }
-
-    public RemoteServer(final int tries, final boolean verbose) {
-        this.tries = (tries < 1 ? 1 : (tries > 3600 ? 3600 : tries)); //Wait at least 1 second to start or stop, but not more than an hour.
-        this.verbose = verbose;
-        home = getHome();
-        tomcat = (home != null) && (new File(new File(home, "bin"), "catalina.sh").exists());
-
-        portShutdown = options.get(SERVER_SHUTDOWN_PORT, tomcat ? 8005 : 4200);
-        portStartup = portShutdown;
-        command = options.get(SERVER_SHUTDOWN_COMMAND, "SHUTDOWN");
-        host = options.get(SERVER_SHUTDOWN_HOST, "localhost");
-    }
-
-    public void init(final Properties props) {
-        properties = props;
-
-        props.put("java.naming.factory.initial", "org.apache.openejb.client.RemoteInitialContextFactory");
-        final int port = options.get("ejbd.port", 4201);
-        props.put("java.naming.provider.url", options.get("java.naming.provider.url", "127.0.0.1:" + port));
-        props.put("java.naming.security.principal", "testuser");
-        props.put("java.naming.security.credentials", "testpassword");
-    }
-
-    public static void main(final String[] args) {
-        assert args.length > 0 : "no arguments supplied: valid arguments are 'start' or 'stop'";
-        if (args[0].equalsIgnoreCase(START)) {
-            final RemoteServer remoteServer = new RemoteServer();
-            try {
-                remoteServer.start();
-            } catch (final Exception e) {
-                remoteServer.destroy();
-                e.printStackTrace(System.err);
-            }
-        } else if (args[0].equalsIgnoreCase(STOP)) {
-            final RemoteServer remoteServer = new RemoteServer();
-            remoteServer.serverHasAlreadyBeenStarted = false;
-            try {
-                remoteServer.forceStop();
-            } catch (final Exception e) {
-                e.printStackTrace(System.err);
-            }
-        } else {
-            throw new OpenEJBRuntimeException("valid arguments are 'start' or 'stop'");
-        }
-    }
-
-    public int getPortStartup() {
-        return this.portStartup;
-    }
-
-    public void setPortStartup(final int portStartup) {
-        this.portStartup = portStartup;
-    }
-
-    public Properties getProperties() {
-        return this.properties;
-    }
-
-    public void destroy() {
-
-        try {
-            final boolean stopSent = stop();
-
-            final Process p = server.get();
-            if (p != null) {
-
-                if (stopSent) {
-                    waitFor(p);
-                } else {
-                    p.destroy();
-                }
-            }
-        } catch (final Exception e) {
-            Logger.getLogger(RemoteServer.class.getName()).log(Level.WARNING, "Failed to destroy remote server process", e);
-        }
-    }
-
-    public void start() {
-        start(Collections.<String>emptyList(), START, true);
-    }
-
-    public void start(final List<String> additionalArgs, final String cmd, final boolean checkPortAvailable) {
-        cmd(additionalArgs, cmd, checkPortAvailable);
-    }
-
-    private void cmd(final List<String> additionalArgs, final String cmd, final boolean checkPortAvailable) {
-        boolean ok = true;
-        final int port = START.equals(cmd) ? portStartup : portShutdown;
-
-        if (checkPortAvailable) {
-            ok = !connect(port, 1);
-        }
-
-        if (ok) {
-            try {
-                if (verbose) {
-                    System.out.println("[] " + cmd.toUpperCase() + " SERVER");
-                }
-
-                final File home = getHome();
-                final String javaVersion = System.getProperty("java.version");
-                if (verbose) {
-                    System.out.println("OPENEJB_HOME = " + home.getAbsolutePath());
-                    final String systemInfo = "Java " + javaVersion + "; " + System.getProperty("os.name") + "/" + System.getProperty("os.version");
-                    System.out.println("SYSTEM_INFO  = " + systemInfo);
-                }
-
-                serverHasAlreadyBeenStarted = false;
-
-                final File lib = new File(home, "lib");
-                final File webapplib = new File(new File(new File(home, "webapps"), "tomee"), "lib");
-
-                File javaagentJar = null;
-                try {
-                    javaagentJar = lib("openejb-javaagent", lib, webapplib);
-                } catch (final IllegalStateException ise) {
-                    // no-op
-                }
-
-                final File conf = new File(home, "conf");
-                final File loggingProperties = new File(conf, "logging.properties");
-
-                //File openejbJar = new File(lib, "openejb-core-" + version + ".jar");
-
-                final String java;
-                final boolean isWindows = System.getProperty("os.name", "unknown").toLowerCase().startsWith("windows");
-                if (isWindows && START.equals(cmd) && options.get("server.windows.fork", false)) {
-                    // run and forget
-                    java = new File(System.getProperty("java.home"), "bin/javaw").getAbsolutePath();
-                } else {
-                    java = new File(System.getProperty("java.home"), "bin/java").getAbsolutePath();
-                }
-
-                final List<String> argsList = new ArrayList<String>(20);
-                argsList.add(java);
-                argsList.add("-XX:+HeapDumpOnOutOfMemoryError");
-
-                if (debug) {
-                    argsList.add("-Xdebug");
-                    argsList.add("-Xnoagent");
-                    argsList.add("-Djava.compiler=NONE");
-                    argsList.add("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=" + options.get(SERVER_DEBUG_PORT, 5005));
-                }
-
-                if (profile) {
-                    String yourkitHome = options.get("yourkit.home", "/Applications/YourKit_Java_Profiler_9.5.6.app/bin/mac/");
-                    if (!yourkitHome.endsWith("/")) {
-                        yourkitHome += "/";
-                    }
-                    final String yourkitOpts = options.get("yourkit.opts", "disablestacktelemetry,disableexceptiontelemetry,builtinprobes=none,delay=10000,sessionname=Tomcat");
-                    argsList.add("-agentpath:" + yourkitHome + "libyjpagent.jnilib=" + yourkitOpts);
-                }
-
-                if (javaOpts != null) {
-                    Collections.addAll(argsList, javaOpts.split(" +"));
-                }
-
-                final Map<String, String> addedArgs = new HashMap<String, String>();
-                if (additionalArgs != null) {
-                    for (final String arg : additionalArgs) {
-                        final String[] values = arg.split("=");
-                        if (values.length == 1) {
-                            addedArgs.put(values[0], "null");
-                        } else {
-                            addedArgs.put(values[0], values[1]);
-                        }
-                        argsList.add(arg);
-                    }
-                }
-
-                if (!addedArgs.containsKey("-Djava.util.logging.config.file") && loggingProperties.exists()) {
-                    argsList.add("-Djava.util.logging.config.file=" + loggingProperties.getAbsolutePath());
-                }
-
-                if (javaagentJar != null && javaagentJar.exists()) {
-                    argsList.add("-javaagent:" + javaagentJar.getAbsolutePath());
-                }
-
-                //DMB: If you don't use an array, you get problems with jar paths containing spaces
-                // the command won't parse correctly
-                final String ps = File.pathSeparator;
-
-                final String[] args;
-                if (!tomcat) {
-                    final File openejbJar = lib("openejb-core", lib, webapplib);
-                    final StringBuilder cp = new StringBuilder(openejbJar.getAbsolutePath());
-                    if (additionalClasspath != null) {
-                        cp.append(ps).append(additionalClasspath);
-                    }
-
-                    argsList.add("-cp");
-                    argsList.add(cp.toString());
-                    argsList.add("org.apache.openejb.cli.Bootstrap");
-                } else {
-                    final File bin = new File(home, "bin");
-                    final File tlib = new File(home, "lib");
-                    final File bootstrapJar = new File(bin, "bootstrap.jar");
-                    final File juliJar = new File(bin, "tomcat-juli.jar");
-                    final File commonsLoggingJar = new File(bin, "commons-logging-api.jar");
-
-                    final File endorsed = new File(home, "endorsed");
-                    final File temp = new File(home, "temp");
-
-//                    if (!addedArgs.containsKey("-Dcom.sun.management.jmxremote")) {
-//                        argsList.add("-Dcom.sun.management.jmxremote");
-//                    }
-                    if (!addedArgs.containsKey("-Djava.util.logging.manager")) {
-                        argsList.add("-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager");
-                    }
-                    if (!addedArgs.containsKey("-Djava.io.tmpdir")) {
-                        argsList.add("-Djava.io.tmpdir=" + temp.getAbsolutePath());
-                    }
-                    if (!addedArgs.containsKey("-Djava.endorsed.dirs")) {
-                        argsList.add("-Djava.endorsed.dirs=" + endorsed.getAbsolutePath());
-                    }
-                    if (!addedArgs.containsKey("-Dcatalina.base")) {
-                        argsList.add("-Dcatalina.base=" + home.getAbsolutePath());
-                    }
-                    if (!addedArgs.containsKey("-Dcatalina.home")) {
-                        argsList.add("-Dcatalina.home=" + home.getAbsolutePath());
-                    }
-                    if (!addedArgs.containsKey("-Dcatalina.ext.dirs")) {
-                        argsList.add("-Dcatalina.ext.dirs=" + tlib.getAbsolutePath());
-                    }
-                    if (!addedArgs.containsKey("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE")) {
-                        argsList.add("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true");
-                    }
-                    if (!addedArgs.containsKey("-Dorg.apache.tomcat.util.http.ServerCookie.ALLOW_HTTP_SEPARATORS_IN_V0")) {
-                        argsList.add("-Dorg.apache.tomcat.util.http.ServerCookie.ALLOW_HTTP_SEPARATORS_IN_V0=true");
-                    }
-
-                    if (addedArgs.isEmpty()) { // default case
-                        addIfSet(argsList, "javax.net.ssl.keyStore");
-                        addIfSet(argsList, "javax.net.ssl.keyStorePassword");
-                        addIfSet(argsList, "javax.net.ssl.trustStore");
-                        addIfSet(argsList, "java.protocol.handler.pkgs");
-                    }
-
-                    argsList.add("-ea");
-                    argsList.add("-classpath");
-
-                    final StringBuilder cp = new StringBuilder(bootstrapJar.getAbsolutePath()).append(ps).append(juliJar.getAbsolutePath());
-                    if (commonsLoggingJar.exists()) {
-                        cp.append(ps).append(commonsLoggingJar.getAbsolutePath());
-                    }
-                    if (additionalClasspath != null) {
-                        cp.append(ps).append(additionalClasspath);
-                    }
-                    argsList.add(cp.toString());
-
-                    argsList.add("org.apache.catalina.startup.Bootstrap");
-                }
-
-                if (cmd == null) {
-                    argsList.add(START);
-                } else {
-                    argsList.add(cmd);
-                }
-                args = argsList.toArray(new String[argsList.size()]);
-
-                if (verbose) {
-                    System.out.println(Join.join("\n", args));
-                }
-
-                // kill3UNIXDebug();
-                final ProcessBuilder pb = new ProcessBuilder(args);
-                pb.directory(home.getAbsoluteFile());
-                Process p = pb.start();
-
-                //Process p = Runtime.getRuntime().exec(args);
-                Pipe.pipeOut(p); // why would we need to redirect System.in to the process, TomEE doesn't use it
-
-                if (START.equals(cmd)) {
-                    server.set(p);
-                } else if (STOP.equals(cmd)) {
-                    waitFor(p);
-                    p = server.get();
-                    if (p != null) {
-                        waitFor(p);
-                    }
-                }
-
-                System.out.println("Started server process on port: " + port);
-
-            } catch (final Exception e) {
-                throw (RuntimeException) new OpenEJBRuntimeException("Cannot start the server.  Exception: " + e.getClass().getName() + ": " + e.getMessage()).initCause(e);
-            }
-
-            if (debug) {
-                if (!connect(port, Integer.MAX_VALUE)) {
-                    throw new OpenEJBRuntimeException("Could not connect to server: " + this.host + ":" + port);
-                }
-            } else {
-                if (!connect(port, tries)) {
-                    throw new OpenEJBRuntimeException("Could not connect to server: " + this.host + ":" + port);
-                }
-            }
-
-        } else {
-            if (verbose) {
-                System.out.println("[] FOUND STARTED SERVER");
-            }
-        }
-    }
-
-    private void waitFor(final Process p) {
-        final CountDownLatch latch = new CountDownLatch(1);
-        final Thread t = new Thread(new Runnable() {
-            @Override
-            public void run() {
-                try {
-                    p.waitFor();
-                } catch (final InterruptedException e) {
-                    //Ignore
-                }
-
-                latch.countDown();
-            }
-        }, "process-waitFor");
-
-        t.start();
-
-        try {
-            if (!latch.await(10, TimeUnit.SECONDS)) {
-                killOnExit(p);
-                throw new RuntimeException("Timeout waiting for process");
-            }
-        } catch (final InterruptedException e) {
-            killOnExit(p);
-        }
-    }
-
-    public void kill3UNIX() { // debug purpose only
-        if (System.getProperty("os.name", "unknown").toLowerCase().startsWith("windows")) {
-            return;
-        }
-
-        try {
-            final Field f = server.get().getClass().getDeclaredField("pid");
-            f.setAccessible(true);
-            final int pid = (Integer) f.get(server.get());
-            Pipe.pipe(Runtime.getRuntime().exec("kill -3 " + pid));
-        } catch (final Exception e1) {
-            e1.printStackTrace();
-        }
-    }
-
-    private File lib(final String name, final File... dirs) {
-        for (final File dir : dirs) {
-            final File[] files = dir.listFiles();
-            if (files != null) {
-                for (final File file : files) {
-                    if (!file.isFile()) {
-                        continue;
-                    }
-                    if (!file.getName().endsWith(".jar")) {
-                        continue;
-                    }
-                    if (file.getName().startsWith(name)) {
-                        return file;
-                    }
-                }
-            }
-        }
-
-        if (debug) {
-            for (final File dir : dirs) {
-                dumpLibs(dir);
-            }
-        }
-        throw new IllegalStateException("Cannot find the " + name + " jar");
-    }
-
-    // for debug purpose
-    private static void dumpLibs(final File dir) {
-        if (!dir.exists()) {
-            System.out.println("lib dir doesn't exist");
-            return;
-        }
-        final File[] files = dir.listFiles();
-        if (files != null) {
-            for (final File lib : files) {
-                System.out.println(lib.getAbsolutePath());
-            }
-        }
-    }
-
-    public Process getServer() {
-        return server.get();
-    }
-
-    private void addIfSet(final List<String> argsList, final String key) {
-        if (System.getProperties().containsKey(key)) {
-            argsList.add("-D" + key + "=" + System.getProperty(key));
-        }
-    }
-
-    private File getHome() {
-        if (home != null) {
-            return home;
-        }
-
-        final String openejbHome = System.getProperty("openejb.home");
-
-        if (openejbHome != null) {
-            home = new File(openejbHome);
-        }
-        return home;
-    }
-
-    public boolean stop() {
-        if (sendShutdown(5)) {
-            return true;
-        } else {
-            if (verbose) {
-                notSent();
-            }
-
-            return false;
-        }
-    }
-
-    private void notSent() {
-        System.out.println("Failed to send the shutdown notification - TomEE is likely shut down already");
-    }
-
-    public void forceStop() throws Exception {
-        if (sendShutdown(5)) {
-
-            // Check TomEE was effectively shut down after getting the message
-            // There can be concurrent shutdown operations (catalina shutdown hook for instance),
-            // so we have to wait here since it is important to be synchronous in this method
-            waitForServerShutdown();
-        } else {
-            if (verbose) {
-                notSent();
-            }
-        }
-    }
-
-    private void waitForServerShutdown() throws Exception {
-
-        if (verbose) {
-            System.out.print("Waiting for TomEE shutdown.");
-        }
-
-        final boolean b = disconnect(portShutdown, tries);
-
-        if (verbose) {
-            System.out.println();
-        }
-
-        if (!b) {
-            //We need to know about this
-            System.out.println("SEVERE: Failed to shutdown TomEE running on port " + portStartup + " using shutdown port: " + portShutdown);
-        }
-    }
-
-    /**
-     * Send the shutdown message to the running server
-     *
-     * @param attempts How many times to try to send the message before giving up
-     * @return True is the message was sent, else false if unable to connect after the defined number of attempts
-     */
-    private boolean sendShutdown(int attempts) {
-        Socket socket = null;
-        OutputStream stream = null;
-        try {
-            socket = new Socket(host, portShutdown);
-            stream = socket.getOutputStream();
-            final String shutdown = command + Character.toString((char) 0);
-            for (int i = 0; i < shutdown.length(); i++) {
-                stream.write(shutdown.charAt(i));
-            }
-            stream.flush();
-        } catch (final Exception e) {
-            if (attempts > 0) {
-                try {
-                    Thread.sleep(1000);
-                } catch (final InterruptedException ie) {
-                    return false;
-                }
-                return sendShutdown(--attempts);
-            } else {
-                return false;
-            }
-        } finally {
-            if (null != stream) {
-                try {
-                    stream.close();
-                } catch (final Exception e) {
-                    // Ignore
-                }
-            }
-            if (socket != null) {
-                try {
-                    socket.close();
-                } catch (final Exception e) {
-                    // Ignore
-                }
-            }
-        }
-
-        return true;
-    }
-
-    private boolean connect(final int port, int tries) {
-        if (verbose) {
-            System.out.println("[] CONNECT ATTEMPT " + (this.tries - tries) + " on port: " + port);
-        }
-
-        Socket s = null;
-        try {
-            s = new Socket();
-            s.connect(new InetSocketAddress(this.host, port), 1000);
-            s.getOutputStream().close();
-            if (verbose) {
-                System.out.println("[] CONNECTED IN " + (this.tries - tries));
-            }
-        } catch (final Exception e) {
-            if (tries < 2) {
-                if (verbose) {
-                    System.out.println("[] CONNECT ATTEMPTS FAILED ( " + (this.tries - tries) + " ATTEMPTS)");
-                }
-                return false;
-            } else {
-                try {
-                    Thread.sleep(1000);
-                } catch (final Exception e2) {
-                    e2.printStackTrace();
-                }
-                return connect(port, --tries);
-            }
-        } finally {
-            if (s != null) {
-                try {
-                    s.close();
-                } catch (final Exception ignored) {
-                    // no-op
-                }
-            }
-        }
-
-        return true;
-    }
-
-    private boolean disconnect(final int port, int tries) {
-        if (verbose) {
-            System.out.println("[] DISCONNECT ATTEMPT " + (this.tries - tries) + " on port: " + port);
-        }
-
-        Socket s = null;
-        try {
-            s = new Socket();
-            s.connect(new InetSocketAddress(this.host, port), 500);
-            s.getOutputStream().close();
-
-            if (verbose) {
-                System.out.println("[] NOT DISCONNECTED AFTER ( " + (this.tries - tries) + " ATTEMPTS)");
-            }
-
-            if (tries < 2) {
-                //Give up
-                return false;
-            } else {
-                try {
-                    Thread.sleep(1000);
-                } catch (final Exception e2) {
-                    e2.printStackTrace();
-                }
-
-                return disconnect(port, --tries);
-            }
-
-        } catch (final IOException e) {
-            //This is what we want
-        } finally {
-            if (s != null) {
-                try {
-                    s.close();
-                } catch (final Exception ignored) {
-                    // no-op
-                }
-            }
-        }
-
-        return true;
-    }
-
-    public void setAdditionalClasspath(final String additionalClasspath) {
-        this.additionalClasspath = additionalClasspath;
-    }
-
-    public void killOnExit() {
-        final Process p = this.server.get();
-        if (!serverHasAlreadyBeenStarted && kill.contains(p)) {
-            return;
-        }
-
-        killOnExit(p);
-    }
-
-    private static void killOnExit(final Process p) {
-        kill.add(p);
-    }
-
-    // Shutdown hook for processes
-    private static final List<Process> kill = new ArrayList<Process>();
-
-    static {
-        Runtime.getRuntime().addShutdownHook(new CleanUpThread());
-    }
-
-    public static class CleanUpThread extends Thread {
-        @Override
-        public void run() {
-            for (final Process server : kill) {
-                try {
-                    if (server != null) {
-                        server.destroy();
-                        server.waitFor();
-                    }
-                } catch (final Throwable e) {
-                    //Ignore
-                }
-            }
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.config;
+
+import org.apache.openejb.OpenEJBRuntimeException;
+import org.apache.openejb.loader.Options;
+import org.apache.openejb.util.Join;
+import org.apache.openejb.util.Pipe;
+
+import java.io.File;
+import java.io.IOException;
+import java.io.OutputStream;
+import java.lang.reflect.Field;
+import java.net.InetSocketAddress;
+import java.net.Socket;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.atomic.AtomicReference;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+//import org.apache.openejb.loader.IO;
+
+/**
+ * NOTE: Do not add inner or anonymous classes or a dependency without updating ExecMojo
+ *
+ * @version $Rev$ $Date$
+ */
+@SuppressWarnings("UseOfSystemOutOrSystemErr")
+public class RemoteServer {
+
+    private static final Options options = new Options(System.getProperties());
+    public static final String SERVER_DEBUG_PORT = "server.debug.port";
+    public static final String SERVER_SHUTDOWN_PORT = "server.shutdown.port";
+    public static final String SERVER_SHUTDOWN_HOST = "server.shutdown.host";
+    public static final String SERVER_SHUTDOWN_COMMAND = "server.shutdown.command";
+    public static final String OPENEJB_SERVER_DEBUG = "openejb.server.debug";
+    public static final String START = "start";
+    public static final String STOP = "stop";
+
+    private final boolean debug = options.get(OPENEJB_SERVER_DEBUG, false);
+    private final boolean profile = options.get("openejb.server.profile", false);
+    private final boolean tomcat;
+    private final String javaOpts = System.getProperty("java.opts");
+    private String additionalClasspath;
+
+    /**
+     * Has the remote server's instance been already running ?
+     */
+    private boolean serverHasAlreadyBeenStarted = true;
+
+    private Properties properties;
+    private final AtomicReference<Process> server = new AtomicReference<Process>();
+    private final int tries;
+    private final boolean verbose;
+    private final int portShutdown;
+    private final String host;
+    private final String command;
+    private File home;
+    private int portStartup;
+
+    public RemoteServer() {
+        this(options.get("connect.tries", 60), options.get("verbose", false));
+    }
+
+    public RemoteServer(final int tries, final boolean verbose) {
+        this.tries = (tries < 1 ? 1 : (tries > 3600 ? 3600 : tries)); //Wait at least 1 second to start or stop, but not more than an hour.
+        this.verbose = verbose;
+        home = getHome();
+        tomcat = (home != null) && (new File(new File(home, "bin"), "catalina.sh").exists());
+
+        portShutdown = options.get(SERVER_SHUTDOWN_PORT, tomcat ? 8005 : 4200);
+        portStartup = portShutdown;
+        command = options.get(SERVER_SHUTDOWN_COMMAND, "SHUTDOWN");
+        host = options.get(SERVER_SHUTDOWN_HOST, "localhost");
+    }
+
+    public void init(final Properties props) {
+        properties = props;
+
+        props.put("java.naming.factory.initial", "org.apache.openejb.client.RemoteInitialContextFactory");
+        final int port = options.get("ejbd.port", 4201);
+        props.put("java.naming.provider.url", options.get("java.naming.provider.url", "127.0.0.1:" + port));
+        props.put("java.naming.security.principal", "testuser");
+        props.put("java.naming.security.credentials", "testpassword");
+    }
+
+    public static void main(final String[] args) {
+        assert args.length > 0 : "no arguments supplied: valid arguments are 'start' or 'stop'";
+        if (args[0].equalsIgnoreCase(START)) {
+            final RemoteServer remoteServer = new RemoteServer();
+            try {
+                remoteServer.start();
+            } catch (final Exception e) {
+                remoteServer.destroy();
+                e.printStackTrace(System.err);
+            }
+        } else if (args[0].equalsIgnoreCase(STOP)) {
+            final RemoteServer remoteServer = new RemoteServer();
+            remoteServer.serverHasAlreadyBeenStarted = false;
+            try {
+                remoteServer.forceStop();
+            } catch (final Exception e) {
+                e.printStackTrace(System.err);
+            }
+        } else {
+            throw new OpenEJBRuntimeException("valid arguments are 'start' or 'stop'");
+        }
+    }
+
+    public int getPortStartup() {
+        return this.portStartup;
+    }
+
+    public void setPortStartup(final int portStartup) {
+        this.portStartup = portStartup;
+    }
+
+    public Properties getProperties() {
+        return this.properties;
+    }
+
+    public void destroy() {
+
+        try {
+            final boolean stopSent = stop();
+
+            final Process p = server.get();
+            if (p != null) {
+
+                if (stopSent) {
+                    waitFor(p);
+                } else {
+                    p.destroy();
+                }
+            }
+        } catch (final Exception e) {
+            Logger.getLogger(RemoteServer.class.getName()).log(Level.WARNING, "Failed to destroy remote server process", e);
+        }
+    }
+
+    public void start() {
+        start(Collections.<String>emptyList(), START, true);
+    }
+
+    public void start(final List<String> additionalArgs, final String cmd, final boolean checkPortAvailable) {
+        cmd(additionalArgs, cmd, checkPortAvailable);
+    }
+
+    private void cmd(final List<String> additionalArgs, final String cmd, final boolean checkPortAvailable) {
+        boolean ok = true;
+        final int port = START.equals(cmd) ? portStartup : portShutdown;
+
+        if (checkPortAvailable) {
+            ok = !connect(port, 1);
+        }
+
+        if (ok) {
+            try {
+                if (verbose) {
+                    System.out.println("[] " + cmd.toUpperCase() + " SERVER");
+                }
+
+                final File home = getHome();
+                final String javaVersion = System.getProperty("java.version");
+                if (verbose) {
+                    System.out.println("OPENEJB_HOME = " + home.getAbsolutePath());
+                    final String systemInfo = "Java " + javaVersion + "; " + System.getProperty("os.name") + "/" + System.getProperty("os.version");
+                    System.out.println("SYSTEM_INFO  = " + systemInfo);
+                }
+
+                serverHasAlreadyBeenStarted = false;
+
+                final File lib = new File(home, "lib");
+                final File webapplib = new File(new File(new File(home, "webapps"), "tomee"), "lib");
+
+                File javaagentJar = null;
+                try {
+                    javaagentJar = lib("openejb-javaagent", lib, webapplib);
+                } catch (final IllegalStateException ise) {
+                    // no-op
+                }
+
+                final File conf = new File(home, "conf");
+                final File loggingProperties = new File(conf, "logging.properties");
+
+                //File openejbJar = new File(lib, "openejb-core-" + version + ".jar");
+
+                final String java;
+                final boolean isWindows = System.getProperty("os.name", "unknown").toLowerCase().startsWith("windows");
+                if (isWindows && START.equals(cmd) && options.get("server.windows.fork", false)) {
+                    // run and forget
+                    java = new File(System.getProperty("java.home"), "bin/javaw").getAbsolutePath();
+                } else {
+                    java = new File(System.getProperty("java.home"), "bin/java").getAbsolutePath();
+                }
+
+                final List<String> argsList = new ArrayList<String>(20);
+                argsList.add(java);
+                argsList.add("-XX:+HeapDumpOnOutOfMemoryError");
+
+                if (debug) {
+                    argsList.add("-Xdebug");
+                    argsList.add("-Xnoagent");
+                    argsList.add("-Djava.compiler=NONE");
+                    argsList.add("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=" + options.get(SERVER_DEBUG_PORT, 5005));
+                }
+
+                if (profile) {
+                    String yourkitHome = options.get("yourkit.home", "/Applications/YourKit_Java_Profiler_9.5.6.app/bin/mac/");
+                    if (!yourkitHome.endsWith("/")) {
+                        yourkitHome += "/";
+                    }
+                    final String yourkitOpts = options.get("yourkit.opts", "disablestacktelemetry,disableexceptiontelemetry,builtinprobes=none,delay=10000,sessionname=Tomcat");
+                    argsList.add("-agentpath:" + yourkitHome + "libyjpagent.jnilib=" + yourkitOpts);
+                }
+
+                if (javaOpts != null) {
+                    Collections.addAll(argsList, javaOpts.split(" +"));
+                }
+
+                final Map<String, String> addedArgs = new HashMap<String, String>();
+                if (additionalArgs != null) {
+                    for (final String arg : additionalArgs) {
+                        final String[] values = arg.split("=");
+                        if (values.length == 1) {
+                            addedArgs.put(values[0], "null");
+                        } else {
+                            addedArgs.put(values[0], values[1]);
+                        }
+                        argsList.add(arg);
+                    }
+                }
+
+                if (!addedArgs.containsKey("-Djava.util.logging.config.file") && loggingProperties.exists()) {
+                    argsList.add("-Djava.util.logging.config.file=" + loggingProperties.getAbsolutePath());
+                }
+
+                if (javaagentJar != null && javaagentJar.exists()) {
+                    argsList.add("-javaagent:" + javaagentJar.getAbsolutePath());
+                }
+
+                //DMB: If you don't use an array, you get problems with jar paths containing spaces
+                // the command won't parse correctly
+                final String ps = File.pathSeparator;
+
+                final String[] args;
+                if (!tomcat) {
+                    final File openejbJar = lib("openejb-core", lib, webapplib);
+                    final StringBuilder cp = new StringBuilder(openejbJar.getAbsolutePath());
+                    if (additionalClasspath != null) {
+                        cp.append(ps).append(additionalClasspath);
+                    }
+
+                    argsList.add("-cp");
+                    argsList.add(cp.toString());
+                    argsList.add("org.apache.openejb.cli.Bootstrap");
+                } else {
+                    final File bin = new File(home, "bin");
+                    final File tlib = new File(home, "lib");
+                    final File bootstrapJar = new File(bin, "bootstrap.jar");
+                    final File juliJar = new File(bin, "tomcat-juli.jar");
+                    final File commonsLoggingJar = new File(bin, "commons-logging-api.jar");
+
+                    final File endorsed = new File(home, "endorsed");
+                    final File temp = new File(home, "temp");
+
+//                    if (!addedArgs.containsKey("-Dcom.sun.management.jmxremote")) {
+//                        argsList.add("-Dcom.sun.management.jmxremote");
+//                    }
+                    if (!addedArgs.containsKey("-Djava.util.logging.manager")) {
+                        argsList.add("-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager");
+                    }
+                    if (!addedArgs.containsKey("-Djava.io.tmpdir")) {
+                        argsList.add("-Djava.io.tmpdir=" + temp.getAbsolutePath());
+                    }
+                    if (!addedArgs.containsKey("-Djava.endorsed.dirs")) {
+                        argsList.add("-Djava.endorsed.dirs=" + endorsed.getAbsolutePath());
+                    }
+                    if (!addedArgs.containsKey("-Dcatalina.base")) {
+                        argsList.add("-Dcatalina.base=" + home.getAbsolutePath());
+                    }
+                    if (!addedArgs.containsKey("-Dcatalina.home")) {
+                        argsList.add("-Dcatalina.home=" + home.getAbsolutePath());
+                    }
+                    if (!addedArgs.containsKey("-Dcatalina.ext.dirs")) {
+                        argsList.add("-Dcatalina.ext.dirs=" + tlib.getAbsolutePath());
+                    }
+                    if (!addedArgs.containsKey("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE")) {
+                        argsList.add("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true");
+                    }
+                    if (!addedArgs.containsKey("-Dorg.apache.tomcat.util.http.ServerCookie.ALLOW_HTTP_SEPARATORS_IN_V0")) {
+                        argsList.add("-Dorg.apache.tomcat.util.http.ServerCookie.ALLOW_HTTP_SEPARATORS_IN_V0=true");
+                    }
+
+                    if (addedArgs.isEmpty()) { // default case
+                        addIfSet(argsList, "javax.net.ssl.keyStore");
+                        addIfSet(argsList, "javax.net.ssl.keyStorePassword");
+                        addIfSet(argsList, "javax.net.ssl.trustStore");
+                        addIfSet(argsList, "java.protocol.handler.pkgs");
+                    }
+
+                    argsList.add("-ea");
+                    argsList.add("-classpath");
+
+                    final StringBuilder cp = new StringBuilder(bootstrapJar.getAbsolutePath()).append(ps).append(juliJar.getAbsolutePath());
+                    if (commonsLoggingJar.exists()) {
+                        cp.append(ps).append(commonsLoggingJar.getAbsolutePath());
+                    }
+                    if (additionalClasspath != null) {
+                        cp.append(ps).append(additionalClasspath);
+                    }
+                    argsList.add(cp.toString());
+
+                    argsList.add("org.apache.catalina.startup.Bootstrap");
+                }
+
+                if (cmd == null) {
+                    argsList.add(START);
+                } else {
+                    argsList.add(cmd);
+                }
+                args = argsList.toArray(new String[argsList.size()]);
+
+                if (verbose) {
+                    System.out.println(Join.join("\n", args));
+                }
+
+                // kill3UNIXDebug();
+                final ProcessBuilder pb = new ProcessBuilder(args);
+                pb.directory(home.getAbsoluteFile());
+                Process p = pb.start();
+
+                //Process p = Runtime.getRuntime().exec(args);
+                Pipe.pipeOut(p); // why would we need to redirect System.in to the process, TomEE doesn't use it
+
+                if (START.equals(cmd)) {
+                    server.set(p);
+                } else if (STOP.equals(cmd)) {
+                    waitFor(p);
+                    p = server.get();
+                    if (p != null) {
+                        waitFor(p);
+                    }
+                }
+
+                System.out.println("Started server process on port: " + port);
+
+            } catch (final Exception e) {
+                throw (RuntimeException) new OpenEJBRuntimeException("Cannot start the server.  Exception: " + e.getClass().getName() + ": " + e.getMessage()).initCause(e);
+            }
+
+            if (debug) {
+                if (!connect(port, Integer.MAX_VALUE)) {
+                    throw new OpenEJBRuntimeException("Could not connect to server: " + this.host + ":" + port);
+                }
+            } else {
+                if (!connect(port, tries)) {
+                    throw new OpenEJBRuntimeException("Could not connect to server: " + this.host + ":" + port);
+                }
+            }
+
+        } else {
+            if (verbose) {
+                System.out.println("[] FOUND STARTED SERVER");
+            }
+        }
+    }
+
+    private void waitFor(final Process p) {
+        final CountDownLatch latch = new CountDownLatch(1);
+        final Thread t = new Thread(new Runnable() {
+            @Override
+            public void run() {
+                try {
+                    p.waitFor();
+                } catch (final InterruptedException e) {
+                    //Ignore
+                }
+
+                latch.countDown();
+            }
+        }, "process-waitFor");
+
+        t.start();
+
+        try {
+            if (!latch.await(10, TimeUnit.SECONDS)) {
+                killOnExit(p);
+                throw new RuntimeException("Timeout waiting for process");
+            }
+        } catch (final InterruptedException e) {
+            killOnExit(p);
+        }
+    }
+
+    public void kill3UNIX() { // debug purpose only
+        if (System.getProperty("os.name", "unknown").toLowerCase().startsWith("windows")) {
+            return;
+        }
+
+        try {
+            final Field f = server.get().getClass().getDeclaredField("pid");
+            f.setAccessible(true);
+            final int pid = (Integer) f.get(server.get());
+            Pipe.pipe(Runtime.getRuntime().exec("kill -3 " + pid));
+        } catch (final Exception e1) {
+            e1.printStackTrace();
+        }
+    }
+
+    private File lib(final String name, final File... dirs) {
+        for (final File dir : dirs) {
+            final File[] files = dir.listFiles();
+            if (files != null) {
+                for (final File file : files) {
+                    if (!file.isFile()) {
+                        continue;
+                    }
+                    if (!file.getName().endsWith(".jar")) {
+                        continue;
+                    }
+                    if (file.getName().startsWith(name)) {
+                        return file;
+                    }
+                }
+            }
+        }
+
+        if (debug) {
+            for (final File dir : dirs) {
+                dumpLibs(dir);
+            }
+        }
+        throw new IllegalStateException("Cannot find the " + name + " jar");
+    }
+
+    // for debug purpose
+    private static void dumpLibs(final File dir) {
+        if (!dir.exists()) {
+            System.out.println("lib dir doesn't exist");
+            return;
+        }
+        final File[] files = dir.listFiles();
+        if (files != null) {
+            for (final File lib : files) {
+                System.out.println(lib.getAbsolutePath());
+            }
+        }
+    }
+
+    public Process getServer() {
+        return server.get();
+    }
+
+    private void addIfSet(final List<String> argsList, final String key) {
+        if (System.getProperties().containsKey(key)) {
+            argsList.add("-D" + key + "=" + System.getProperty(key));
+        }
+    }
+
+    private File getHome() {
+        if (home != null) {
+            return home;
+        }
+
+        final String openejbHome = System.getProperty("openejb.home");
+
+        if (openejbHome != null) {
+            home = new File(openejbHome);
+        }
+        return home;
+    }
+
+    public boolean stop() {
+        if (sendShutdown(5)) {
+            return true;
+        } else {
+            if (verbose) {
+                notSent();
+            }
+
+            return false;
+        }
+    }
+
+    private void notSent() {
+        System.out.println("Failed to send the shutdown notification - TomEE is likely shut down already");
+    }
+
+    public void forceStop() throws Exception {
+        if (sendShutdown(5)) {
+
+            // Check TomEE was effectively shut down after getting the message
+            // There can be concurrent shutdown operations (catalina shutdown hook for instance),
+            // so we have to wait here since it is important to be synchronous in this method
+            waitForServerShutdown();
+        } else {
+            if (verbose) {
+                notSent();
+            }
+        }
+    }
+
+    private void waitForServerShutdown() throws Exception {
+
+        if (verbose) {
+            System.out.print("Waiting for TomEE shutdown.");
+        }
+
+        final boolean b = disconnect(portShutdown, tries);
+
+        if (verbose) {
+            System.out.println();
+        }
+
+        if (!b) {
+            //We need to know about this
+            System.out.println("SEVERE: Failed to shutdown TomEE running on port " + portStartup + " using shutdown port: " + portShutdown);
+        }
+    }
+
+    /**
+     * Send the shutdown message to the running server
+     *
+     * @param attempts How many times to try to send the message before giving up
+     * @return True is the message was sent, else false if unable to connect after the defined number of attempts
+     */
+    private boolean sendShutdown(int attempts) {
+        Socket socket = null;
+        OutputStream stream = null;
+        try {
+            socket = new Socket(host, portShutdown);
+            stream = socket.getOutputStream();
+            final String shutdown = command + Character.toString((char) 0);
+            for (int i = 0; i < shutdown.length(); i++) {
+                stream.write(shutdown.charAt(i));
+            }
+            stream.flush();
+        } catch (final Exception e) {
+            if (attempts > 0) {
+                try {
+                    Thread.sleep(1000);
+                } catch (final InterruptedException ie) {
+                    return false;
+                }
+                return sendShutdown(--attempts);
+            } else {
+                return false;
+            }
+        } finally {
+            if (null != stream) {
+                try {
+                    stream.close();
+                } catch (final Exception e) {
+                    // Ignore
+                }
+            }
+            if (socket != null) {
+                try {
+                    socket.close();
+                } catch (final Exception e) {
+                    // Ignore
+                }
+            }
+        }
+
+        return true;
+    }
+
+    private boolean connect(final int port, int tries) {
+        if (verbose) {
+            System.out.println("[] CONNECT ATTEMPT " + (this.tries - tries) + " on port: " + port);
+        }
+
+        Socket s = null;
+        try {
+            s = new Socket();
+            s.connect(new InetSocketAddress(this.host, port), 1000);
+            s.getOutputStream().close();
+            if (verbose) {
+                System.out.println("[] CONNECTED IN " + (this.tries - tries));
+            }
+        } catch (final Exception e) {
+            if (tries < 2) {
+                if (verbose) {
+                    System.out.println("[] CONNECT ATTEMPTS FAILED ( " + (this.tries - tries) + " ATTEMPTS)");
+                }
+                return false;
+            } else {
+                try {
+                    Thread.sleep(1000);
+                } catch (final Exception e2) {
+                    e2.printStackTrace();
+                }
+                return connect(port, --tries);
+            }
+        } finally {
+            if (s != null) {
+                try {
+                    s.close();
+                } catch (final Exception ignored) {
+                    // no-op
+                }
+            }
+        }
+
+        return true;
+    }
+
+    private boolean disconnect(final int port, int tries) {
+        if (verbose) {
+            System.out.println("[] DISCONNECT ATTEMPT " + (this.tries - tries) + " on port: " + port);
+        }
+
+        Socket s = null;
+        try {
+            s = new Socket();
+            s.connect(new InetSocketAddress(this.host, port), 500);
+            s.getOutputStream().close();
+
+            if (verbose) {
+                System.out.println("[] NOT DISCONNECTED AFTER ( " + (this.tries - tries) + " ATTEMPTS)");
+            }
+
+            if (tries < 2) {
+                //Give up
+                return false;
+            } else {
+                try {
+                    Thread.sleep(1000);
+                } catch (final Exception e2) {
+                    e2.printStackTrace();
+                }
+
+                return disconnect(port, --tries);
+            }
+
+        } catch (final IOException e) {
+            //This is what we want
+        } finally {
+            if (s != null) {
+                try {
+                    s.close();
+                } catch (final Exception ignored) {
+                    // no-op
+                }
+            }
+        }
+
+        return true;
+    }
+
+    public void setAdditionalClasspath(final String additionalClasspath) {
+        this.additionalClasspath = additionalClasspath;
+    }
+
+    public void killOnExit() {
+        final Process p = this.server.get();
+        if (!serverHasAlreadyBeenStarted && kill.contains(p)) {
+            return;
+        }
+
+        killOnExit(p);
+    }
+
+    private static void killOnExit(final Process p) {
+        kill.add(p);
+    }
+
+    // Shutdown hook for processes
+    private static final List<Process> kill = new ArrayList<Process>();
+
+    static {
+        Runtime.getRuntime().addShutdownHook(new CleanUpThread());
+    }
+
+    public static class CleanUpThread extends Thread {
+        @Override
+        public void run() {
+            for (final Process server : kill) {
+                try {
+                    if (server != null) {
+                        server.destroy();
+                        server.waitFor();
+                    }
+                } catch (final Throwable e) {
+                    //Ignore
+                }
+            }
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAnnotations.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAnnotations.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAnnotations.java
index 8a6adce..1ff2611 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAnnotations.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAnnotations.java
@@ -1,96 +1,96 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.config.WebModule;
-import org.apache.openejb.util.LogCategory;
-import org.apache.openejb.util.Logger;
-import org.apache.xbean.finder.IAnnotationFinder;
-
-import javax.jws.WebService;
-import java.lang.annotation.Annotation;
-import java.util.Arrays;
-import java.util.List;
-
-public class CheckAnnotations extends ValidationBase {
-
-    Logger logger = Logger.getInstance(LogCategory.OPENEJB_STARTUP_VALIDATION, CheckAnnotations.class);
-
-    @Override
-    public void validate(final AppModule appModule) {
-        try {
-
-            for (final EjbModule ejbModule : appModule.getEjbModules()) {
-                module = ejbModule;
-                findClassesAnnotatedWithWebService(ejbModule);
-            }
-
-            for (final WebModule webModule : appModule.getWebModules()) {
-                module = webModule;
-                findClassesAnnotatedWithWebService(webModule);
-            }
-
-        } catch (final Exception e) {
-            logger.error("Error while validating @WebService annotation", e);
-        }
-
-
-    }
-
-    private void findClassesAnnotatedWithWebService(final EjbModule ejbModule) {
-
-        final IAnnotationFinder finder = ejbModule.getFinder();
-        if (finder != null) {
-            findIncorrectAnnotationAndWarn(finder, ejbModule.toString());
-        }
-    }
-
-
-    private void findClassesAnnotatedWithWebService(final WebModule webModule) {
-        final IAnnotationFinder finder = webModule.getFinder();
-        if (finder != null) {
-            findIncorrectAnnotationAndWarn(finder, webModule.toString());
-        }
-
-    }
-
-    private void findIncorrectAnnotationAndWarn(final IAnnotationFinder finder, final String component) {
-        final List<Class<?>> webserviceAnnotatedClasses = finder.findAnnotatedClasses(WebService.class);
-        for (final Class clazz : webserviceAnnotatedClasses) {
-            final Annotation[] annotations = clazz.getDeclaredAnnotations();
-
-            final List<Annotation> declaredAnnotations = Arrays.asList(annotations);
-            for (final Annotation declaredAnn : declaredAnnotations) {
-                if (declaredAnn.annotationType().getName().equals("javax.ejb.Stateful")) {
-                    warn(component, "annotation.invalid.stateful.webservice", clazz.getName());
-                }
-                if (declaredAnn.annotationType().getName().equals("javax.annotation.ManagedBean")) {
-                    warn(component, "annotation.invalid.managedbean.webservice", clazz.getName());
-                }
-                if (declaredAnn.annotationType().getName().equals("javax.ejb.MessageDriven")) {
-                    warn(component, "annotation.invalid.messagedriven.webservice", clazz.getName());
-                }
-
-            }
-        }
-    }
-
-
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.config.WebModule;
+import org.apache.openejb.util.LogCategory;
+import org.apache.openejb.util.Logger;
+import org.apache.xbean.finder.IAnnotationFinder;
+
+import javax.jws.WebService;
+import java.lang.annotation.Annotation;
+import java.util.Arrays;
+import java.util.List;
+
+public class CheckAnnotations extends ValidationBase {
+
+    Logger logger = Logger.getInstance(LogCategory.OPENEJB_STARTUP_VALIDATION, CheckAnnotations.class);
+
+    @Override
+    public void validate(final AppModule appModule) {
+        try {
+
+            for (final EjbModule ejbModule : appModule.getEjbModules()) {
+                module = ejbModule;
+                findClassesAnnotatedWithWebService(ejbModule);
+            }
+
+            for (final WebModule webModule : appModule.getWebModules()) {
+                module = webModule;
+                findClassesAnnotatedWithWebService(webModule);
+            }
+
+        } catch (final Exception e) {
+            logger.error("Error while validating @WebService annotation", e);
+        }
+
+
+    }
+
+    private void findClassesAnnotatedWithWebService(final EjbModule ejbModule) {
+
+        final IAnnotationFinder finder = ejbModule.getFinder();
+        if (finder != null) {
+            findIncorrectAnnotationAndWarn(finder, ejbModule.toString());
+        }
+    }
+
+
+    private void findClassesAnnotatedWithWebService(final WebModule webModule) {
+        final IAnnotationFinder finder = webModule.getFinder();
+        if (finder != null) {
+            findIncorrectAnnotationAndWarn(finder, webModule.toString());
+        }
+
+    }
+
+    private void findIncorrectAnnotationAndWarn(final IAnnotationFinder finder, final String component) {
+        final List<Class<?>> webserviceAnnotatedClasses = finder.findAnnotatedClasses(WebService.class);
+        for (final Class clazz : webserviceAnnotatedClasses) {
+            final Annotation[] annotations = clazz.getDeclaredAnnotations();
+
+            final List<Annotation> declaredAnnotations = Arrays.asList(annotations);
+            for (final Annotation declaredAnn : declaredAnnotations) {
+                if (declaredAnn.annotationType().getName().equals("javax.ejb.Stateful")) {
+                    warn(component, "annotation.invalid.stateful.webservice", clazz.getName());
+                }
+                if (declaredAnn.annotationType().getName().equals("javax.annotation.ManagedBean")) {
+                    warn(component, "annotation.invalid.managedbean.webservice", clazz.getName());
+                }
+                if (declaredAnn.annotationType().getName().equals("javax.ejb.MessageDriven")) {
+                    warn(component, "annotation.invalid.messagedriven.webservice", clazz.getName());
+                }
+
+            }
+        }
+    }
+
+
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNames.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNames.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNames.java
index e2e3eaf..8b85bb3 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNames.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckIncorrectPropertyNames.java
@@ -1,84 +1,84 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.loader.SystemInstance;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Properties;
-
-public class CheckIncorrectPropertyNames extends ValidationBase {
-
-    Map incorrectAndCorrectPropNames = new HashMap<String, String>();
-
-    {
-        //incorrect property key : correct property key
-        incorrectAndCorrectPropNames.put("java.persistence.provider", "javax.persistence.provider");
-        incorrectAndCorrectPropNames.put("java.persistence.transactionType", "javax.persistence.transactionType");
-        incorrectAndCorrectPropNames.put("java.persistence.jtaDataSource", "javax.persistence.jtaDataSource");
-        incorrectAndCorrectPropNames.put("java.persistence.nonJtaDataSource", "javax.persistence.nonJtaDataSource");
-        incorrectAndCorrectPropNames.put("java.net.ssl.keyStore", "javax.net.ssl.keyStore");
-        incorrectAndCorrectPropNames.put("java.net.ssl.keyStorePassword", "javax.net.ssl.keyStorePassword");
-        incorrectAndCorrectPropNames.put("java.net.ssl.trustStore", "javax.net.ssl.trustStore");
-        incorrectAndCorrectPropNames.put("java.security.jacc.PolicyConfigurationFactory.provider", "javax.security.jacc.PolicyConfigurationFactory.provider");
-        incorrectAndCorrectPropNames.put("java.security.jacc.policy.provider", "javax.security.jacc.policy.provider");
-        incorrectAndCorrectPropNames.put("java.xml.ws.spi.Provider", "javax.xml.ws.spi.Provider");
-        incorrectAndCorrectPropNames.put("java.xml.soap.MessageFactory", "javax.xml.soap.MessageFactory");
-        incorrectAndCorrectPropNames.put("java.xml.soap.SOAPFactory", "javax.xml.soap.SOAPFactory");
-        incorrectAndCorrectPropNames.put("java.xml.soap.SOAPConnectionFactory", "javax.xml.soap.SOAPConnectionFactory");
-        incorrectAndCorrectPropNames.put("java.xml.soap.MetaFactory", "javax.xml.soap.MetaFactory");
-        incorrectAndCorrectPropNames.put("java.persistence.sharedCache.mode", "javax.persistence.sharedCache.mode");
-        incorrectAndCorrectPropNames.put("java.persistence.validation.mode", "javax.persistence.validation.mode");
-        incorrectAndCorrectPropNames.put("java.persistence.transactionType", "javax.persistence.transactionType");
-
-        incorrectAndCorrectPropNames.put("javax.naming.applet", "java.naming.applet");
-        incorrectAndCorrectPropNames.put("javax.naming.authoritative", "java.naming.authoritative");
-        incorrectAndCorrectPropNames.put("javax.naming.batchsize", "java.naming.batchsize");
-        incorrectAndCorrectPropNames.put("javax.naming.dns.url", "java.naming.dns.url");
-        incorrectAndCorrectPropNames.put("javax.naming.factory.initial", "java.naming.factory.initial");
-        incorrectAndCorrectPropNames.put("javax.naming.factory.object", "java.naming.factory.object");
-        incorrectAndCorrectPropNames.put("javax.naming.factory.state", "java.naming.factory.state");
-        incorrectAndCorrectPropNames.put("javax.naming.factory.url.pkgs", "java.naming.factory.url.pkgs");
-        incorrectAndCorrectPropNames.put("javax.naming.language", "java.naming.language");
-        incorrectAndCorrectPropNames.put("javax.naming.provider.url", "java.naming.provider.url");
-        incorrectAndCorrectPropNames.put("javax.naming.referral", "java.naming.referral");
-        incorrectAndCorrectPropNames.put("javax.naming.security.authentication", "java.naming.security.authentication");
-        incorrectAndCorrectPropNames.put("javax.naming.security.credentials", "java.naming.security.credentials");
-        incorrectAndCorrectPropNames.put("javax.naming.security.principal", "java.naming.security.principal");
-        incorrectAndCorrectPropNames.put("javax.naming.security.protocol", "java.naming.security.protocol");
-
-    }
-
-    @Override
-    public void validate(final AppModule appModule) {
-        this.module = appModule;
-        final Properties systemProperties = SystemInstance.get().getProperties();
-
-        final Iterator iterator = incorrectAndCorrectPropNames.entrySet().iterator();
-        while (iterator.hasNext()) {
-            final Map.Entry<String, String> entry = (Map.Entry<String, String>) iterator.next();
-            if (systemProperties.containsKey(entry.getKey())) {
-                warn(appModule.toString(), "incorrect.property.name", entry.getKey(), entry.getValue());
-            }
-        }
-
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.loader.SystemInstance;
+
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.Properties;
+
+public class CheckIncorrectPropertyNames extends ValidationBase {
+
+    Map incorrectAndCorrectPropNames = new HashMap<String, String>();
+
+    {
+        //incorrect property key : correct property key
+        incorrectAndCorrectPropNames.put("java.persistence.provider", "javax.persistence.provider");
+        incorrectAndCorrectPropNames.put("java.persistence.transactionType", "javax.persistence.transactionType");
+        incorrectAndCorrectPropNames.put("java.persistence.jtaDataSource", "javax.persistence.jtaDataSource");
+        incorrectAndCorrectPropNames.put("java.persistence.nonJtaDataSource", "javax.persistence.nonJtaDataSource");
+        incorrectAndCorrectPropNames.put("java.net.ssl.keyStore", "javax.net.ssl.keyStore");
+        incorrectAndCorrectPropNames.put("java.net.ssl.keyStorePassword", "javax.net.ssl.keyStorePassword");
+        incorrectAndCorrectPropNames.put("java.net.ssl.trustStore", "javax.net.ssl.trustStore");
+        incorrectAndCorrectPropNames.put("java.security.jacc.PolicyConfigurationFactory.provider", "javax.security.jacc.PolicyConfigurationFactory.provider");
+        incorrectAndCorrectPropNames.put("java.security.jacc.policy.provider", "javax.security.jacc.policy.provider");
+        incorrectAndCorrectPropNames.put("java.xml.ws.spi.Provider", "javax.xml.ws.spi.Provider");
+        incorrectAndCorrectPropNames.put("java.xml.soap.MessageFactory", "javax.xml.soap.MessageFactory");
+        incorrectAndCorrectPropNames.put("java.xml.soap.SOAPFactory", "javax.xml.soap.SOAPFactory");
+        incorrectAndCorrectPropNames.put("java.xml.soap.SOAPConnectionFactory", "javax.xml.soap.SOAPConnectionFactory");
+        incorrectAndCorrectPropNames.put("java.xml.soap.MetaFactory", "javax.xml.soap.MetaFactory");
+        incorrectAndCorrectPropNames.put("java.persistence.sharedCache.mode", "javax.persistence.sharedCache.mode");
+        incorrectAndCorrectPropNames.put("java.persistence.validation.mode", "javax.persistence.validation.mode");
+        incorrectAndCorrectPropNames.put("java.persistence.transactionType", "javax.persistence.transactionType");
+
+        incorrectAndCorrectPropNames.put("javax.naming.applet", "java.naming.applet");
+        incorrectAndCorrectPropNames.put("javax.naming.authoritative", "java.naming.authoritative");
+        incorrectAndCorrectPropNames.put("javax.naming.batchsize", "java.naming.batchsize");
+        incorrectAndCorrectPropNames.put("javax.naming.dns.url", "java.naming.dns.url");
+        incorrectAndCorrectPropNames.put("javax.naming.factory.initial", "java.naming.factory.initial");
+        incorrectAndCorrectPropNames.put("javax.naming.factory.object", "java.naming.factory.object");
+        incorrectAndCorrectPropNames.put("javax.naming.factory.state", "java.naming.factory.state");
+        incorrectAndCorrectPropNames.put("javax.naming.factory.url.pkgs", "java.naming.factory.url.pkgs");
+        incorrectAndCorrectPropNames.put("javax.naming.language", "java.naming.language");
+        incorrectAndCorrectPropNames.put("javax.naming.provider.url", "java.naming.provider.url");
+        incorrectAndCorrectPropNames.put("javax.naming.referral", "java.naming.referral");
+        incorrectAndCorrectPropNames.put("javax.naming.security.authentication", "java.naming.security.authentication");
+        incorrectAndCorrectPropNames.put("javax.naming.security.credentials", "java.naming.security.credentials");
+        incorrectAndCorrectPropNames.put("javax.naming.security.principal", "java.naming.security.principal");
+        incorrectAndCorrectPropNames.put("javax.naming.security.protocol", "java.naming.security.protocol");
+
+    }
+
+    @Override
+    public void validate(final AppModule appModule) {
+        this.module = appModule;
+        final Properties systemProperties = SystemInstance.get().getProperties();
+
+        final Iterator iterator = incorrectAndCorrectPropNames.entrySet().iterator();
+        while (iterator.hasNext()) {
+            final Map.Entry<String, String> entry = (Map.Entry<String, String>) iterator.next();
+            if (systemProperties.containsKey(entry.getKey())) {
+                warn(appModule.toString(), "incorrect.property.name", entry.getKey(), entry.getValue());
+            }
+        }
+
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/injection/FallbackPropertyInjector.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/injection/FallbackPropertyInjector.java b/container/openejb-core/src/main/java/org/apache/openejb/injection/FallbackPropertyInjector.java
index c886a92..8a176fd 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/injection/FallbackPropertyInjector.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/injection/FallbackPropertyInjector.java
@@ -1,24 +1,24 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.injection;
-
-import org.apache.openejb.Injection;
-
-public interface FallbackPropertyInjector {
-    Object getValue(final Injection prefix);
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.injection;
+
+import org.apache.openejb.Injection;
+
+public interface FallbackPropertyInjector {
+    Object getValue(final Injection prefix);
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/persistence/QueryOperation.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/persistence/QueryOperation.java b/container/openejb-core/src/main/java/org/apache/openejb/persistence/QueryOperation.java
index 949764e..01eba63 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/persistence/QueryOperation.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/persistence/QueryOperation.java
@@ -1,24 +1,24 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.persistence;
-
-import javax.persistence.Query;
-
-public interface QueryOperation {
-    Query apply(final Query query);
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.persistence;
+
+import javax.persistence.Query;
+
+public interface QueryOperation {
+    Query apply(final Query query);
+}


[02/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ParamValue.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ParamValue.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ParamValue.java
index 3e46e07..c4ddecb 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ParamValue.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ParamValue.java
@@ -1,339 +1,339 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 This type is a general type that can be used to declare
- * parameter/value lists.
- * <p/>
- * <p/>
- * <p/>
- * Java class for ParamValue complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="ParamValue">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "ParamValue", propOrder = {"descriptions", "extensions"})
-public class ParamValue {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected String value;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the value property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getValue() {
-        return value;
-    }
-
-    /**
-     * Sets the value of the value property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setValue(final String value) {
-        this.value = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 This type is a general type that can be used to declare
+ * parameter/value lists.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for ParamValue complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="ParamValue">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "ParamValue", propOrder = {"descriptions", "extensions"})
+public class ParamValue {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected String value;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the value property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getValue() {
+        return value;
+    }
+
+    /**
+     * Sets the value of the value property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setValue(final String value) {
+        this.value = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/QName.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/QName.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/QName.java
index 7e133f8..806e7f4 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/QName.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/QName.java
@@ -1,321 +1,321 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * <p/>
- * Java class for QName complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="QName">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="combinedQName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="internalPrefixOrNsURI" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="localPart" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="namespaceURI" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "QName", propOrder = {"extensions"})
-public class QName {
-
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String combinedQName;
-    @XmlAttribute
-    protected String internalPrefixOrNsURI;
-    @XmlAttribute
-    protected String localPart;
-    @XmlAttribute
-    protected String namespaceURI;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected javax.xml.namespace.QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the combinedQName property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getCombinedQName() {
-        return combinedQName;
-    }
-
-    /**
-     * Sets the value of the combinedQName property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setCombinedQName(final String value) {
-        this.combinedQName = value;
-    }
-
-    /**
-     * Gets the value of the internalPrefixOrNsURI property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getInternalPrefixOrNsURI() {
-        return internalPrefixOrNsURI;
-    }
-
-    /**
-     * Sets the value of the internalPrefixOrNsURI property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setInternalPrefixOrNsURI(final String value) {
-        this.internalPrefixOrNsURI = value;
-    }
-
-    /**
-     * Gets the value of the localPart property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLocalPart() {
-        return localPart;
-    }
-
-    /**
-     * Sets the value of the localPart property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLocalPart(final String value) {
-        this.localPart = value;
-    }
-
-    /**
-     * Gets the value of the namespaceURI property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getNamespaceURI() {
-        return namespaceURI;
-    }
-
-    /**
-     * Sets the value of the namespaceURI property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setNamespaceURI(final String value) {
-        this.namespaceURI = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link javax.xml.namespace.QName }
-     */
-    public javax.xml.namespace.QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link javax.xml.namespace.QName }
-     */
-    public void setType(final javax.xml.namespace.QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * <p/>
+ * Java class for QName complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="QName">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="combinedQName" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="internalPrefixOrNsURI" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="localPart" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="namespaceURI" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "QName", propOrder = {"extensions"})
+public class QName {
+
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String combinedQName;
+    @XmlAttribute
+    protected String internalPrefixOrNsURI;
+    @XmlAttribute
+    protected String localPart;
+    @XmlAttribute
+    protected String namespaceURI;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected javax.xml.namespace.QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the combinedQName property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getCombinedQName() {
+        return combinedQName;
+    }
+
+    /**
+     * Sets the value of the combinedQName property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setCombinedQName(final String value) {
+        this.combinedQName = value;
+    }
+
+    /**
+     * Gets the value of the internalPrefixOrNsURI property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getInternalPrefixOrNsURI() {
+        return internalPrefixOrNsURI;
+    }
+
+    /**
+     * Sets the value of the internalPrefixOrNsURI property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setInternalPrefixOrNsURI(final String value) {
+        this.internalPrefixOrNsURI = value;
+    }
+
+    /**
+     * Gets the value of the localPart property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLocalPart() {
+        return localPart;
+    }
+
+    /**
+     * Sets the value of the localPart property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLocalPart(final String value) {
+        this.localPart = value;
+    }
+
+    /**
+     * Gets the value of the namespaceURI property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getNamespaceURI() {
+        return namespaceURI;
+    }
+
+    /**
+     * Sets the value of the namespaceURI property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setNamespaceURI(final String value) {
+        this.namespaceURI = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link javax.xml.namespace.QName }
+     */
+    public javax.xml.namespace.QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link javax.xml.namespace.QName }
+     */
+    public void setType(final javax.xml.namespace.QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResAuthEnum.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResAuthEnum.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResAuthEnum.java
index e3353f9..fa37177 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResAuthEnum.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResAuthEnum.java
@@ -1,66 +1,66 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlEnumValue;
-
-/**
- * <p/>
- * Java class for ResAuthTypeBase.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <p/>
- * <pre>
- * &lt;simpleType name="ResAuthTypeBase">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
- *     &lt;enumeration value="Container"/>
- *     &lt;enumeration value="Application"/>
- *     &lt;enumeration value="SERVLET"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlEnum
-public enum ResAuthEnum {
-
-    @XmlEnumValue("Container")
-    CONTAINER("Container"), @XmlEnumValue("Application")
-    APPLICATION("Application"), SERVLET("SERVLET");
-    private final String value;
-
-    ResAuthEnum(final String v) {
-        value = v;
-    }
-
-    public String value() {
-        return value;
-    }
-
-    public static ResAuthEnum fromValue(final String v) {
-        for (final ResAuthEnum c : ResAuthEnum.values()) {
-            if (c.value.equals(v)) {
-                return c;
-            }
-        }
-        throw new IllegalArgumentException(v.toString());
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+
+/**
+ * <p/>
+ * Java class for ResAuthTypeBase.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="ResAuthTypeBase">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
+ *     &lt;enumeration value="Container"/>
+ *     &lt;enumeration value="Application"/>
+ *     &lt;enumeration value="SERVLET"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlEnum
+public enum ResAuthEnum {
+
+    @XmlEnumValue("Container")
+    CONTAINER("Container"), @XmlEnumValue("Application")
+    APPLICATION("Application"), SERVLET("SERVLET");
+    private final String value;
+
+    ResAuthEnum(final String v) {
+        value = v;
+    }
+
+    public String value() {
+        return value;
+    }
+
+    public static ResAuthEnum fromValue(final String v) {
+        for (final ResAuthEnum c : ResAuthEnum.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v.toString());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResSharingScopeEnum.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResSharingScopeEnum.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResSharingScopeEnum.java
index 0a77cbe..3f21846 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResSharingScopeEnum.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResSharingScopeEnum.java
@@ -1,65 +1,65 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlEnumValue;
-
-/**
- * <p/>
- * Java class for ResSharingScopeType.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <p/>
- * <pre>
- * &lt;simpleType name="ResSharingScopeType">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
- *     &lt;enumeration value="Shareable"/>
- *     &lt;enumeration value="Unshareable"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlEnum
-public enum ResSharingScopeEnum {
-
-    @XmlEnumValue("Shareable")
-    SHAREABLE("Shareable"), @XmlEnumValue("Unshareable")
-    UNSHAREABLE("Unshareable");
-    private final String value;
-
-    ResSharingScopeEnum(final String v) {
-        value = v;
-    }
-
-    public String value() {
-        return value;
-    }
-
-    public static ResSharingScopeEnum fromValue(final String v) {
-        for (final ResSharingScopeEnum c : ResSharingScopeEnum.values()) {
-            if (c.value.equals(v)) {
-                return c;
-            }
-        }
-        throw new IllegalArgumentException(v.toString());
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+
+/**
+ * <p/>
+ * Java class for ResSharingScopeType.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="ResSharingScopeType">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
+ *     &lt;enumeration value="Shareable"/>
+ *     &lt;enumeration value="Unshareable"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlEnum
+public enum ResSharingScopeEnum {
+
+    @XmlEnumValue("Shareable")
+    SHAREABLE("Shareable"), @XmlEnumValue("Unshareable")
+    UNSHAREABLE("Unshareable");
+    private final String value;
+
+    ResSharingScopeEnum(final String v) {
+        value = v;
+    }
+
+    public String value() {
+        return value;
+    }
+
+    public static ResSharingScopeEnum fromValue(final String v) {
+        for (final ResSharingScopeEnum c : ResSharingScopeEnum.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v.toString());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceEnvRef.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceEnvRef.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceEnvRef.java
index 42788d2..3df0d06 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceEnvRef.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ResourceEnvRef.java
@@ -1,396 +1,396 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.java.JavaClass;
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The resource-env-refType is used to define resource-env-type elements. It
- * contains a declaration of a Deployment Component's reference to an
- * administered object associated with a resource in the Deployment Component's
- * environment. It consists of an optional description, the resource environment
- * reference name, and an indication of the resource environment reference type
- * expected by the Deployment Component code.
- * <p/>
- * Example:
- * <p/>
- * <p/>
- * <pre>
- * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;resource-env-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;resource-env-ref-name&gt;
- *
- * 						jms/StockQueue
- *
- * 					&lt;/resource-env-ref-name&gt;&lt;resource-env-ref-type&gt;
- *
- * 						javax.jms.Queue
- *
- * 					&lt;/resource-env-ref-type&gt;
- *
- * 				&lt;/resource-env-ref&gt;
- * </pre>
- * <p/>
- * <p/>
- * <p/>
- * <p/>
- * Java class for ResourceEnvRef complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="ResourceEnvRef">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="type" type="{java.xmi}JavaClass"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "ResourceEnvRef", propOrder = {"resourceEnvRefTypes",
-    "descriptions", "extensions"})
-public class ResourceEnvRef {
-
-    @XmlElement(name = "type")
-    protected List<JavaClass> resourceEnvRefTypes;
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute(name = "type")
-    protected String resourceEnvRefTypeString;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the resourceEnvRefTypes property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the resourceEnvRefTypes property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getResourceEnvRefTypes().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JavaClass }
-     */
-    public List<JavaClass> getResourceEnvRefTypes() {
-        if (resourceEnvRefTypes == null) {
-            resourceEnvRefTypes = new ArrayList<JavaClass>();
-        }
-        return this.resourceEnvRefTypes;
-    }
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the resourceEnvRefTypeString property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getResourceEnvRefTypeString() {
-        return resourceEnvRefTypeString;
-    }
-
-    /**
-     * Sets the value of the resourceEnvRefTypeString property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setResourceEnvRefTypeString(final String value) {
-        this.resourceEnvRefTypeString = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.java.JavaClass;
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * The resource-env-refType is used to define resource-env-type elements. It
+ * contains a declaration of a Deployment Component's reference to an
+ * administered object associated with a resource in the Deployment Component's
+ * environment. It consists of an optional description, the resource environment
+ * reference name, and an indication of the resource environment reference type
+ * expected by the Deployment Component code.
+ * <p/>
+ * Example:
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;resource-env-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;resource-env-ref-name&gt;
+ *
+ * 						jms/StockQueue
+ *
+ * 					&lt;/resource-env-ref-name&gt;&lt;resource-env-ref-type&gt;
+ *
+ * 						javax.jms.Queue
+ *
+ * 					&lt;/resource-env-ref-type&gt;
+ *
+ * 				&lt;/resource-env-ref&gt;
+ * </pre>
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for ResourceEnvRef complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="ResourceEnvRef">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="type" type="{java.xmi}JavaClass"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "ResourceEnvRef", propOrder = {"resourceEnvRefTypes",
+    "descriptions", "extensions"})
+public class ResourceEnvRef {
+
+    @XmlElement(name = "type")
+    protected List<JavaClass> resourceEnvRefTypes;
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute(name = "type")
+    protected String resourceEnvRefTypeString;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the resourceEnvRefTypes property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the resourceEnvRefTypes property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getResourceEnvRefTypes().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link JavaClass }
+     */
+    public List<JavaClass> getResourceEnvRefTypes() {
+        if (resourceEnvRefTypes == null) {
+            resourceEnvRefTypes = new ArrayList<JavaClass>();
+        }
+        return this.resourceEnvRefTypes;
+    }
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the resourceEnvRefTypeString property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getResourceEnvRefTypeString() {
+        return resourceEnvRefTypeString;
+    }
+
+    /**
+     * Sets the value of the resourceEnvRefTypeString property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setResourceEnvRefTypeString(final String value) {
+        this.resourceEnvRefTypeString = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}


[16/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/bval/BeanValidationAppendixInterceptor.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/bval/BeanValidationAppendixInterceptor.java b/container/openejb-core/src/main/java/org/apache/openejb/bval/BeanValidationAppendixInterceptor.java
index 9efded1..1395f0d 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/bval/BeanValidationAppendixInterceptor.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/bval/BeanValidationAppendixInterceptor.java
@@ -1,205 +1,205 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.bval;
-
-import org.apache.openejb.core.ThreadContext;
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.util.LogCategory;
-import org.apache.openejb.util.Logger;
-
-import javax.interceptor.AroundInvoke;
-import javax.interceptor.InvocationContext;
-import javax.naming.InitialContext;
-import javax.naming.NamingException;
-import javax.validation.ConstraintViolation;
-import javax.validation.ConstraintViolationException;
-import javax.validation.ValidationException;
-import javax.validation.Validator;
-import java.lang.reflect.Method;
-import java.util.Collections;
-import java.util.Set;
-
-/**
- * A simple interceptor to validate parameters and returned value using
- * bean validation spec. It doesn't use group for now.
- */
-public class BeanValidationAppendixInterceptor {
-    private static final Logger logger = Logger.getInstance(LogCategory.OPENEJB, BeanValidationAppendixInterceptor.class);
-    private static final Class<?> APACHE_BVAL_METHOD_CLASS = initApache();
-    private static final Class<?> HIBERNATE_METHOD_CLASS = initHibernate();
-    public static final Class<?>[] BVAL_ARG_TYPES = new Class<?>[]{
-        Class.class, Method.class, Object[].class, Class[].class
-    };
-    public static final Class<?>[] HIBERNATE_ARG_TYPES = new Class<?>[]{
-        Object.class, Method.class, Object[].class, Class[].class
-    };
-
-    private static final boolean ON;
-
-    static {
-        boolean on = true;
-        try {
-            BeanValidationAppendixInterceptor.class.getClassLoader().loadClass("javax.validation.executable.ExecutableValidator");
-            on = "true".equalsIgnoreCase(SystemInstance.get().getProperty("openejb.bval.10.interceptor.force", "false"));
-            if (!on) {
-                logger.debug(BeanValidationAppendixInterceptor.class.getName() + " deactivated since BVal 1.1 is usable, use openejb.bval.10.interceptor.force=true to force it");
-            }
-        } catch (final Throwable e) {
-            // no-op
-        }
-        ON = on;
-    }
-
-    @AroundInvoke
-    public Object aroundInvoke(final InvocationContext ejbContext) throws Exception {
-        if (!BeanValidationAppendixInterceptor.ON) {
-            return ejbContext.proceed();
-        }
-
-        Object validatorObject = null;
-        Validator validator = null;
-        try {
-            validator = (Validator) new InitialContext().lookup("java:comp/Validator");
-        } catch (final NamingException ne) {
-            // no-op
-        } catch (final Exception e) {
-            logger.warning("BeanValidationAppendixInterceptor unexpected error: " + e);
-            return ejbContext.proceed();
-        }
-
-        final ThreadContext threadContext = ThreadContext.getThreadContext();
-        Class<?> bvalClazzToValidate = ejbContext.getTarget().getClass();
-        if (threadContext != null && ejbContext.getTarget().getClass().getInterfaces().length > 0) {
-            bvalClazzToValidate = threadContext.getInvokedInterface();
-        }
-
-        Method method = ejbContext.getMethod();
-        if (!bvalClazzToValidate.equals(ejbContext.getTarget().getClass())) {
-            method = bvalClazzToValidate.getMethod(method.getName(), method.getParameterTypes());
-        }
-
-        Set<?> violations = Collections.emptySet();
-        if (APACHE_BVAL_METHOD_CLASS != null && validator != null) {
-            validatorObject = validator.unwrap(APACHE_BVAL_METHOD_CLASS);
-            violations = call(Set.class, validatorObject, "validateParameters",
-                new Object[]{
-                    bvalClazzToValidate, method, ejbContext.getParameters(), new Class[0]
-                },
-                BVAL_ARG_TYPES);
-        } else if (HIBERNATE_METHOD_CLASS != null && validator != null) {
-            validatorObject = validator.unwrap(HIBERNATE_METHOD_CLASS);
-            violations = call(Set.class, validatorObject, "validateAllParameters",
-                new Object[]{
-                    ejbContext.getTarget(), ejbContext.getMethod(), ejbContext.getParameters(), new Class[0]
-                },
-                HIBERNATE_ARG_TYPES);
-        } else { // a warning message to inform Apache Bean Validation is not present
-            if (validator == null) {
-                logger.error("can't find validator");
-            } else {
-                logger.warning("Apache Bean Validation is not present, "
-                    + BeanValidationAppendixInterceptor.class.getName() + " will not work. "
-                    + "Please put it if you want to validate your parameters and returned values "
-                    + "with bean validation JSR.");
-            }
-        }
-
-        if (violations.size() > 0) {
-            throw buildValidationException((Set<ConstraintViolation<?>>) violations);
-        }
-
-        final Object returnedValue = ejbContext.proceed();
-
-        violations = Collections.emptySet();
-        if (validatorObject != null && APACHE_BVAL_METHOD_CLASS != null) {
-            violations = call(Set.class, validatorObject, "validateReturnedValue",
-                new Object[]{
-                    bvalClazzToValidate, method, returnedValue, new Class[0]
-                },
-                new Class<?>[]{
-                    Class.class, Method.class, Object.class, Class[].class
-                });
-        } else if (validatorObject != null && HIBERNATE_METHOD_CLASS != null) {
-            violations = call(Set.class, validatorObject, "validateReturnValue",
-                new Object[]{
-                    ejbContext.getTarget(), ejbContext.getMethod(), returnedValue, new Class[0]
-                },
-                new Class<?>[]{
-                    Object.class, Method.class, Object.class, Class[].class
-                });
-        }
-
-        if (violations.size() > 0) {
-            throw buildValidationException((Set<ConstraintViolation<?>>) violations);
-        }
-
-        return returnedValue;
-    }
-
-
-    // just a simple EJBException for now
-    private RuntimeException buildValidationException(final Set<ConstraintViolation<?>> violations) {
-        return new ConstraintViolationException(violations);
-    }
-
-    private static <T> T call(final Class<T> returnedType, final Object o, final String methodName, final Object[] params, final Class<?>[] types) {
-        Method method = null;
-        boolean accessible = true;
-        try {
-            method = o.getClass().getMethod(methodName, types);
-            accessible = method.isAccessible();
-            if (!accessible) {
-                accessible = false;
-                method.setAccessible(true);
-            }
-            return returnedType.cast(method.invoke(o, params));
-        } catch (final Exception e) {
-            e.printStackTrace();
-            throw new ValidationException("can't call method " + methodName + " on " + o, e);
-        } finally {
-            if (method != null) {
-                method.setAccessible(accessible);
-            }
-        }
-    }
-
-    private static ClassLoader getClassLaoder() {
-        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
-        if (classLoader == null) {
-            classLoader = BeanValidationAppendixInterceptor.class.getClassLoader();
-        }
-        return classLoader;
-    }
-
-    private static Class<?> initApache() {
-        try {
-            return getClassLaoder().loadClass("org.apache.bval.jsr303.extensions.MethodValidator");
-        } catch (final ClassNotFoundException e) {
-            return null;
-        }
-    }
-
-    private static Class<?> initHibernate() {
-        try {
-            return getClassLaoder().loadClass("org.hibernate.validator.method.MethodValidator");
-        } catch (final ClassNotFoundException e) {
-            return null;
-        }
-    }
-}
-
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.bval;
+
+import org.apache.openejb.core.ThreadContext;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.util.LogCategory;
+import org.apache.openejb.util.Logger;
+
+import javax.interceptor.AroundInvoke;
+import javax.interceptor.InvocationContext;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import javax.validation.ConstraintViolation;
+import javax.validation.ConstraintViolationException;
+import javax.validation.ValidationException;
+import javax.validation.Validator;
+import java.lang.reflect.Method;
+import java.util.Collections;
+import java.util.Set;
+
+/**
+ * A simple interceptor to validate parameters and returned value using
+ * bean validation spec. It doesn't use group for now.
+ */
+public class BeanValidationAppendixInterceptor {
+    private static final Logger logger = Logger.getInstance(LogCategory.OPENEJB, BeanValidationAppendixInterceptor.class);
+    private static final Class<?> APACHE_BVAL_METHOD_CLASS = initApache();
+    private static final Class<?> HIBERNATE_METHOD_CLASS = initHibernate();
+    public static final Class<?>[] BVAL_ARG_TYPES = new Class<?>[]{
+        Class.class, Method.class, Object[].class, Class[].class
+    };
+    public static final Class<?>[] HIBERNATE_ARG_TYPES = new Class<?>[]{
+        Object.class, Method.class, Object[].class, Class[].class
+    };
+
+    private static final boolean ON;
+
+    static {
+        boolean on = true;
+        try {
+            BeanValidationAppendixInterceptor.class.getClassLoader().loadClass("javax.validation.executable.ExecutableValidator");
+            on = "true".equalsIgnoreCase(SystemInstance.get().getProperty("openejb.bval.10.interceptor.force", "false"));
+            if (!on) {
+                logger.debug(BeanValidationAppendixInterceptor.class.getName() + " deactivated since BVal 1.1 is usable, use openejb.bval.10.interceptor.force=true to force it");
+            }
+        } catch (final Throwable e) {
+            // no-op
+        }
+        ON = on;
+    }
+
+    @AroundInvoke
+    public Object aroundInvoke(final InvocationContext ejbContext) throws Exception {
+        if (!BeanValidationAppendixInterceptor.ON) {
+            return ejbContext.proceed();
+        }
+
+        Object validatorObject = null;
+        Validator validator = null;
+        try {
+            validator = (Validator) new InitialContext().lookup("java:comp/Validator");
+        } catch (final NamingException ne) {
+            // no-op
+        } catch (final Exception e) {
+            logger.warning("BeanValidationAppendixInterceptor unexpected error: " + e);
+            return ejbContext.proceed();
+        }
+
+        final ThreadContext threadContext = ThreadContext.getThreadContext();
+        Class<?> bvalClazzToValidate = ejbContext.getTarget().getClass();
+        if (threadContext != null && ejbContext.getTarget().getClass().getInterfaces().length > 0) {
+            bvalClazzToValidate = threadContext.getInvokedInterface();
+        }
+
+        Method method = ejbContext.getMethod();
+        if (!bvalClazzToValidate.equals(ejbContext.getTarget().getClass())) {
+            method = bvalClazzToValidate.getMethod(method.getName(), method.getParameterTypes());
+        }
+
+        Set<?> violations = Collections.emptySet();
+        if (APACHE_BVAL_METHOD_CLASS != null && validator != null) {
+            validatorObject = validator.unwrap(APACHE_BVAL_METHOD_CLASS);
+            violations = call(Set.class, validatorObject, "validateParameters",
+                new Object[]{
+                    bvalClazzToValidate, method, ejbContext.getParameters(), new Class[0]
+                },
+                BVAL_ARG_TYPES);
+        } else if (HIBERNATE_METHOD_CLASS != null && validator != null) {
+            validatorObject = validator.unwrap(HIBERNATE_METHOD_CLASS);
+            violations = call(Set.class, validatorObject, "validateAllParameters",
+                new Object[]{
+                    ejbContext.getTarget(), ejbContext.getMethod(), ejbContext.getParameters(), new Class[0]
+                },
+                HIBERNATE_ARG_TYPES);
+        } else { // a warning message to inform Apache Bean Validation is not present
+            if (validator == null) {
+                logger.error("can't find validator");
+            } else {
+                logger.warning("Apache Bean Validation is not present, "
+                    + BeanValidationAppendixInterceptor.class.getName() + " will not work. "
+                    + "Please put it if you want to validate your parameters and returned values "
+                    + "with bean validation JSR.");
+            }
+        }
+
+        if (violations.size() > 0) {
+            throw buildValidationException((Set<ConstraintViolation<?>>) violations);
+        }
+
+        final Object returnedValue = ejbContext.proceed();
+
+        violations = Collections.emptySet();
+        if (validatorObject != null && APACHE_BVAL_METHOD_CLASS != null) {
+            violations = call(Set.class, validatorObject, "validateReturnedValue",
+                new Object[]{
+                    bvalClazzToValidate, method, returnedValue, new Class[0]
+                },
+                new Class<?>[]{
+                    Class.class, Method.class, Object.class, Class[].class
+                });
+        } else if (validatorObject != null && HIBERNATE_METHOD_CLASS != null) {
+            violations = call(Set.class, validatorObject, "validateReturnValue",
+                new Object[]{
+                    ejbContext.getTarget(), ejbContext.getMethod(), returnedValue, new Class[0]
+                },
+                new Class<?>[]{
+                    Object.class, Method.class, Object.class, Class[].class
+                });
+        }
+
+        if (violations.size() > 0) {
+            throw buildValidationException((Set<ConstraintViolation<?>>) violations);
+        }
+
+        return returnedValue;
+    }
+
+
+    // just a simple EJBException for now
+    private RuntimeException buildValidationException(final Set<ConstraintViolation<?>> violations) {
+        return new ConstraintViolationException(violations);
+    }
+
+    private static <T> T call(final Class<T> returnedType, final Object o, final String methodName, final Object[] params, final Class<?>[] types) {
+        Method method = null;
+        boolean accessible = true;
+        try {
+            method = o.getClass().getMethod(methodName, types);
+            accessible = method.isAccessible();
+            if (!accessible) {
+                accessible = false;
+                method.setAccessible(true);
+            }
+            return returnedType.cast(method.invoke(o, params));
+        } catch (final Exception e) {
+            e.printStackTrace();
+            throw new ValidationException("can't call method " + methodName + " on " + o, e);
+        } finally {
+            if (method != null) {
+                method.setAccessible(accessible);
+            }
+        }
+    }
+
+    private static ClassLoader getClassLaoder() {
+        ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
+        if (classLoader == null) {
+            classLoader = BeanValidationAppendixInterceptor.class.getClassLoader();
+        }
+        return classLoader;
+    }
+
+    private static Class<?> initApache() {
+        try {
+            return getClassLaoder().loadClass("org.apache.bval.jsr303.extensions.MethodValidator");
+        } catch (final ClassNotFoundException e) {
+            return null;
+        }
+    }
+
+    private static Class<?> initHibernate() {
+        try {
+            return getClassLaoder().loadClass("org.hibernate.validator.method.MethodValidator");
+        } catch (final ClassNotFoundException e) {
+            return null;
+        }
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/cdi/OpenEJBLifecycle.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/cdi/OpenEJBLifecycle.java b/container/openejb-core/src/main/java/org/apache/openejb/cdi/OpenEJBLifecycle.java
index 81195c0..0a945a3 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/cdi/OpenEJBLifecycle.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/cdi/OpenEJBLifecycle.java
@@ -1,419 +1,419 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.cdi;
-
-import org.apache.openejb.AppContext;
-import org.apache.openejb.BeanContext;
-import org.apache.openejb.OpenEJBRuntimeException;
-import org.apache.openejb.assembler.classic.AppInfo;
-import org.apache.openejb.assembler.classic.Assembler;
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.util.LogCategory;
-import org.apache.openejb.util.Logger;
-import org.apache.webbeans.config.BeansDeployer;
-import org.apache.webbeans.config.OpenWebBeansConfiguration;
-import org.apache.webbeans.config.WebBeansContext;
-import org.apache.webbeans.config.WebBeansFinder;
-import org.apache.webbeans.container.BeanManagerImpl;
-import org.apache.webbeans.intercept.InterceptorResolutionService;
-import org.apache.webbeans.portable.AbstractProducer;
-import org.apache.webbeans.portable.InjectionTargetImpl;
-import org.apache.webbeans.portable.events.discovery.BeforeShutdownImpl;
-import org.apache.webbeans.spi.ContainerLifecycle;
-import org.apache.webbeans.spi.ContextsService;
-import org.apache.webbeans.spi.JNDIService;
-import org.apache.webbeans.spi.ResourceInjectionService;
-import org.apache.webbeans.spi.ScannerService;
-import org.apache.webbeans.spi.adaptor.ELAdaptor;
-import org.apache.webbeans.util.WebBeansConstants;
-import org.apache.webbeans.util.WebBeansUtil;
-import org.apache.webbeans.xml.WebBeansXMLConfigurator;
-
-import javax.el.ELResolver;
-import javax.enterprise.inject.spi.BeanManager;
-import javax.servlet.ServletContext;
-import javax.servlet.ServletContextEvent;
-import javax.servlet.jsp.JspApplicationContext;
-import javax.servlet.jsp.JspFactory;
-import java.util.Properties;
-import java.util.concurrent.Executors;
-import java.util.concurrent.ScheduledExecutorService;
-import java.util.concurrent.ThreadFactory;
-import java.util.concurrent.TimeUnit;
-
-/**
- * @version $Rev:$ $Date:$
- */
-public class OpenEJBLifecycle implements ContainerLifecycle {
-    public static final ThreadLocal<AppInfo> CURRENT_APP_INFO = new ThreadLocal<AppInfo>();
-
-    //Logger instance
-    private static final Logger logger = Logger.getInstance(LogCategory.OPENEJB_CDI, OpenEJBLifecycle.class);
-
-    public static final String OPENEJB_CDI_SKIP_CLASS_NOT_FOUND = "openejb.cdi.skip-class-not-found";
-
-    /**
-     * Discover bean classes
-     */
-    protected ScannerService scannerService;
-
-    protected final ContextsService contextsService;
-
-    /**
-     * Deploy discovered beans
-     */
-    private final BeansDeployer deployer;
-
-    /**
-     * XML discovery.
-     */
-    //XML discovery is removed from the specification. It is here for next revisions of spec.
-    private final WebBeansXMLConfigurator xmlDeployer;
-
-    /**
-     * Using for lookup operations
-     */
-    private final JNDIService jndiService;
-
-    /**
-     * Root container.
-     */
-    private final BeanManagerImpl beanManager;
-    private final WebBeansContext webBeansContext;
-    /**
-     * Manages unused conversations
-     */
-    private ScheduledExecutorService service;
-
-    public OpenEJBLifecycle(final WebBeansContext webBeansContext) {
-        this.webBeansContext = webBeansContext;
-        beforeInitApplication(null);
-
-        this.beanManager = webBeansContext.getBeanManagerImpl();
-        this.xmlDeployer = new WebBeansXMLConfigurator();
-        this.deployer = new BeansDeployer(this.xmlDeployer, webBeansContext);
-        this.jndiService = webBeansContext.getService(JNDIService.class);
-        this.beanManager.setXMLConfigurator(this.xmlDeployer);
-        this.scannerService = webBeansContext.getScannerService();
-        this.contextsService = webBeansContext.getContextsService();
-
-        initApplication(null);
-    }
-
-    @Override
-    public BeanManager getBeanManager() {
-        return this.beanManager;
-    }
-
-    @Override
-    public void startApplication(final Object startupObject) {
-        if (ServletContextEvent.class.isInstance( startupObject)) {
-            startServletContext(ServletContext.class.cast(getServletContext(startupObject))); // TODO: check it is relevant
-            return;
-        } else if (!StartupObject.class.isInstance(startupObject)) {
-            logger.debug("startupObject is not of StartupObject type; ignored");
-            return;
-        }
-
-        final StartupObject stuff = (StartupObject) startupObject;
-        final ClassLoader oldCl = Thread.currentThread().getContextClassLoader();
-
-        // Initalize Application Context
-        logger.info("OpenWebBeans Container is starting...");
-
-        final long begin = System.currentTimeMillis();
-
-        try {
-            Thread.currentThread().setContextClassLoader(stuff.getClassLoader());
-
-            //Before Start
-            beforeStartApplication(startupObject);
-
-
-            //Load all plugins
-            webBeansContext.getPluginLoader().startUp();
-
-            //Get Plugin
-            final CdiPlugin cdiPlugin = (CdiPlugin) webBeansContext.getPluginLoader().getEjbPlugin();
-
-            final AppContext appContext = stuff.getAppContext();
-            if (stuff.getWebContext() == null) {
-                appContext.setWebBeansContext(webBeansContext);
-            }
-
-            cdiPlugin.setClassLoader(stuff.getClassLoader());
-            cdiPlugin.setWebBeansContext(webBeansContext);
-            cdiPlugin.startup();
-
-            //Configure EJB Deployments
-            cdiPlugin.configureDeployments(stuff.getBeanContexts());
-
-            //Resournce Injection Service
-            final CdiResourceInjectionService injectionService = (CdiResourceInjectionService) webBeansContext.getService(ResourceInjectionService.class);
-            injectionService.setAppContext(stuff.getAppContext());
-
-            //Deploy the beans
-            try {
-                //Initialize contexts
-                this.contextsService.init(startupObject);
-
-                //Scanning process
-                logger.debug("Scanning classpaths for beans artifacts.");
-
-                if (CdiScanner.class.isInstance(scannerService)) {
-                    final CdiScanner service = CdiScanner.class.cast(scannerService);
-                    service.init(startupObject);
-                } else {
-                    new CdiScanner().init(startupObject);
-                }
-
-                //Scan
-                this.scannerService.scan();
-
-                // just to let us write custom CDI Extension using our internals easily
-                CURRENT_APP_INFO.set(StartupObject.class.cast(startupObject).getAppInfo());
-
-                //Deploy bean from XML. Also configures deployments, interceptors, decorators.
-                deployer.deploy(scannerService);
-            } catch (final Exception e1) {
-                SystemInstance.get().getComponent(Assembler.class).getLogger().error("CDI Beans module deployment failed", e1);
-                throw new OpenEJBRuntimeException(e1);
-            } finally {
-                CURRENT_APP_INFO.remove();
-            }
-
-            for (final BeanContext bc : stuff.getBeanContexts()) {
-                final CdiEjbBean cdiEjbBean = bc.get(CdiEjbBean.class);
-                if (cdiEjbBean == null) {
-                    continue;
-                }
-
-                if (AbstractProducer.class.isInstance(cdiEjbBean)) {
-                    AbstractProducer.class.cast(cdiEjbBean).defineInterceptorStack(cdiEjbBean, cdiEjbBean.getAnnotatedType(), cdiEjbBean.getWebBeansContext());
-                }
-                bc.mergeOWBAndOpenEJBInfo();
-                bc.set(InterceptorResolutionService.BeanInterceptorInfo.class, InjectionTargetImpl.class.cast(cdiEjbBean.getInjectionTarget()).getInterceptorInfo());
-                cdiEjbBean.initInternals();
-            }
-
-            //Start actual starting on sub-classes
-            afterStartApplication(startupObject);
-        } finally {
-            Thread.currentThread().setContextClassLoader(oldCl);
-
-            // cleanup threadlocal used to enrich cdi context manually
-            OptimizedLoaderService.ADDITIONAL_EXTENSIONS.remove();
-            CdiScanner.ADDITIONAL_CLASSES.remove();
-        }
-
-        logger.info("OpenWebBeans Container has started, it took {0} ms.", Long.toString(System.currentTimeMillis() - begin));
-    }
-
-    @Override
-    public void stopApplication(final Object endObject) {
-        logger.debug("OpenWebBeans Container is stopping.");
-
-        try {
-            //Sub-classes operations
-            beforeStopApplication(null);
-
-            //Fire shut down
-            if (WebappBeanManager.class.isInstance(beanManager)) {
-                WebappBeanManager.class.cast(beanManager).beforeStop();
-            }
-            this.beanManager.fireEvent(new BeforeShutdownImpl());
-
-            //Destroys context
-            this.contextsService.destroy(null);
-
-            //Unbind BeanManager
-            if (jndiService != null) {
-                jndiService.unbind(WebBeansConstants.WEB_BEANS_MANAGER_JNDI_NAME);
-            }
-
-            //Free all plugin resources
-            ((CdiPlugin) webBeansContext.getPluginLoader().getEjbPlugin()).clearProxies();
-            webBeansContext.getPluginLoader().shutDown();
-
-            //Clear extensions
-            webBeansContext.getExtensionLoader().clear();
-
-            //Delete Resolutions Cache
-            beanManager.getInjectionResolver().clearCaches();
-
-            //Delete AnnotateTypeCache
-            webBeansContext.getAnnotatedElementFactory().clear();
-
-            //After Stop
-            afterStopApplication(null);
-
-            // Clear BeanManager
-            this.beanManager.clear();
-
-            // Clear singleton list
-            WebBeansFinder.clearInstances(WebBeansUtil.getCurrentClassLoader());
-
-        } catch (final Exception e) {
-            logger.error("An error occured while stopping the container.", e);
-        }
-
-    }
-
-    /**
-     * @return the scannerService
-     */
-    protected ScannerService getScannerService() {
-        return scannerService;
-    }
-
-    /**
-     * @return the contextsService
-     */
-    public ContextsService getContextService() {
-        return contextsService;
-    }
-
-    /**
-     * @return the xmlDeployer
-     */
-    protected WebBeansXMLConfigurator getXmlDeployer() {
-        return xmlDeployer;
-    }
-
-    /**
-     * @return the jndiService
-     */
-    protected JNDIService getJndiService() {
-        return jndiService;
-    }
-
-    @Override
-    public void initApplication(final Properties properties) {
-        afterInitApplication(properties);
-    }
-
-    protected void beforeInitApplication(final Properties properties) {
-        //Do nothing as default
-    }
-
-    protected void afterInitApplication(final Properties properties) {
-        //Do nothing as default
-    }
-
-    protected void afterStartApplication(final Object startupObject) {
-        if (WebappBeanManager.class.isInstance(beanManager)) {
-            WebappBeanManager.class.cast(beanManager).afterStart();
-        }
-    }
-
-    public void startServletContext(final ServletContext servletContext) {
-        service = initializeServletContext(servletContext, webBeansContext);
-    }
-
-    public static ScheduledExecutorService initializeServletContext(final ServletContext servletContext, final WebBeansContext context) {
-        final String strDelay = context.getOpenWebBeansConfiguration().getProperty(OpenWebBeansConfiguration.CONVERSATION_PERIODIC_DELAY, "150000");
-        final long delay = Long.parseLong(strDelay);
-
-        final ScheduledExecutorService executorService = Executors.newScheduledThreadPool(1, new ThreadFactory() {
-            @Override
-            public Thread newThread(final Runnable runable) {
-                final Thread t = new Thread(runable, "OwbConversationCleaner-" + servletContext.getContextPath());
-                t.setDaemon(true);
-                return t;
-            }
-        });
-        executorService.scheduleWithFixedDelay(new ConversationCleaner(context), delay, delay, TimeUnit.MILLISECONDS);
-
-        final ELAdaptor elAdaptor = context.getService(ELAdaptor.class);
-        final ELResolver resolver = elAdaptor.getOwbELResolver();
-        //Application is configured as JSP
-        if (context.getOpenWebBeansConfiguration().isJspApplication()) {
-            logger.debug("Application is configured as JSP. Adding EL Resolver.");
-
-            final JspFactory factory = JspFactory.getDefaultFactory();
-            if (factory != null) {
-                final JspApplicationContext applicationCtx = factory.getJspApplicationContext(servletContext);
-                applicationCtx.addELResolver(resolver);
-            } else {
-                logger.debug("Default JspFactory instance was not found");
-            }
-        }
-
-        // Add BeanManager to the 'javax.enterprise.inject.spi.BeanManager' servlet context attribute
-        servletContext.setAttribute(BeanManager.class.getName(), context.getBeanManagerImpl());
-
-        return executorService;
-    }
-
-    /**
-     * Conversation cleaner thread, that
-     * clears unused conversations.
-     */
-    private static final class ConversationCleaner implements Runnable {
-        private final WebBeansContext webBeansContext;
-
-        private ConversationCleaner(final WebBeansContext webBeansContext) {
-            this.webBeansContext = webBeansContext;
-        }
-
-        public void run() {
-            webBeansContext.getConversationManager().destroyWithRespectToTimout();
-
-        }
-    }
-
-    protected void afterStopApplication(final Object stopObject) throws Exception {
-
-        //Clear the resource injection service
-        final ResourceInjectionService injectionServices = webBeansContext.getService(ResourceInjectionService.class);
-        if (injectionServices != null) {
-            injectionServices.clear();
-        }
-
-        //Comment out for commit OWB-502
-        //ContextFactory.cleanUpContextFactory();
-
-        CdiAppContextsService.class.cast(contextsService).removeThreadLocals();
-
-        WebBeansFinder.clearInstances(WebBeansUtil.getCurrentClassLoader());
-    }
-
-    /**
-     * Returns servlet context otherwise throws exception.
-     *
-     * @param object object
-     * @return servlet context
-     */
-    private Object getServletContext(Object object) {
-        if (ServletContextEvent.class.isInstance(object)) {
-            object = ServletContextEvent.class.cast(object).getServletContext();
-            return object;
-        }
-        return object;
-    }
-
-    protected void beforeStartApplication(final Object startupObject) {
-        //Do nothing as default
-    }
-
-    protected void beforeStopApplication(final Object stopObject) throws Exception {
-        if (service != null) {
-            service.shutdownNow();
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.cdi;
+
+import org.apache.openejb.AppContext;
+import org.apache.openejb.BeanContext;
+import org.apache.openejb.OpenEJBRuntimeException;
+import org.apache.openejb.assembler.classic.AppInfo;
+import org.apache.openejb.assembler.classic.Assembler;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.util.LogCategory;
+import org.apache.openejb.util.Logger;
+import org.apache.webbeans.config.BeansDeployer;
+import org.apache.webbeans.config.OpenWebBeansConfiguration;
+import org.apache.webbeans.config.WebBeansContext;
+import org.apache.webbeans.config.WebBeansFinder;
+import org.apache.webbeans.container.BeanManagerImpl;
+import org.apache.webbeans.intercept.InterceptorResolutionService;
+import org.apache.webbeans.portable.AbstractProducer;
+import org.apache.webbeans.portable.InjectionTargetImpl;
+import org.apache.webbeans.portable.events.discovery.BeforeShutdownImpl;
+import org.apache.webbeans.spi.ContainerLifecycle;
+import org.apache.webbeans.spi.ContextsService;
+import org.apache.webbeans.spi.JNDIService;
+import org.apache.webbeans.spi.ResourceInjectionService;
+import org.apache.webbeans.spi.ScannerService;
+import org.apache.webbeans.spi.adaptor.ELAdaptor;
+import org.apache.webbeans.util.WebBeansConstants;
+import org.apache.webbeans.util.WebBeansUtil;
+import org.apache.webbeans.xml.WebBeansXMLConfigurator;
+
+import javax.el.ELResolver;
+import javax.enterprise.inject.spi.BeanManager;
+import javax.servlet.ServletContext;
+import javax.servlet.ServletContextEvent;
+import javax.servlet.jsp.JspApplicationContext;
+import javax.servlet.jsp.JspFactory;
+import java.util.Properties;
+import java.util.concurrent.Executors;
+import java.util.concurrent.ScheduledExecutorService;
+import java.util.concurrent.ThreadFactory;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * @version $Rev:$ $Date:$
+ */
+public class OpenEJBLifecycle implements ContainerLifecycle {
+    public static final ThreadLocal<AppInfo> CURRENT_APP_INFO = new ThreadLocal<AppInfo>();
+
+    //Logger instance
+    private static final Logger logger = Logger.getInstance(LogCategory.OPENEJB_CDI, OpenEJBLifecycle.class);
+
+    public static final String OPENEJB_CDI_SKIP_CLASS_NOT_FOUND = "openejb.cdi.skip-class-not-found";
+
+    /**
+     * Discover bean classes
+     */
+    protected ScannerService scannerService;
+
+    protected final ContextsService contextsService;
+
+    /**
+     * Deploy discovered beans
+     */
+    private final BeansDeployer deployer;
+
+    /**
+     * XML discovery.
+     */
+    //XML discovery is removed from the specification. It is here for next revisions of spec.
+    private final WebBeansXMLConfigurator xmlDeployer;
+
+    /**
+     * Using for lookup operations
+     */
+    private final JNDIService jndiService;
+
+    /**
+     * Root container.
+     */
+    private final BeanManagerImpl beanManager;
+    private final WebBeansContext webBeansContext;
+    /**
+     * Manages unused conversations
+     */
+    private ScheduledExecutorService service;
+
+    public OpenEJBLifecycle(final WebBeansContext webBeansContext) {
+        this.webBeansContext = webBeansContext;
+        beforeInitApplication(null);
+
+        this.beanManager = webBeansContext.getBeanManagerImpl();
+        this.xmlDeployer = new WebBeansXMLConfigurator();
+        this.deployer = new BeansDeployer(this.xmlDeployer, webBeansContext);
+        this.jndiService = webBeansContext.getService(JNDIService.class);
+        this.beanManager.setXMLConfigurator(this.xmlDeployer);
+        this.scannerService = webBeansContext.getScannerService();
+        this.contextsService = webBeansContext.getContextsService();
+
+        initApplication(null);
+    }
+
+    @Override
+    public BeanManager getBeanManager() {
+        return this.beanManager;
+    }
+
+    @Override
+    public void startApplication(final Object startupObject) {
+        if (ServletContextEvent.class.isInstance( startupObject)) {
+            startServletContext(ServletContext.class.cast(getServletContext(startupObject))); // TODO: check it is relevant
+            return;
+        } else if (!StartupObject.class.isInstance(startupObject)) {
+            logger.debug("startupObject is not of StartupObject type; ignored");
+            return;
+        }
+
+        final StartupObject stuff = (StartupObject) startupObject;
+        final ClassLoader oldCl = Thread.currentThread().getContextClassLoader();
+
+        // Initalize Application Context
+        logger.info("OpenWebBeans Container is starting...");
+
+        final long begin = System.currentTimeMillis();
+
+        try {
+            Thread.currentThread().setContextClassLoader(stuff.getClassLoader());
+
+            //Before Start
+            beforeStartApplication(startupObject);
+
+
+            //Load all plugins
+            webBeansContext.getPluginLoader().startUp();
+
+            //Get Plugin
+            final CdiPlugin cdiPlugin = (CdiPlugin) webBeansContext.getPluginLoader().getEjbPlugin();
+
+            final AppContext appContext = stuff.getAppContext();
+            if (stuff.getWebContext() == null) {
+                appContext.setWebBeansContext(webBeansContext);
+            }
+
+            cdiPlugin.setClassLoader(stuff.getClassLoader());
+            cdiPlugin.setWebBeansContext(webBeansContext);
+            cdiPlugin.startup();
+
+            //Configure EJB Deployments
+            cdiPlugin.configureDeployments(stuff.getBeanContexts());
+
+            //Resournce Injection Service
+            final CdiResourceInjectionService injectionService = (CdiResourceInjectionService) webBeansContext.getService(ResourceInjectionService.class);
+            injectionService.setAppContext(stuff.getAppContext());
+
+            //Deploy the beans
+            try {
+                //Initialize contexts
+                this.contextsService.init(startupObject);
+
+                //Scanning process
+                logger.debug("Scanning classpaths for beans artifacts.");
+
+                if (CdiScanner.class.isInstance(scannerService)) {
+                    final CdiScanner service = CdiScanner.class.cast(scannerService);
+                    service.init(startupObject);
+                } else {
+                    new CdiScanner().init(startupObject);
+                }
+
+                //Scan
+                this.scannerService.scan();
+
+                // just to let us write custom CDI Extension using our internals easily
+                CURRENT_APP_INFO.set(StartupObject.class.cast(startupObject).getAppInfo());
+
+                //Deploy bean from XML. Also configures deployments, interceptors, decorators.
+                deployer.deploy(scannerService);
+            } catch (final Exception e1) {
+                SystemInstance.get().getComponent(Assembler.class).getLogger().error("CDI Beans module deployment failed", e1);
+                throw new OpenEJBRuntimeException(e1);
+            } finally {
+                CURRENT_APP_INFO.remove();
+            }
+
+            for (final BeanContext bc : stuff.getBeanContexts()) {
+                final CdiEjbBean cdiEjbBean = bc.get(CdiEjbBean.class);
+                if (cdiEjbBean == null) {
+                    continue;
+                }
+
+                if (AbstractProducer.class.isInstance(cdiEjbBean)) {
+                    AbstractProducer.class.cast(cdiEjbBean).defineInterceptorStack(cdiEjbBean, cdiEjbBean.getAnnotatedType(), cdiEjbBean.getWebBeansContext());
+                }
+                bc.mergeOWBAndOpenEJBInfo();
+                bc.set(InterceptorResolutionService.BeanInterceptorInfo.class, InjectionTargetImpl.class.cast(cdiEjbBean.getInjectionTarget()).getInterceptorInfo());
+                cdiEjbBean.initInternals();
+            }
+
+            //Start actual starting on sub-classes
+            afterStartApplication(startupObject);
+        } finally {
+            Thread.currentThread().setContextClassLoader(oldCl);
+
+            // cleanup threadlocal used to enrich cdi context manually
+            OptimizedLoaderService.ADDITIONAL_EXTENSIONS.remove();
+            CdiScanner.ADDITIONAL_CLASSES.remove();
+        }
+
+        logger.info("OpenWebBeans Container has started, it took {0} ms.", Long.toString(System.currentTimeMillis() - begin));
+    }
+
+    @Override
+    public void stopApplication(final Object endObject) {
+        logger.debug("OpenWebBeans Container is stopping.");
+
+        try {
+            //Sub-classes operations
+            beforeStopApplication(null);
+
+            //Fire shut down
+            if (WebappBeanManager.class.isInstance(beanManager)) {
+                WebappBeanManager.class.cast(beanManager).beforeStop();
+            }
+            this.beanManager.fireEvent(new BeforeShutdownImpl());
+
+            //Destroys context
+            this.contextsService.destroy(null);
+
+            //Unbind BeanManager
+            if (jndiService != null) {
+                jndiService.unbind(WebBeansConstants.WEB_BEANS_MANAGER_JNDI_NAME);
+            }
+
+            //Free all plugin resources
+            ((CdiPlugin) webBeansContext.getPluginLoader().getEjbPlugin()).clearProxies();
+            webBeansContext.getPluginLoader().shutDown();
+
+            //Clear extensions
+            webBeansContext.getExtensionLoader().clear();
+
+            //Delete Resolutions Cache
+            beanManager.getInjectionResolver().clearCaches();
+
+            //Delete AnnotateTypeCache
+            webBeansContext.getAnnotatedElementFactory().clear();
+
+            //After Stop
+            afterStopApplication(null);
+
+            // Clear BeanManager
+            this.beanManager.clear();
+
+            // Clear singleton list
+            WebBeansFinder.clearInstances(WebBeansUtil.getCurrentClassLoader());
+
+        } catch (final Exception e) {
+            logger.error("An error occured while stopping the container.", e);
+        }
+
+    }
+
+    /**
+     * @return the scannerService
+     */
+    protected ScannerService getScannerService() {
+        return scannerService;
+    }
+
+    /**
+     * @return the contextsService
+     */
+    public ContextsService getContextService() {
+        return contextsService;
+    }
+
+    /**
+     * @return the xmlDeployer
+     */
+    protected WebBeansXMLConfigurator getXmlDeployer() {
+        return xmlDeployer;
+    }
+
+    /**
+     * @return the jndiService
+     */
+    protected JNDIService getJndiService() {
+        return jndiService;
+    }
+
+    @Override
+    public void initApplication(final Properties properties) {
+        afterInitApplication(properties);
+    }
+
+    protected void beforeInitApplication(final Properties properties) {
+        //Do nothing as default
+    }
+
+    protected void afterInitApplication(final Properties properties) {
+        //Do nothing as default
+    }
+
+    protected void afterStartApplication(final Object startupObject) {
+        if (WebappBeanManager.class.isInstance(beanManager)) {
+            WebappBeanManager.class.cast(beanManager).afterStart();
+        }
+    }
+
+    public void startServletContext(final ServletContext servletContext) {
+        service = initializeServletContext(servletContext, webBeansContext);
+    }
+
+    public static ScheduledExecutorService initializeServletContext(final ServletContext servletContext, final WebBeansContext context) {
+        final String strDelay = context.getOpenWebBeansConfiguration().getProperty(OpenWebBeansConfiguration.CONVERSATION_PERIODIC_DELAY, "150000");
+        final long delay = Long.parseLong(strDelay);
+
+        final ScheduledExecutorService executorService = Executors.newScheduledThreadPool(1, new ThreadFactory() {
+            @Override
+            public Thread newThread(final Runnable runable) {
+                final Thread t = new Thread(runable, "OwbConversationCleaner-" + servletContext.getContextPath());
+                t.setDaemon(true);
+                return t;
+            }
+        });
+        executorService.scheduleWithFixedDelay(new ConversationCleaner(context), delay, delay, TimeUnit.MILLISECONDS);
+
+        final ELAdaptor elAdaptor = context.getService(ELAdaptor.class);
+        final ELResolver resolver = elAdaptor.getOwbELResolver();
+        //Application is configured as JSP
+        if (context.getOpenWebBeansConfiguration().isJspApplication()) {
+            logger.debug("Application is configured as JSP. Adding EL Resolver.");
+
+            final JspFactory factory = JspFactory.getDefaultFactory();
+            if (factory != null) {
+                final JspApplicationContext applicationCtx = factory.getJspApplicationContext(servletContext);
+                applicationCtx.addELResolver(resolver);
+            } else {
+                logger.debug("Default JspFactory instance was not found");
+            }
+        }
+
+        // Add BeanManager to the 'javax.enterprise.inject.spi.BeanManager' servlet context attribute
+        servletContext.setAttribute(BeanManager.class.getName(), context.getBeanManagerImpl());
+
+        return executorService;
+    }
+
+    /**
+     * Conversation cleaner thread, that
+     * clears unused conversations.
+     */
+    private static final class ConversationCleaner implements Runnable {
+        private final WebBeansContext webBeansContext;
+
+        private ConversationCleaner(final WebBeansContext webBeansContext) {
+            this.webBeansContext = webBeansContext;
+        }
+
+        public void run() {
+            webBeansContext.getConversationManager().destroyWithRespectToTimout();
+
+        }
+    }
+
+    protected void afterStopApplication(final Object stopObject) throws Exception {
+
+        //Clear the resource injection service
+        final ResourceInjectionService injectionServices = webBeansContext.getService(ResourceInjectionService.class);
+        if (injectionServices != null) {
+            injectionServices.clear();
+        }
+
+        //Comment out for commit OWB-502
+        //ContextFactory.cleanUpContextFactory();
+
+        CdiAppContextsService.class.cast(contextsService).removeThreadLocals();
+
+        WebBeansFinder.clearInstances(WebBeansUtil.getCurrentClassLoader());
+    }
+
+    /**
+     * Returns servlet context otherwise throws exception.
+     *
+     * @param object object
+     * @return servlet context
+     */
+    private Object getServletContext(Object object) {
+        if (ServletContextEvent.class.isInstance(object)) {
+            object = ServletContextEvent.class.cast(object).getServletContext();
+            return object;
+        }
+        return object;
+    }
+
+    protected void beforeStartApplication(final Object startupObject) {
+        //Do nothing as default
+    }
+
+    protected void beforeStopApplication(final Object stopObject) throws Exception {
+        if (service != null) {
+            service.shutdownNow();
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/cipher/PasswordCipher.java
index 52e3fe6..fc657dd 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/cipher/PasswordCipher.java
@@ -1,51 +1,51 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.cipher;
-
-/**
- * Implementations of {@link org.apache.openejb.cipher.PasswordCipher} allow to encode and decode passwords
- * used to connect to a database.
- * <p/>
- * Several implementations may exist, as several encryption algorithms may be
- * supported. One-way encryption algorithm (hash) can't be used as we need to
- * give a plain password to the database. {@link #encrypt(String)} method is not
- * mandatory as we don't need to encode a password, but it's useful to get the
- * encrypted value for a given plain text password. In the case you have
- * implemented both methods, you can use the PasswordCodec command line tool to
- * encode/decode a password.
- */
-public interface PasswordCipher {
-
-    /**
-     * Encodes a given plain text password and returns the encoded password.
-     *
-     * @param plainPassword The password to encode. May not be <code>null</code>, nor empty.
-     * @return The encoded password.
-     */
-    char[] encrypt(String plainPassword);
-
-    /**
-     * Decodes an encoded password and returns a plain text password.
-     *
-     * @param encryptedPassword The ciphered password to decode. May not be <code>null</code>,
-     *                          nor empty.
-     * @return The plain text password.
-     */
-    String decrypt(char[] encryptedPassword);
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.cipher;
+
+/**
+ * Implementations of {@link org.apache.openejb.cipher.PasswordCipher} allow to encode and decode passwords
+ * used to connect to a database.
+ * <p/>
+ * Several implementations may exist, as several encryption algorithms may be
+ * supported. One-way encryption algorithm (hash) can't be used as we need to
+ * give a plain password to the database. {@link #encrypt(String)} method is not
+ * mandatory as we don't need to encode a password, but it's useful to get the
+ * encrypted value for a given plain text password. In the case you have
+ * implemented both methods, you can use the PasswordCodec command line tool to
+ * encode/decode a password.
+ */
+public interface PasswordCipher {
+
+    /**
+     * Encodes a given plain text password and returns the encoded password.
+     *
+     * @param plainPassword The password to encode. May not be <code>null</code>, nor empty.
+     * @return The encoded password.
+     */
+    char[] encrypt(String plainPassword);
+
+    /**
+     * Decodes an encoded password and returns a plain text password.
+     *
+     * @param encryptedPassword The ciphered password to decode. May not be <code>null</code>,
+     *                          nor empty.
+     * @return The plain text password.
+     */
+    String decrypt(char[] encryptedPassword);
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PlainTextPasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PlainTextPasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/cipher/PlainTextPasswordCipher.java
index 4b71dad..099b4ef 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/cipher/PlainTextPasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/cipher/PlainTextPasswordCipher.java
@@ -1,54 +1,54 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.cipher;
-
-/**
- * This {@link org.apache.openejb.cipher.PlainTextPasswordCipher} is an {@link org.apache.openejb.cipher.PasswordCipher}
- * implementation that does not use any encryption/decryption algorithm at all.
- */
-public class PlainTextPasswordCipher implements PasswordCipher {
-
-    /**
-     * Returns the <code>encryptedPassword</code> as plain text string.
-     *
-     * @param encryptedPassword the encoded password
-     * @return String the decoded password
-     * @see org.apache.openejb.cipher.PasswordCipher#decrypt(char[])
-     */
-    public String decrypt(final char[] encryptedPassword) {
-        if (null == encryptedPassword) {
-            throw new IllegalArgumentException("encodedPassword cannot be null.");
-        }
-        return new String(encryptedPassword);
-    }
-
-    /**
-     * Returns the <code>plainPassword</code> as plain text character array.
-     *
-     * @param plainPassword the plain-text password
-     * @return the plain-text password as character array
-     * @see org.apache.openejb.cipher.PasswordCipher#encrypt(String)
-     */
-    public char[] encrypt(final String plainPassword) {
-        if (null == plainPassword) {
-            throw new IllegalArgumentException("plainPassword cannot be null.");
-        }
-        return plainPassword.toCharArray();
-    }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.cipher;
+
+/**
+ * This {@link org.apache.openejb.cipher.PlainTextPasswordCipher} is an {@link org.apache.openejb.cipher.PasswordCipher}
+ * implementation that does not use any encryption/decryption algorithm at all.
+ */
+public class PlainTextPasswordCipher implements PasswordCipher {
+
+    /**
+     * Returns the <code>encryptedPassword</code> as plain text string.
+     *
+     * @param encryptedPassword the encoded password
+     * @return String the decoded password
+     * @see org.apache.openejb.cipher.PasswordCipher#decrypt(char[])
+     */
+    public String decrypt(final char[] encryptedPassword) {
+        if (null == encryptedPassword) {
+            throw new IllegalArgumentException("encodedPassword cannot be null.");
+        }
+        return new String(encryptedPassword);
+    }
+
+    /**
+     * Returns the <code>plainPassword</code> as plain text character array.
+     *
+     * @param plainPassword the plain-text password
+     * @return the plain-text password as character array
+     * @see org.apache.openejb.cipher.PasswordCipher#encrypt(String)
+     */
+    public char[] encrypt(final String plainPassword) {
+        if (null == plainPassword) {
+            throw new IllegalArgumentException("plainPassword cannot be null.");
+        }
+        return plainPassword.toCharArray();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/cipher/StaticDESPasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/cipher/StaticDESPasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/cipher/StaticDESPasswordCipher.java
index f6cd88f..1741e4f 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/cipher/StaticDESPasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/cipher/StaticDESPasswordCipher.java
@@ -1,97 +1,97 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.cipher;
-
-import org.apache.openejb.OpenEJBRuntimeException;
-import org.apache.openejb.util.Base64;
-
-import javax.crypto.Cipher;
-import javax.crypto.spec.SecretKeySpec;
-
-/**
- * This {@link org.apache.openejb.cipher.PasswordCipher} implementation uses a the Triple-DES encryption
- * algorithm.
- */
-public class StaticDESPasswordCipher implements PasswordCipher {
-
-    private static final byte[] _3desData = {
-        (byte) 0x76, (byte) 0x6F, (byte) 0xBA, (byte) 0x39, (byte) 0x31,
-        (byte) 0x2F, (byte) 0x0D, (byte) 0x4A, (byte) 0xA3, (byte) 0x90,
-        (byte) 0x55, (byte) 0xFE, (byte) 0x55, (byte) 0x65, (byte) 0x61,
-        (byte) 0x13, (byte) 0x34, (byte) 0x82, (byte) 0x12, (byte) 0x17,
-        (byte) 0xAC, (byte) 0x77, (byte) 0x39, (byte) 0x19};
-
-    private static final SecretKeySpec KEY = new SecretKeySpec(_3desData, "DESede");
-
-    /**
-     * The name of the transformation defines Triple-DES encryption
-     */
-    private static final String TRANSFORMATION = "DESede";
-
-    /**
-     * @throws RuntimeException in any case of error.
-     * @see org.apache.openejb.cipher.PasswordCipher#encrypt(String)
-     */
-    public char[] encrypt(final String plainPassword) {
-        if (null == plainPassword || plainPassword.length() == 0) {
-            throw new IllegalArgumentException("plainPassword cannot be null nor empty.");
-        }
-
-        final byte[] plaintext = plainPassword.getBytes();
-        try {
-            // Get a 3DES Cipher object
-            final Cipher cipher = Cipher.getInstance(TRANSFORMATION);
-            // Set it into encryption mode
-            cipher.init(Cipher.ENCRYPT_MODE, KEY);
-
-            // Encrypt data
-            final byte[] cipherText = cipher.doFinal(plaintext);
-            return new String(Base64.encodeBase64(cipherText)).toCharArray();
-
-        } catch (final Exception e) {
-            throw new OpenEJBRuntimeException(e);
-        }
-    }
-
-    /**
-     * @throws RuntimeException in any case of error.
-     * @see org.apache.openejb.cipher.PasswordCipher#decrypt(char[])
-     */
-    public String decrypt(final char[] encodedPassword) {
-        if (null == encodedPassword || encodedPassword.length == 0) {
-            throw new IllegalArgumentException("encodedPassword cannot be null nor empty.");
-        }
-
-        try {
-            final byte[] cipherText = Base64.decodeBase64(
-                String.valueOf(encodedPassword).getBytes());
-
-            // Get a 3DES Cipher object
-            final Cipher cipher = Cipher.getInstance(TRANSFORMATION);
-            // Set it into decryption mode
-            cipher.init(Cipher.DECRYPT_MODE, KEY);
-
-            // Decrypt data
-            return new String(cipher.doFinal(cipherText));
-
-        } catch (final Exception e) {
-            throw new OpenEJBRuntimeException(e);
-        }
-    }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.cipher;
+
+import org.apache.openejb.OpenEJBRuntimeException;
+import org.apache.openejb.util.Base64;
+
+import javax.crypto.Cipher;
+import javax.crypto.spec.SecretKeySpec;
+
+/**
+ * This {@link org.apache.openejb.cipher.PasswordCipher} implementation uses a the Triple-DES encryption
+ * algorithm.
+ */
+public class StaticDESPasswordCipher implements PasswordCipher {
+
+    private static final byte[] _3desData = {
+        (byte) 0x76, (byte) 0x6F, (byte) 0xBA, (byte) 0x39, (byte) 0x31,
+        (byte) 0x2F, (byte) 0x0D, (byte) 0x4A, (byte) 0xA3, (byte) 0x90,
+        (byte) 0x55, (byte) 0xFE, (byte) 0x55, (byte) 0x65, (byte) 0x61,
+        (byte) 0x13, (byte) 0x34, (byte) 0x82, (byte) 0x12, (byte) 0x17,
+        (byte) 0xAC, (byte) 0x77, (byte) 0x39, (byte) 0x19};
+
+    private static final SecretKeySpec KEY = new SecretKeySpec(_3desData, "DESede");
+
+    /**
+     * The name of the transformation defines Triple-DES encryption
+     */
+    private static final String TRANSFORMATION = "DESede";
+
+    /**
+     * @throws RuntimeException in any case of error.
+     * @see org.apache.openejb.cipher.PasswordCipher#encrypt(String)
+     */
+    public char[] encrypt(final String plainPassword) {
+        if (null == plainPassword || plainPassword.length() == 0) {
+            throw new IllegalArgumentException("plainPassword cannot be null nor empty.");
+        }
+
+        final byte[] plaintext = plainPassword.getBytes();
+        try {
+            // Get a 3DES Cipher object
+            final Cipher cipher = Cipher.getInstance(TRANSFORMATION);
+            // Set it into encryption mode
+            cipher.init(Cipher.ENCRYPT_MODE, KEY);
+
+            // Encrypt data
+            final byte[] cipherText = cipher.doFinal(plaintext);
+            return new String(Base64.encodeBase64(cipherText)).toCharArray();
+
+        } catch (final Exception e) {
+            throw new OpenEJBRuntimeException(e);
+        }
+    }
+
+    /**
+     * @throws RuntimeException in any case of error.
+     * @see org.apache.openejb.cipher.PasswordCipher#decrypt(char[])
+     */
+    public String decrypt(final char[] encodedPassword) {
+        if (null == encodedPassword || encodedPassword.length == 0) {
+            throw new IllegalArgumentException("encodedPassword cannot be null nor empty.");
+        }
+
+        try {
+            final byte[] cipherText = Base64.decodeBase64(
+                String.valueOf(encodedPassword).getBytes());
+
+            // Get a 3DES Cipher object
+            final Cipher cipher = Cipher.getInstance(TRANSFORMATION);
+            // Set it into decryption mode
+            cipher.init(Cipher.DECRYPT_MODE, KEY);
+
+            // Decrypt data
+            return new String(cipher.doFinal(cipherText));
+
+        } catch (final Exception e) {
+            throw new OpenEJBRuntimeException(e);
+        }
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/classloader/FalseFilter.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/classloader/FalseFilter.java b/container/openejb-core/src/main/java/org/apache/openejb/classloader/FalseFilter.java
index 3378221..3452f19 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/classloader/FalseFilter.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/classloader/FalseFilter.java
@@ -1,29 +1,29 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.classloader;
-
-import org.apache.xbean.finder.filter.Filter;
-
-public class FalseFilter implements Filter {
-    public static final FalseFilter INSTANCE = new FalseFilter();
-
-    @Override
-    public boolean accept(final String name) {
-        return false;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.classloader;
+
+import org.apache.xbean.finder.filter.Filter;
+
+public class FalseFilter implements Filter {
+    public static final FalseFilter INSTANCE = new FalseFilter();
+
+    @Override
+    public boolean accept(final String name) {
+        return false;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/config/DeploymentFilterable.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/DeploymentFilterable.java b/container/openejb-core/src/main/java/org/apache/openejb/config/DeploymentFilterable.java
index ec3365a..f4b9be6 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/DeploymentFilterable.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/DeploymentFilterable.java
@@ -1,33 +1,33 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.config;
-
-/**
- * @version $Rev$
- */
-public interface DeploymentFilterable {
-    String DEPLOYMENTS_CLASSPATH_PROPERTY = "openejb.deployments.classpath";
-    String SEARCH_CLASSPATH_FOR_DEPLOYMENTS_PROPERTY = DEPLOYMENTS_CLASSPATH_PROPERTY;
-    String CLASSPATH_INCLUDE = "openejb.deployments.classpath.include";
-    String CLASSPATH_EXCLUDE = "openejb.deployments.classpath.exclude";
-    String PACKAGE_INCLUDE = "openejb.deployments.package.include";
-    String PACKAGE_EXCLUDE = "openejb.deployments.package.exclude";
-    String CLASSPATH_REQUIRE_DESCRIPTOR = RequireDescriptors.PROPERTY;
-    String CLASSPATH_FILTER_DESCRIPTORS = "openejb.deployments.classpath.filter.descriptors";
-    String CLASSPATH_FILTER_SYSTEMAPPS = "openejb.deployments.classpath.filter.systemapps";
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.config;
+
+/**
+ * @version $Rev$
+ */
+public interface DeploymentFilterable {
+    String DEPLOYMENTS_CLASSPATH_PROPERTY = "openejb.deployments.classpath";
+    String SEARCH_CLASSPATH_FOR_DEPLOYMENTS_PROPERTY = DEPLOYMENTS_CLASSPATH_PROPERTY;
+    String CLASSPATH_INCLUDE = "openejb.deployments.classpath.include";
+    String CLASSPATH_EXCLUDE = "openejb.deployments.classpath.exclude";
+    String PACKAGE_INCLUDE = "openejb.deployments.package.include";
+    String PACKAGE_EXCLUDE = "openejb.deployments.package.exclude";
+    String CLASSPATH_REQUIRE_DESCRIPTOR = RequireDescriptors.PROPERTY;
+    String CLASSPATH_FILTER_DESCRIPTORS = "openejb.deployments.classpath.filter.descriptors";
+    String CLASSPATH_FILTER_SYSTEMAPPS = "openejb.deployments.classpath.filter.systemapps";
+}


[03/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Listener.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Listener.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Listener.java
index 2d00600..ae510c7 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Listener.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Listener.java
@@ -1,111 +1,111 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.java.JavaClass;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlType;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 moved from webapp
- * <p/>
- * Declares a class in the application must be registered as a web
- * application listener bean.
- * <p/>
- * <p/>
- * <p/>
- * Java class for Listener complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="Listener">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element name="listenerClass" type="{java.xmi}JavaClass"/>
- *       &lt;/choice>
- *       &lt;attribute name="listenerClass" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "Listener", propOrder = {"listenerClasses"})
-public class Listener extends CompatibilityDescriptionGroup {
-
-    @XmlElement(name = "listenerClass")
-    protected List<JavaClass> listenerClasses;
-    @XmlAttribute(name = "listenerClass")
-    protected String listenerClassString;
-
-    /**
-     * Gets the value of the listenerClasses property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the listenerClasses property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getListenerClasses().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link JavaClass }
-     */
-    public List<JavaClass> getListenerClasses() {
-        if (listenerClasses == null) {
-            listenerClasses = new ArrayList<JavaClass>();
-        }
-        return this.listenerClasses;
-    }
-
-    /**
-     * Gets the value of the listenerClassString property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getListenerClassString() {
-        return listenerClassString;
-    }
-
-    /**
-     * Sets the value of the listenerClassString property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setListenerClassString(final String value) {
-        this.listenerClassString = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.java.JavaClass;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 moved from webapp
+ * <p/>
+ * Declares a class in the application must be registered as a web
+ * application listener bean.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for Listener complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="Listener">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element name="listenerClass" type="{java.xmi}JavaClass"/>
+ *       &lt;/choice>
+ *       &lt;attribute name="listenerClass" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "Listener", propOrder = {"listenerClasses"})
+public class Listener extends CompatibilityDescriptionGroup {
+
+    @XmlElement(name = "listenerClass")
+    protected List<JavaClass> listenerClasses;
+    @XmlAttribute(name = "listenerClass")
+    protected String listenerClassString;
+
+    /**
+     * Gets the value of the listenerClasses property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the listenerClasses property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getListenerClasses().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link JavaClass }
+     */
+    public List<JavaClass> getListenerClasses() {
+        if (listenerClasses == null) {
+            listenerClasses = new ArrayList<JavaClass>();
+        }
+        return this.listenerClasses;
+    }
+
+    /**
+     * Gets the value of the listenerClassString property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getListenerClassString() {
+        return listenerClassString;
+    }
+
+    /**
+     * Sets the value of the listenerClassString property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setListenerClassString(final String value) {
+        this.listenerClassString = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestination.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestination.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestination.java
index 8f512cb..89efbab 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestination.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestination.java
@@ -1,92 +1,92 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-/**
- * @since J2EE1.4 The message-destinationType specifies a message destination.
- * The logical destination described by this element is mapped to a
- * physical destination by the Deployer.
- * <p/>
- * The message destination element contains:
- * <p/>
- * - an optional description - an optional display-name - an optional
- * icon - a message destination name which must be unique among message
- * destination names within the same Deployment File.
- * <p/>
- * Example:
- * <p/>
- * <p/>
- * <pre>
- * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;message-destination xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;message-destination-name&gt;
- *
- * 						CorporateStocks
- *
- * 					&lt;/message-destination-name&gt;
- *
- * 				&lt;/message-destination&gt;
- * </pre>
- * <p/>
- * <p/>
- * <p/>
- * <p/>
- * Java class for MessageDestination complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="MessageDestination">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "MessageDestination")
-public class MessageDestination extends CompatibilityDescriptionGroup {
-
-    @XmlAttribute
-    protected String name;
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * @since J2EE1.4 The message-destinationType specifies a message destination.
+ * The logical destination described by this element is mapped to a
+ * physical destination by the Deployer.
+ * <p/>
+ * The message destination element contains:
+ * <p/>
+ * - an optional description - an optional display-name - an optional
+ * icon - a message destination name which must be unique among message
+ * destination names within the same Deployment File.
+ * <p/>
+ * Example:
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;message-destination xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;message-destination-name&gt;
+ *
+ * 						CorporateStocks
+ *
+ * 					&lt;/message-destination-name&gt;
+ *
+ * 				&lt;/message-destination&gt;
+ * </pre>
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for MessageDestination complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="MessageDestination">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "MessageDestination")
+public class MessageDestination extends CompatibilityDescriptionGroup {
+
+    @XmlAttribute
+    protected String name;
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationRef.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationRef.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationRef.java
index 28f86d1..b56f4dd 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationRef.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationRef.java
@@ -1,393 +1,393 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 The message-destination-ref element contains a declaration of
- * Deployment Component's reference to a message destination associated
- * with a resource in Deployment Component's environment. It consists of:
- * <p/>
- * - an optional description - the message destination reference name -
- * the message destination type - a specification as to whether the
- * destination is used for consuming or producing messages, or both - a
- * link to the message destination
- * <p/>
- * Examples:
- * <p/>
- * <p/>
- * <pre>
- * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;message-destination-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;message-destination-ref-name&gt;
- *
- * 						jms/StockQueue
- *
- * 					&lt;/message-destination-ref-name&gt;&lt;message-destination-type&gt;
- *
- * 						javax.jms.Queue
- *
- * 					&lt;/message-destination-type&gt;&lt;message-destination-usage&gt;
- *
- * 						Consumes
- *
- * 					&lt;/message-destination-usage&gt;&lt;message-destination-link&gt;
- *
- * 						CorporateStocks
- *
- * 					&lt;/message-destination-link&gt;
- *
- * 				&lt;/message-destination-ref&gt;
- * </pre>
- * <p/>
- * <p/>
- * <p/>
- * <p/>
- * Java class for MessageDestinationRef complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="MessageDestinationRef">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="usage" type="{common.xmi}MessageDestinationUsageType" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "MessageDestinationRef", propOrder = {"descriptions",
-    "extensions"})
-public class MessageDestinationRef {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String link;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute(name = "type")
-    protected String messageDestinationRefTypeString;
-    @XmlAttribute
-    protected MessageDestinationUsageEnum usage;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the link property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLink() {
-        return link;
-    }
-
-    /**
-     * Sets the value of the link property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLink(final String value) {
-        this.link = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the messageDestinationRefTypeString property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getMessageDestinationRefTypeString() {
-        return messageDestinationRefTypeString;
-    }
-
-    /**
-     * Sets the value of the messageDestinationRefTypeString property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setMessageDestinationRefTypeString(final String value) {
-        this.messageDestinationRefTypeString = value;
-    }
-
-    /**
-     * Gets the value of the usage property.
-     *
-     * @return possible object is {@link MessageDestinationUsageEnum }
-     */
-    public MessageDestinationUsageEnum getUsage() {
-        return usage;
-    }
-
-    /**
-     * Sets the value of the usage property.
-     *
-     * @param value allowed object is {@link MessageDestinationUsageEnum }
-     */
-    public void setUsage(final MessageDestinationUsageEnum value) {
-        this.usage = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 The message-destination-ref element contains a declaration of
+ * Deployment Component's reference to a message destination associated
+ * with a resource in Deployment Component's environment. It consists of:
+ * <p/>
+ * - an optional description - the message destination reference name -
+ * the message destination type - a specification as to whether the
+ * destination is used for consuming or producing messages, or both - a
+ * link to the message destination
+ * <p/>
+ * Examples:
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;message-destination-ref xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;&lt;message-destination-ref-name&gt;
+ *
+ * 						jms/StockQueue
+ *
+ * 					&lt;/message-destination-ref-name&gt;&lt;message-destination-type&gt;
+ *
+ * 						javax.jms.Queue
+ *
+ * 					&lt;/message-destination-type&gt;&lt;message-destination-usage&gt;
+ *
+ * 						Consumes
+ *
+ * 					&lt;/message-destination-usage&gt;&lt;message-destination-link&gt;
+ *
+ * 						CorporateStocks
+ *
+ * 					&lt;/message-destination-link&gt;
+ *
+ * 				&lt;/message-destination-ref&gt;
+ * </pre>
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for MessageDestinationRef complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="MessageDestinationRef">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="usage" type="{common.xmi}MessageDestinationUsageType" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "MessageDestinationRef", propOrder = {"descriptions",
+    "extensions"})
+public class MessageDestinationRef {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String link;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute(name = "type")
+    protected String messageDestinationRefTypeString;
+    @XmlAttribute
+    protected MessageDestinationUsageEnum usage;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the link property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLink() {
+        return link;
+    }
+
+    /**
+     * Sets the value of the link property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLink(final String value) {
+        this.link = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the messageDestinationRefTypeString property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getMessageDestinationRefTypeString() {
+        return messageDestinationRefTypeString;
+    }
+
+    /**
+     * Sets the value of the messageDestinationRefTypeString property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setMessageDestinationRefTypeString(final String value) {
+        this.messageDestinationRefTypeString = value;
+    }
+
+    /**
+     * Gets the value of the usage property.
+     *
+     * @return possible object is {@link MessageDestinationUsageEnum }
+     */
+    public MessageDestinationUsageEnum getUsage() {
+        return usage;
+    }
+
+    /**
+     * Sets the value of the usage property.
+     *
+     * @param value allowed object is {@link MessageDestinationUsageEnum }
+     */
+    public void setUsage(final MessageDestinationUsageEnum value) {
+        this.usage = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationUsageEnum.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationUsageEnum.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationUsageEnum.java
index d94e3ab..ac24dc4 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationUsageEnum.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/MessageDestinationUsageEnum.java
@@ -1,68 +1,68 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlEnumValue;
-
-/**
- * <p/>
- * Java class for MessageDestinationUsageType.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <p/>
- * <pre>
- * &lt;simpleType name="MessageDestinationUsageType">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
- *     &lt;enumeration value="Consumes"/>
- *     &lt;enumeration value="Produces"/>
- *     &lt;enumeration value="ConsumesProduces"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlEnum
-public enum MessageDestinationUsageEnum {
-
-    @XmlEnumValue("Consumes")
-    CONSUMES("Consumes"), @XmlEnumValue("Produces")
-    PRODUCES("Produces"), @XmlEnumValue("ConsumesProduces")
-    CONSUMES_PRODUCES("ConsumesProduces");
-    private final String value;
-
-    MessageDestinationUsageEnum(final String v) {
-        value = v;
-    }
-
-    public String value() {
-        return value;
-    }
-
-    public static MessageDestinationUsageEnum fromValue(final String v) {
-        for (final MessageDestinationUsageEnum c : MessageDestinationUsageEnum
-            .values()) {
-            if (c.value.equals(v)) {
-                return c;
-            }
-        }
-        throw new IllegalArgumentException(v.toString());
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+
+/**
+ * <p/>
+ * Java class for MessageDestinationUsageType.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="MessageDestinationUsageType">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
+ *     &lt;enumeration value="Consumes"/>
+ *     &lt;enumeration value="Produces"/>
+ *     &lt;enumeration value="ConsumesProduces"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlEnum
+public enum MessageDestinationUsageEnum {
+
+    @XmlEnumValue("Consumes")
+    CONSUMES("Consumes"), @XmlEnumValue("Produces")
+    PRODUCES("Produces"), @XmlEnumValue("ConsumesProduces")
+    CONSUMES_PRODUCES("ConsumesProduces");
+    private final String value;
+
+    MessageDestinationUsageEnum(final String v) {
+        value = v;
+    }
+
+    public String value() {
+        return value;
+    }
+
+    public static MessageDestinationUsageEnum fromValue(final String v) {
+        for (final MessageDestinationUsageEnum c : MessageDestinationUsageEnum
+            .values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v.toString());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ObjectFactory.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ObjectFactory.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ObjectFactory.java
index 2e0c6b1..fe362b4 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ObjectFactory.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/ObjectFactory.java
@@ -1,475 +1,475 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.JAXBElement;
-import javax.xml.bind.annotation.XmlElementDecl;
-import javax.xml.bind.annotation.XmlRegistry;
-
-/**
- * This object contains factory methods for each Java content interface and Java
- * element interface generated in the org.apache.openejb.jee.was.v6.common
- * package.
- * <p/>
- * An ObjectFactory allows you to programatically construct new instances of the
- * Java representation for XML content. The Java representation of XML content
- * can consist of schema derived interfaces and classes representing the binding
- * of schema type definitions, element declarations and model groups. Factory
- * methods for each of these are provided in this class.
- */
-@XmlRegistry
-public class ObjectFactory {
-
-    private final static javax.xml.namespace.QName _QName_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "QName");
-    private final static javax.xml.namespace.QName _Listener_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "Listener");
-    private final static javax.xml.namespace.QName _SecurityRoleRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "SecurityRoleRef");
-    private final static javax.xml.namespace.QName _Identity_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "Identity");
-    private final static javax.xml.namespace.QName _Description_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "Description");
-    private final static javax.xml.namespace.QName _EnvEntry_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "EnvEntry");
-    private final static javax.xml.namespace.QName _DisplayName_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "DisplayName");
-    private final static javax.xml.namespace.QName _ResourceEnvRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "ResourceEnvRef");
-    private final static javax.xml.namespace.QName _DescriptionGroup_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "DescriptionGroup");
-    private final static javax.xml.namespace.QName _SecurityIdentity_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "SecurityIdentity");
-    private final static javax.xml.namespace.QName _RunAsSpecifiedIdentity_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "RunAsSpecifiedIdentity");
-    private final static javax.xml.namespace.QName _IconType_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "IconType");
-    private final static javax.xml.namespace.QName _UseCallerIdentity_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "UseCallerIdentity");
-    private final static javax.xml.namespace.QName _MessageDestination_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "MessageDestination");
-    private final static javax.xml.namespace.QName _MessageDestinationRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "MessageDestinationRef");
-    private final static javax.xml.namespace.QName _CompatibilityDescriptionGroup_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "CompatibilityDescriptionGroup");
-    private final static javax.xml.namespace.QName _ResourceRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "ResourceRef");
-    private final static javax.xml.namespace.QName _ParamValue_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "ParamValue");
-    private final static javax.xml.namespace.QName _EjbRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "EjbRef");
-    private final static javax.xml.namespace.QName _EJBLocalRef_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "EJBLocalRef");
-    private final static javax.xml.namespace.QName _SecurityRole_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "SecurityRole");
-    private final static javax.xml.namespace.QName _JNDIEnvRefsGroup_QNAME = new javax.xml.namespace.QName(
-        "common.xmi", "JNDIEnvRefsGroup");
-
-    /**
-     * Create a new ObjectFactory that can be used to create new instances of
-     * schema derived classes for package: org.apache.openejb.jee.was.v6.common
-     */
-    public ObjectFactory() {
-    }
-
-    /**
-     * Create an instance of {@link EJBLocalRef }
-     */
-    public EJBLocalRef createEJBLocalRef() {
-        return new EJBLocalRef();
-    }
-
-    /**
-     * Create an instance of {@link SecurityRole }
-     */
-    public SecurityRole createSecurityRole() {
-        return new SecurityRole();
-    }
-
-    /**
-     * Create an instance of {@link ResourceRef }
-     */
-    public ResourceRef createResourceRef() {
-        return new ResourceRef();
-    }
-
-    /**
-     * Create an instance of {@link ResourceEnvRef }
-     */
-    public ResourceEnvRef createResourceEnvRef() {
-        return new ResourceEnvRef();
-    }
-
-    /**
-     * Create an instance of {@link ParamValue }
-     */
-    public ParamValue createParamValue() {
-        return new ParamValue();
-    }
-
-    /**
-     * Create an instance of {@link DisplayName }
-     */
-    public DisplayName createDisplayName() {
-        return new DisplayName();
-    }
-
-    /**
-     * Create an instance of {@link CompatibilityDescriptionGroup }
-     */
-    public CompatibilityDescriptionGroup createCompatibilityDescriptionGroup() {
-        return new CompatibilityDescriptionGroup();
-    }
-
-    /**
-     * Create an instance of {@link Identity }
-     */
-    public Identity createIdentity() {
-        return new Identity();
-    }
-
-    /**
-     * Create an instance of {@link SecurityRoleRef }
-     */
-    public SecurityRoleRef createSecurityRoleRef() {
-        return new SecurityRoleRef();
-    }
-
-    /**
-     * Create an instance of {@link IconType }
-     */
-    public IconType createIconType() {
-        return new IconType();
-    }
-
-    /**
-     * Create an instance of {@link SecurityIdentity }
-     */
-    public SecurityIdentity createSecurityIdentity() {
-        return new SecurityIdentity();
-    }
-
-    /**
-     * Create an instance of {@link UseCallerIdentity }
-     */
-    public UseCallerIdentity createUseCallerIdentity() {
-        return new UseCallerIdentity();
-    }
-
-    /**
-     * Create an instance of {@link MessageDestinationRef }
-     */
-    public MessageDestinationRef createMessageDestinationRef() {
-        return new MessageDestinationRef();
-    }
-
-    /**
-     * Create an instance of {@link org.apache.openejb.jee.was.v6.common.QName }
-     */
-    public org.apache.openejb.jee.was.v6.common.QName createQName() {
-        return new org.apache.openejb.jee.was.v6.common.QName();
-    }
-
-    /**
-     * Create an instance of {@link MessageDestination }
-     */
-    public MessageDestination createMessageDestination() {
-        return new MessageDestination();
-    }
-
-    /**
-     * Create an instance of {@link EjbRef }
-     */
-    public EjbRef createEjbRef() {
-        return new EjbRef();
-    }
-
-    /**
-     * Create an instance of {@link Description }
-     */
-    public Description createDescription() {
-        return new Description();
-    }
-
-    /**
-     * Create an instance of {@link JNDIEnvRefsGroup }
-     */
-    public JNDIEnvRefsGroup createJNDIEnvRefsGroup() {
-        return new JNDIEnvRefsGroup();
-    }
-
-    /**
-     * Create an instance of {@link EnvEntry }
-     */
-    public EnvEntry createEnvEntry() {
-        return new EnvEntry();
-    }
-
-    /**
-     * Create an instance of {@link RunAsSpecifiedIdentity }
-     */
-    public RunAsSpecifiedIdentity createRunAsSpecifiedIdentity() {
-        return new RunAsSpecifiedIdentity();
-    }
-
-    /**
-     * Create an instance of {@link Listener }
-     */
-    public Listener createListener() {
-        return new Listener();
-    }
-
-    /**
-     * Create an instance of {@link DescriptionGroup }
-     */
-    public DescriptionGroup createDescriptionGroup() {
-        return new DescriptionGroup();
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link org.apache.openejb.jee.was.v6.common.QName }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "QName")
-    public JAXBElement<org.apache.openejb.jee.was.v6.common.QName> createQName(
-        final org.apache.openejb.jee.was.v6.common.QName value) {
-        return new JAXBElement<org.apache.openejb.jee.was.v6.common.QName>(
-            _QName_QNAME, org.apache.openejb.jee.was.v6.common.QName.class,
-            null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link Listener }{@code
-     * >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "Listener")
-    public JAXBElement<Listener> createListener(final Listener value) {
-        return new JAXBElement<Listener>(_Listener_QNAME, Listener.class, null,
-            value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link SecurityRoleRef }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "SecurityRoleRef")
-    public JAXBElement<SecurityRoleRef> createSecurityRoleRef(
-        final SecurityRoleRef value) {
-        return new JAXBElement<SecurityRoleRef>(_SecurityRoleRef_QNAME,
-            SecurityRoleRef.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link Identity }{@code
-     * >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "Identity")
-    public JAXBElement<Identity> createIdentity(final Identity value) {
-        return new JAXBElement<Identity>(_Identity_QNAME, Identity.class, null,
-            value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link Description }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "Description")
-    public JAXBElement<Description> createDescription(final Description value) {
-        return new JAXBElement<Description>(_Description_QNAME,
-            Description.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link EnvEntry }{@code
-     * >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "EnvEntry")
-    public JAXBElement<EnvEntry> createEnvEntry(final EnvEntry value) {
-        return new JAXBElement<EnvEntry>(_EnvEntry_QNAME, EnvEntry.class, null,
-            value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link DisplayName }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "DisplayName")
-    public JAXBElement<DisplayName> createDisplayName(final DisplayName value) {
-        return new JAXBElement<DisplayName>(_DisplayName_QNAME,
-            DisplayName.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link ResourceEnvRef }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "ResourceEnvRef")
-    public JAXBElement<ResourceEnvRef> createResourceEnvRef(final ResourceEnvRef value) {
-        return new JAXBElement<ResourceEnvRef>(_ResourceEnvRef_QNAME,
-            ResourceEnvRef.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link DescriptionGroup }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "DescriptionGroup")
-    public JAXBElement<DescriptionGroup> createDescriptionGroup(
-        final DescriptionGroup value) {
-        return new JAXBElement<DescriptionGroup>(_DescriptionGroup_QNAME,
-            DescriptionGroup.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link SecurityIdentity }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "SecurityIdentity")
-    public JAXBElement<SecurityIdentity> createSecurityIdentity(
-        final SecurityIdentity value) {
-        return new JAXBElement<SecurityIdentity>(_SecurityIdentity_QNAME,
-            SecurityIdentity.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link RunAsSpecifiedIdentity }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "RunAsSpecifiedIdentity")
-    public JAXBElement<RunAsSpecifiedIdentity> createRunAsSpecifiedIdentity(
-        final RunAsSpecifiedIdentity value) {
-        return new JAXBElement<RunAsSpecifiedIdentity>(
-            _RunAsSpecifiedIdentity_QNAME, RunAsSpecifiedIdentity.class,
-            null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link IconType }{@code
-     * >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "IconType")
-    public JAXBElement<IconType> createIconType(final IconType value) {
-        return new JAXBElement<IconType>(_IconType_QNAME, IconType.class, null,
-            value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link UseCallerIdentity }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "UseCallerIdentity")
-    public JAXBElement<UseCallerIdentity> createUseCallerIdentity(
-        final UseCallerIdentity value) {
-        return new JAXBElement<UseCallerIdentity>(_UseCallerIdentity_QNAME,
-            UseCallerIdentity.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link MessageDestination }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "MessageDestination")
-    public JAXBElement<MessageDestination> createMessageDestination(
-        final MessageDestination value) {
-        return new JAXBElement<MessageDestination>(_MessageDestination_QNAME,
-            MessageDestination.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link MessageDestinationRef }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "MessageDestinationRef")
-    public JAXBElement<MessageDestinationRef> createMessageDestinationRef(
-        final MessageDestinationRef value) {
-        return new JAXBElement<MessageDestinationRef>(
-            _MessageDestinationRef_QNAME, MessageDestinationRef.class,
-            null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link CompatibilityDescriptionGroup }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "CompatibilityDescriptionGroup")
-    public JAXBElement<CompatibilityDescriptionGroup> createCompatibilityDescriptionGroup(
-        final CompatibilityDescriptionGroup value) {
-        return new JAXBElement<CompatibilityDescriptionGroup>(
-            _CompatibilityDescriptionGroup_QNAME,
-            CompatibilityDescriptionGroup.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link ResourceRef }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "ResourceRef")
-    public JAXBElement<ResourceRef> createResourceRef(final ResourceRef value) {
-        return new JAXBElement<ResourceRef>(_ResourceRef_QNAME,
-            ResourceRef.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link ParamValue }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "ParamValue")
-    public JAXBElement<ParamValue> createParamValue(final ParamValue value) {
-        return new JAXBElement<ParamValue>(_ParamValue_QNAME, ParamValue.class,
-            null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link EjbRef }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "EjbRef")
-    public JAXBElement<EjbRef> createEjbRef(final EjbRef value) {
-        return new JAXBElement<EjbRef>(_EjbRef_QNAME, EjbRef.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link EJBLocalRef }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "EJBLocalRef")
-    public JAXBElement<EJBLocalRef> createEJBLocalRef(final EJBLocalRef value) {
-        return new JAXBElement<EJBLocalRef>(_EJBLocalRef_QNAME,
-            EJBLocalRef.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}{@link SecurityRole }
-     * {@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "SecurityRole")
-    public JAXBElement<SecurityRole> createSecurityRole(final SecurityRole value) {
-        return new JAXBElement<SecurityRole>(_SecurityRole_QNAME,
-            SecurityRole.class, null, value);
-    }
-
-    /**
-     * Create an instance of {@link JAXBElement }{@code <}
-     * {@link JNDIEnvRefsGroup }{@code >}
-     */
-    @XmlElementDecl(namespace = "common.xmi", name = "JNDIEnvRefsGroup")
-    public JAXBElement<JNDIEnvRefsGroup> createJNDIEnvRefsGroup(
-        final JNDIEnvRefsGroup value) {
-        return new JAXBElement<JNDIEnvRefsGroup>(_JNDIEnvRefsGroup_QNAME,
-            JNDIEnvRefsGroup.class, null, value);
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.annotation.XmlElementDecl;
+import javax.xml.bind.annotation.XmlRegistry;
+
+/**
+ * This object contains factory methods for each Java content interface and Java
+ * element interface generated in the org.apache.openejb.jee.was.v6.common
+ * package.
+ * <p/>
+ * An ObjectFactory allows you to programatically construct new instances of the
+ * Java representation for XML content. The Java representation of XML content
+ * can consist of schema derived interfaces and classes representing the binding
+ * of schema type definitions, element declarations and model groups. Factory
+ * methods for each of these are provided in this class.
+ */
+@XmlRegistry
+public class ObjectFactory {
+
+    private final static javax.xml.namespace.QName _QName_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "QName");
+    private final static javax.xml.namespace.QName _Listener_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "Listener");
+    private final static javax.xml.namespace.QName _SecurityRoleRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "SecurityRoleRef");
+    private final static javax.xml.namespace.QName _Identity_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "Identity");
+    private final static javax.xml.namespace.QName _Description_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "Description");
+    private final static javax.xml.namespace.QName _EnvEntry_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "EnvEntry");
+    private final static javax.xml.namespace.QName _DisplayName_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "DisplayName");
+    private final static javax.xml.namespace.QName _ResourceEnvRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "ResourceEnvRef");
+    private final static javax.xml.namespace.QName _DescriptionGroup_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "DescriptionGroup");
+    private final static javax.xml.namespace.QName _SecurityIdentity_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "SecurityIdentity");
+    private final static javax.xml.namespace.QName _RunAsSpecifiedIdentity_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "RunAsSpecifiedIdentity");
+    private final static javax.xml.namespace.QName _IconType_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "IconType");
+    private final static javax.xml.namespace.QName _UseCallerIdentity_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "UseCallerIdentity");
+    private final static javax.xml.namespace.QName _MessageDestination_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "MessageDestination");
+    private final static javax.xml.namespace.QName _MessageDestinationRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "MessageDestinationRef");
+    private final static javax.xml.namespace.QName _CompatibilityDescriptionGroup_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "CompatibilityDescriptionGroup");
+    private final static javax.xml.namespace.QName _ResourceRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "ResourceRef");
+    private final static javax.xml.namespace.QName _ParamValue_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "ParamValue");
+    private final static javax.xml.namespace.QName _EjbRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "EjbRef");
+    private final static javax.xml.namespace.QName _EJBLocalRef_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "EJBLocalRef");
+    private final static javax.xml.namespace.QName _SecurityRole_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "SecurityRole");
+    private final static javax.xml.namespace.QName _JNDIEnvRefsGroup_QNAME = new javax.xml.namespace.QName(
+        "common.xmi", "JNDIEnvRefsGroup");
+
+    /**
+     * Create a new ObjectFactory that can be used to create new instances of
+     * schema derived classes for package: org.apache.openejb.jee.was.v6.common
+     */
+    public ObjectFactory() {
+    }
+
+    /**
+     * Create an instance of {@link EJBLocalRef }
+     */
+    public EJBLocalRef createEJBLocalRef() {
+        return new EJBLocalRef();
+    }
+
+    /**
+     * Create an instance of {@link SecurityRole }
+     */
+    public SecurityRole createSecurityRole() {
+        return new SecurityRole();
+    }
+
+    /**
+     * Create an instance of {@link ResourceRef }
+     */
+    public ResourceRef createResourceRef() {
+        return new ResourceRef();
+    }
+
+    /**
+     * Create an instance of {@link ResourceEnvRef }
+     */
+    public ResourceEnvRef createResourceEnvRef() {
+        return new ResourceEnvRef();
+    }
+
+    /**
+     * Create an instance of {@link ParamValue }
+     */
+    public ParamValue createParamValue() {
+        return new ParamValue();
+    }
+
+    /**
+     * Create an instance of {@link DisplayName }
+     */
+    public DisplayName createDisplayName() {
+        return new DisplayName();
+    }
+
+    /**
+     * Create an instance of {@link CompatibilityDescriptionGroup }
+     */
+    public CompatibilityDescriptionGroup createCompatibilityDescriptionGroup() {
+        return new CompatibilityDescriptionGroup();
+    }
+
+    /**
+     * Create an instance of {@link Identity }
+     */
+    public Identity createIdentity() {
+        return new Identity();
+    }
+
+    /**
+     * Create an instance of {@link SecurityRoleRef }
+     */
+    public SecurityRoleRef createSecurityRoleRef() {
+        return new SecurityRoleRef();
+    }
+
+    /**
+     * Create an instance of {@link IconType }
+     */
+    public IconType createIconType() {
+        return new IconType();
+    }
+
+    /**
+     * Create an instance of {@link SecurityIdentity }
+     */
+    public SecurityIdentity createSecurityIdentity() {
+        return new SecurityIdentity();
+    }
+
+    /**
+     * Create an instance of {@link UseCallerIdentity }
+     */
+    public UseCallerIdentity createUseCallerIdentity() {
+        return new UseCallerIdentity();
+    }
+
+    /**
+     * Create an instance of {@link MessageDestinationRef }
+     */
+    public MessageDestinationRef createMessageDestinationRef() {
+        return new MessageDestinationRef();
+    }
+
+    /**
+     * Create an instance of {@link org.apache.openejb.jee.was.v6.common.QName }
+     */
+    public org.apache.openejb.jee.was.v6.common.QName createQName() {
+        return new org.apache.openejb.jee.was.v6.common.QName();
+    }
+
+    /**
+     * Create an instance of {@link MessageDestination }
+     */
+    public MessageDestination createMessageDestination() {
+        return new MessageDestination();
+    }
+
+    /**
+     * Create an instance of {@link EjbRef }
+     */
+    public EjbRef createEjbRef() {
+        return new EjbRef();
+    }
+
+    /**
+     * Create an instance of {@link Description }
+     */
+    public Description createDescription() {
+        return new Description();
+    }
+
+    /**
+     * Create an instance of {@link JNDIEnvRefsGroup }
+     */
+    public JNDIEnvRefsGroup createJNDIEnvRefsGroup() {
+        return new JNDIEnvRefsGroup();
+    }
+
+    /**
+     * Create an instance of {@link EnvEntry }
+     */
+    public EnvEntry createEnvEntry() {
+        return new EnvEntry();
+    }
+
+    /**
+     * Create an instance of {@link RunAsSpecifiedIdentity }
+     */
+    public RunAsSpecifiedIdentity createRunAsSpecifiedIdentity() {
+        return new RunAsSpecifiedIdentity();
+    }
+
+    /**
+     * Create an instance of {@link Listener }
+     */
+    public Listener createListener() {
+        return new Listener();
+    }
+
+    /**
+     * Create an instance of {@link DescriptionGroup }
+     */
+    public DescriptionGroup createDescriptionGroup() {
+        return new DescriptionGroup();
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link org.apache.openejb.jee.was.v6.common.QName }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "QName")
+    public JAXBElement<org.apache.openejb.jee.was.v6.common.QName> createQName(
+        final org.apache.openejb.jee.was.v6.common.QName value) {
+        return new JAXBElement<org.apache.openejb.jee.was.v6.common.QName>(
+            _QName_QNAME, org.apache.openejb.jee.was.v6.common.QName.class,
+            null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link Listener }{@code
+     * >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "Listener")
+    public JAXBElement<Listener> createListener(final Listener value) {
+        return new JAXBElement<Listener>(_Listener_QNAME, Listener.class, null,
+            value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link SecurityRoleRef }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "SecurityRoleRef")
+    public JAXBElement<SecurityRoleRef> createSecurityRoleRef(
+        final SecurityRoleRef value) {
+        return new JAXBElement<SecurityRoleRef>(_SecurityRoleRef_QNAME,
+            SecurityRoleRef.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link Identity }{@code
+     * >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "Identity")
+    public JAXBElement<Identity> createIdentity(final Identity value) {
+        return new JAXBElement<Identity>(_Identity_QNAME, Identity.class, null,
+            value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link Description }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "Description")
+    public JAXBElement<Description> createDescription(final Description value) {
+        return new JAXBElement<Description>(_Description_QNAME,
+            Description.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link EnvEntry }{@code
+     * >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "EnvEntry")
+    public JAXBElement<EnvEntry> createEnvEntry(final EnvEntry value) {
+        return new JAXBElement<EnvEntry>(_EnvEntry_QNAME, EnvEntry.class, null,
+            value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link DisplayName }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "DisplayName")
+    public JAXBElement<DisplayName> createDisplayName(final DisplayName value) {
+        return new JAXBElement<DisplayName>(_DisplayName_QNAME,
+            DisplayName.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link ResourceEnvRef }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "ResourceEnvRef")
+    public JAXBElement<ResourceEnvRef> createResourceEnvRef(final ResourceEnvRef value) {
+        return new JAXBElement<ResourceEnvRef>(_ResourceEnvRef_QNAME,
+            ResourceEnvRef.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link DescriptionGroup }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "DescriptionGroup")
+    public JAXBElement<DescriptionGroup> createDescriptionGroup(
+        final DescriptionGroup value) {
+        return new JAXBElement<DescriptionGroup>(_DescriptionGroup_QNAME,
+            DescriptionGroup.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link SecurityIdentity }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "SecurityIdentity")
+    public JAXBElement<SecurityIdentity> createSecurityIdentity(
+        final SecurityIdentity value) {
+        return new JAXBElement<SecurityIdentity>(_SecurityIdentity_QNAME,
+            SecurityIdentity.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link RunAsSpecifiedIdentity }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "RunAsSpecifiedIdentity")
+    public JAXBElement<RunAsSpecifiedIdentity> createRunAsSpecifiedIdentity(
+        final RunAsSpecifiedIdentity value) {
+        return new JAXBElement<RunAsSpecifiedIdentity>(
+            _RunAsSpecifiedIdentity_QNAME, RunAsSpecifiedIdentity.class,
+            null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link IconType }{@code
+     * >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "IconType")
+    public JAXBElement<IconType> createIconType(final IconType value) {
+        return new JAXBElement<IconType>(_IconType_QNAME, IconType.class, null,
+            value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link UseCallerIdentity }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "UseCallerIdentity")
+    public JAXBElement<UseCallerIdentity> createUseCallerIdentity(
+        final UseCallerIdentity value) {
+        return new JAXBElement<UseCallerIdentity>(_UseCallerIdentity_QNAME,
+            UseCallerIdentity.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link MessageDestination }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "MessageDestination")
+    public JAXBElement<MessageDestination> createMessageDestination(
+        final MessageDestination value) {
+        return new JAXBElement<MessageDestination>(_MessageDestination_QNAME,
+            MessageDestination.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link MessageDestinationRef }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "MessageDestinationRef")
+    public JAXBElement<MessageDestinationRef> createMessageDestinationRef(
+        final MessageDestinationRef value) {
+        return new JAXBElement<MessageDestinationRef>(
+            _MessageDestinationRef_QNAME, MessageDestinationRef.class,
+            null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link CompatibilityDescriptionGroup }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "CompatibilityDescriptionGroup")
+    public JAXBElement<CompatibilityDescriptionGroup> createCompatibilityDescriptionGroup(
+        final CompatibilityDescriptionGroup value) {
+        return new JAXBElement<CompatibilityDescriptionGroup>(
+            _CompatibilityDescriptionGroup_QNAME,
+            CompatibilityDescriptionGroup.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link ResourceRef }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "ResourceRef")
+    public JAXBElement<ResourceRef> createResourceRef(final ResourceRef value) {
+        return new JAXBElement<ResourceRef>(_ResourceRef_QNAME,
+            ResourceRef.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link ParamValue }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "ParamValue")
+    public JAXBElement<ParamValue> createParamValue(final ParamValue value) {
+        return new JAXBElement<ParamValue>(_ParamValue_QNAME, ParamValue.class,
+            null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link EjbRef }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "EjbRef")
+    public JAXBElement<EjbRef> createEjbRef(final EjbRef value) {
+        return new JAXBElement<EjbRef>(_EjbRef_QNAME, EjbRef.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link EJBLocalRef }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "EJBLocalRef")
+    public JAXBElement<EJBLocalRef> createEJBLocalRef(final EJBLocalRef value) {
+        return new JAXBElement<EJBLocalRef>(_EJBLocalRef_QNAME,
+            EJBLocalRef.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}{@link SecurityRole }
+     * {@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "SecurityRole")
+    public JAXBElement<SecurityRole> createSecurityRole(final SecurityRole value) {
+        return new JAXBElement<SecurityRole>(_SecurityRole_QNAME,
+            SecurityRole.class, null, value);
+    }
+
+    /**
+     * Create an instance of {@link JAXBElement }{@code <}
+     * {@link JNDIEnvRefsGroup }{@code >}
+     */
+    @XmlElementDecl(namespace = "common.xmi", name = "JNDIEnvRefsGroup")
+    public JAXBElement<JNDIEnvRefsGroup> createJNDIEnvRefsGroup(
+        final JNDIEnvRefsGroup value) {
+        return new JAXBElement<JNDIEnvRefsGroup>(_JNDIEnvRefsGroup_QNAME,
+            JNDIEnvRefsGroup.class, null, value);
+    }
+
+}


[04/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntry.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntry.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntry.java
index bc50472..44dfc7b 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntry.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntry.java
@@ -1,364 +1,364 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The env-entryType is used to declare an application's environment entry. The
- * declaration consists of an optional description, the name of the environment
- * entry, and an optional value. If a value is not specified, one must be
- * supplied during deployment.
- * <p/>
- * It is used by env-entry elements.
- * <p/>
- * <p/>
- * <p/>
- * Java class for EnvEntry complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="EnvEntry">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="type" type="{common.xmi}EnvEntryType" />
- *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "EnvEntry", propOrder = {"descriptions", "extensions"})
-public class EnvEntry {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute(name = "type")
-    protected EnvEntryEnum envEntryType;
-    @XmlAttribute
-    protected String value;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the envEntryType property.
-     *
-     * @return possible object is {@link EnvEntryEnum }
-     */
-    public EnvEntryEnum getEnvEntryType() {
-        return envEntryType;
-    }
-
-    /**
-     * Sets the value of the envEntryType property.
-     *
-     * @param value allowed object is {@link EnvEntryEnum }
-     */
-    public void setEnvEntryType(final EnvEntryEnum value) {
-        this.envEntryType = value;
-    }
-
-    /**
-     * Gets the value of the value property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getValue() {
-        return value;
-    }
-
-    /**
-     * Sets the value of the value property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setValue(final String value) {
-        this.value = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * The env-entryType is used to declare an application's environment entry. The
+ * declaration consists of an optional description, the name of the environment
+ * entry, and an optional value. If a value is not specified, one must be
+ * supplied during deployment.
+ * <p/>
+ * It is used by env-entry elements.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for EnvEntry complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="EnvEntry">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="type" type="{common.xmi}EnvEntryType" />
+ *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "EnvEntry", propOrder = {"descriptions", "extensions"})
+public class EnvEntry {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute(name = "type")
+    protected EnvEntryEnum envEntryType;
+    @XmlAttribute
+    protected String value;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the envEntryType property.
+     *
+     * @return possible object is {@link EnvEntryEnum }
+     */
+    public EnvEntryEnum getEnvEntryType() {
+        return envEntryType;
+    }
+
+    /**
+     * Sets the value of the envEntryType property.
+     *
+     * @param value allowed object is {@link EnvEntryEnum }
+     */
+    public void setEnvEntryType(final EnvEntryEnum value) {
+        this.envEntryType = value;
+    }
+
+    /**
+     * Gets the value of the value property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getValue() {
+        return value;
+    }
+
+    /**
+     * Sets the value of the value property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setValue(final String value) {
+        this.value = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntryEnum.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntryEnum.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntryEnum.java
index 77da3dd..714e3be 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntryEnum.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EnvEntryEnum.java
@@ -1,79 +1,79 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlEnumValue;
-
-/**
- * <p/>
- * Java class for EnvEntryType.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <p/>
- * <pre>
- * &lt;simpleType name="EnvEntryType">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
- *     &lt;enumeration value="String"/>
- *     &lt;enumeration value="Integer"/>
- *     &lt;enumeration value="Boolean"/>
- *     &lt;enumeration value="Double"/>
- *     &lt;enumeration value="Byte"/>
- *     &lt;enumeration value="Short"/>
- *     &lt;enumeration value="Long"/>
- *     &lt;enumeration value="Float"/>
- *     &lt;enumeration value="Character"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlEnum
-public enum EnvEntryEnum {
-
-    @XmlEnumValue("String")
-    STRING("String"), @XmlEnumValue("Integer")
-    INTEGER("Integer"), @XmlEnumValue("Boolean")
-    BOOLEAN("Boolean"), @XmlEnumValue("Double")
-    DOUBLE("Double"), @XmlEnumValue("Byte")
-    BYTE("Byte"), @XmlEnumValue("Short")
-    SHORT("Short"), @XmlEnumValue("Long")
-    LONG("Long"), @XmlEnumValue("Float")
-    FLOAT("Float"), @XmlEnumValue("Character")
-    CHARACTER("Character");
-    private final String value;
-
-    EnvEntryEnum(final String v) {
-        value = v;
-    }
-
-    public String value() {
-        return value;
-    }
-
-    public static EnvEntryEnum fromValue(final String v) {
-        for (final EnvEntryEnum c : EnvEntryEnum.values()) {
-            if (c.value.equals(v)) {
-                return c;
-            }
-        }
-        throw new IllegalArgumentException(v.toString());
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+
+/**
+ * <p/>
+ * Java class for EnvEntryType.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="EnvEntryType">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
+ *     &lt;enumeration value="String"/>
+ *     &lt;enumeration value="Integer"/>
+ *     &lt;enumeration value="Boolean"/>
+ *     &lt;enumeration value="Double"/>
+ *     &lt;enumeration value="Byte"/>
+ *     &lt;enumeration value="Short"/>
+ *     &lt;enumeration value="Long"/>
+ *     &lt;enumeration value="Float"/>
+ *     &lt;enumeration value="Character"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlEnum
+public enum EnvEntryEnum {
+
+    @XmlEnumValue("String")
+    STRING("String"), @XmlEnumValue("Integer")
+    INTEGER("Integer"), @XmlEnumValue("Boolean")
+    BOOLEAN("Boolean"), @XmlEnumValue("Double")
+    DOUBLE("Double"), @XmlEnumValue("Byte")
+    BYTE("Byte"), @XmlEnumValue("Short")
+    SHORT("Short"), @XmlEnumValue("Long")
+    LONG("Long"), @XmlEnumValue("Float")
+    FLOAT("Float"), @XmlEnumValue("Character")
+    CHARACTER("Character");
+    private final String value;
+
+    EnvEntryEnum(final String v) {
+        value = v;
+    }
+
+    public String value() {
+        return value;
+    }
+
+    public static EnvEntryEnum fromValue(final String v) {
+        for (final EnvEntryEnum c : EnvEntryEnum.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v.toString());
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/IconType.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/IconType.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/IconType.java
index 12484e5..86479f3 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/IconType.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/IconType.java
@@ -1,309 +1,309 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 The icon type contains small-icon and large-icon elements that
- * specify the file names for small and large GIF or JPEG icon images
- * used to represent the parent element in a GUI tool.
- * <p/>
- * The xml:lang attribute defines the language that the icon file names
- * are provided in. Its value is "en" (English) by default.
- * <p/>
- * <p/>
- * <p/>
- * Java class for IconType complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="IconType">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="largeIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="smallIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "IconType", propOrder = {"extensions"})
-public class IconType {
-
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String lang;
-    @XmlAttribute
-    protected String largeIcon;
-    @XmlAttribute
-    protected String smallIcon;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the lang property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLang() {
-        return lang;
-    }
-
-    /**
-     * Sets the value of the lang property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLang(final String value) {
-        this.lang = value;
-    }
-
-    /**
-     * Gets the value of the largeIcon property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLargeIcon() {
-        return largeIcon;
-    }
-
-    /**
-     * Sets the value of the largeIcon property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLargeIcon(final String value) {
-        this.largeIcon = value;
-    }
-
-    /**
-     * Gets the value of the smallIcon property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getSmallIcon() {
-        return smallIcon;
-    }
-
-    /**
-     * Sets the value of the smallIcon property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setSmallIcon(final String value) {
-        this.smallIcon = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 The icon type contains small-icon and large-icon elements that
+ * specify the file names for small and large GIF or JPEG icon images
+ * used to represent the parent element in a GUI tool.
+ * <p/>
+ * The xml:lang attribute defines the language that the icon file names
+ * are provided in. Its value is "en" (English) by default.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for IconType complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="IconType">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="largeIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="smallIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "IconType", propOrder = {"extensions"})
+public class IconType {
+
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String lang;
+    @XmlAttribute
+    protected String largeIcon;
+    @XmlAttribute
+    protected String smallIcon;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the lang property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLang() {
+        return lang;
+    }
+
+    /**
+     * Sets the value of the lang property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLang(final String value) {
+        this.lang = value;
+    }
+
+    /**
+     * Gets the value of the largeIcon property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLargeIcon() {
+        return largeIcon;
+    }
+
+    /**
+     * Sets the value of the largeIcon property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLargeIcon(final String value) {
+        this.largeIcon = value;
+    }
+
+    /**
+     * Gets the value of the smallIcon property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getSmallIcon() {
+        return smallIcon;
+    }
+
+    /**
+     * Sets the value of the smallIcon property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setSmallIcon(final String value) {
+        this.smallIcon = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Identity.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Identity.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Identity.java
index dc21ee3..bac913b 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Identity.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Identity.java
@@ -1,319 +1,319 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Specifies the run-as identity to be used for the execution of the methods of
- * an enterprise bean. It contains an optional description, and the name of a
- * security role.
- * <p/>
- * <p/>
- * <p/>
- * Java class for Identity complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="Identity">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="roleName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "Identity", propOrder = {"descriptions", "extensions"})
-public class Identity {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String roleName;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the roleName property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getRoleName() {
-        return roleName;
-    }
-
-    /**
-     * Sets the value of the roleName property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setRoleName(final String value) {
-        this.roleName = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Specifies the run-as identity to be used for the execution of the methods of
+ * an enterprise bean. It contains an optional description, and the name of a
+ * security role.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for Identity complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="Identity">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="roleName" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "Identity", propOrder = {"descriptions", "extensions"})
+public class Identity {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String roleName;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the roleName property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getRoleName() {
+        return roleName;
+    }
+
+    /**
+     * Sets the value of the roleName property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setRoleName(final String value) {
+        this.roleName = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/JNDIEnvRefsGroup.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/JNDIEnvRefsGroup.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/JNDIEnvRefsGroup.java
index 8b5f8f8..8d41bf5 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/JNDIEnvRefsGroup.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/JNDIEnvRefsGroup.java
@@ -1,279 +1,279 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.wsclient.ServiceRef;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlType;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 This group keeps the usage of the contained JNDI environment
- * reference elements consistent across J2EE deployment descriptors.
- * <p/>
- * <p/>
- * <p/>
- * Java class for JNDIEnvRefsGroup complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="JNDIEnvRefsGroup">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="environmentProperties" type="{common.xmi}EnvEntry"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="resourceRefs" type="{common.xmi}ResourceRef"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="ejbRefs" type="{common.xmi}EjbRef"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="resourceEnvRefs" type="{common.xmi}ResourceEnvRef"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="ejbLocalRefs" type="{common.xmi}EJBLocalRef"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="messageDestinationRefs" type="{common.xmi}MessageDestinationRef"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="serviceRefs" type="{webservice_client.xmi}ServiceRef"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "JNDIEnvRefsGroup", propOrder = {"environmentProperties",
-    "resourceRefs", "ejbRefs", "resourceEnvRefs", "ejbLocalRefs",
-    "messageDestinationRefs", "serviceRefs"})
-public class JNDIEnvRefsGroup extends CompatibilityDescriptionGroup {
-
-    protected List<EnvEntry> environmentProperties;
-    protected List<ResourceRef> resourceRefs;
-    protected List<EjbRef> ejbRefs;
-    protected List<ResourceEnvRef> resourceEnvRefs;
-    protected List<EJBLocalRef> ejbLocalRefs;
-    protected List<MessageDestinationRef> messageDestinationRefs;
-    protected List<ServiceRef> serviceRefs;
-
-    /**
-     * Gets the value of the environmentProperties property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the environmentProperties property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getEnvironmentProperties().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list {@link EnvEntry }
-     */
-    public List<EnvEntry> getEnvironmentProperties() {
-        if (environmentProperties == null) {
-            environmentProperties = new ArrayList<EnvEntry>();
-        }
-        return this.environmentProperties;
-    }
-
-    /**
-     * Gets the value of the resourceRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the resourceRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getResourceRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link ResourceRef }
-     */
-    public List<ResourceRef> getResourceRefs() {
-        if (resourceRefs == null) {
-            resourceRefs = new ArrayList<ResourceRef>();
-        }
-        return this.resourceRefs;
-    }
-
-    /**
-     * Gets the value of the ejbRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the ejbRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getEjbRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list {@link EjbRef }
-     */
-    public List<EjbRef> getEjbRefs() {
-        if (ejbRefs == null) {
-            ejbRefs = new ArrayList<EjbRef>();
-        }
-        return this.ejbRefs;
-    }
-
-    /**
-     * Gets the value of the resourceEnvRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the resourceEnvRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getResourceEnvRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link ResourceEnvRef }
-     */
-    public List<ResourceEnvRef> getResourceEnvRefs() {
-        if (resourceEnvRefs == null) {
-            resourceEnvRefs = new ArrayList<ResourceEnvRef>();
-        }
-        return this.resourceEnvRefs;
-    }
-
-    /**
-     * Gets the value of the ejbLocalRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the ejbLocalRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getEjbLocalRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link EJBLocalRef }
-     */
-    public List<EJBLocalRef> getEjbLocalRefs() {
-        if (ejbLocalRefs == null) {
-            ejbLocalRefs = new ArrayList<EJBLocalRef>();
-        }
-        return this.ejbLocalRefs;
-    }
-
-    /**
-     * Gets the value of the messageDestinationRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the messageDestinationRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getMessageDestinationRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link MessageDestinationRef }
-     */
-    public List<MessageDestinationRef> getMessageDestinationRefs() {
-        if (messageDestinationRefs == null) {
-            messageDestinationRefs = new ArrayList<MessageDestinationRef>();
-        }
-        return this.messageDestinationRefs;
-    }
-
-    /**
-     * Gets the value of the serviceRefs property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the serviceRefs property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getServiceRefs().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link ServiceRef }
-     */
-    public List<ServiceRef> getServiceRefs() {
-        if (serviceRefs == null) {
-            serviceRefs = new ArrayList<ServiceRef>();
-        }
-        return this.serviceRefs;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.wsclient.ServiceRef;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 This group keeps the usage of the contained JNDI environment
+ * reference elements consistent across J2EE deployment descriptors.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for JNDIEnvRefsGroup complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="JNDIEnvRefsGroup">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}CompatibilityDescriptionGroup">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="environmentProperties" type="{common.xmi}EnvEntry"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="resourceRefs" type="{common.xmi}ResourceRef"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="ejbRefs" type="{common.xmi}EjbRef"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="resourceEnvRefs" type="{common.xmi}ResourceEnvRef"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="ejbLocalRefs" type="{common.xmi}EJBLocalRef"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="messageDestinationRefs" type="{common.xmi}MessageDestinationRef"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="serviceRefs" type="{webservice_client.xmi}ServiceRef"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "JNDIEnvRefsGroup", propOrder = {"environmentProperties",
+    "resourceRefs", "ejbRefs", "resourceEnvRefs", "ejbLocalRefs",
+    "messageDestinationRefs", "serviceRefs"})
+public class JNDIEnvRefsGroup extends CompatibilityDescriptionGroup {
+
+    protected List<EnvEntry> environmentProperties;
+    protected List<ResourceRef> resourceRefs;
+    protected List<EjbRef> ejbRefs;
+    protected List<ResourceEnvRef> resourceEnvRefs;
+    protected List<EJBLocalRef> ejbLocalRefs;
+    protected List<MessageDestinationRef> messageDestinationRefs;
+    protected List<ServiceRef> serviceRefs;
+
+    /**
+     * Gets the value of the environmentProperties property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the environmentProperties property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getEnvironmentProperties().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list {@link EnvEntry }
+     */
+    public List<EnvEntry> getEnvironmentProperties() {
+        if (environmentProperties == null) {
+            environmentProperties = new ArrayList<EnvEntry>();
+        }
+        return this.environmentProperties;
+    }
+
+    /**
+     * Gets the value of the resourceRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the resourceRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getResourceRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link ResourceRef }
+     */
+    public List<ResourceRef> getResourceRefs() {
+        if (resourceRefs == null) {
+            resourceRefs = new ArrayList<ResourceRef>();
+        }
+        return this.resourceRefs;
+    }
+
+    /**
+     * Gets the value of the ejbRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the ejbRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getEjbRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list {@link EjbRef }
+     */
+    public List<EjbRef> getEjbRefs() {
+        if (ejbRefs == null) {
+            ejbRefs = new ArrayList<EjbRef>();
+        }
+        return this.ejbRefs;
+    }
+
+    /**
+     * Gets the value of the resourceEnvRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the resourceEnvRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getResourceEnvRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link ResourceEnvRef }
+     */
+    public List<ResourceEnvRef> getResourceEnvRefs() {
+        if (resourceEnvRefs == null) {
+            resourceEnvRefs = new ArrayList<ResourceEnvRef>();
+        }
+        return this.resourceEnvRefs;
+    }
+
+    /**
+     * Gets the value of the ejbLocalRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the ejbLocalRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getEjbLocalRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link EJBLocalRef }
+     */
+    public List<EJBLocalRef> getEjbLocalRefs() {
+        if (ejbLocalRefs == null) {
+            ejbLocalRefs = new ArrayList<EJBLocalRef>();
+        }
+        return this.ejbLocalRefs;
+    }
+
+    /**
+     * Gets the value of the messageDestinationRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the messageDestinationRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getMessageDestinationRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link MessageDestinationRef }
+     */
+    public List<MessageDestinationRef> getMessageDestinationRefs() {
+        if (messageDestinationRefs == null) {
+            messageDestinationRefs = new ArrayList<MessageDestinationRef>();
+        }
+        return this.messageDestinationRefs;
+    }
+
+    /**
+     * Gets the value of the serviceRefs property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the serviceRefs property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getServiceRefs().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link ServiceRef }
+     */
+    public List<ServiceRef> getServiceRefs() {
+        if (serviceRefs == null) {
+            serviceRefs = new ArrayList<ServiceRef>();
+        }
+        return this.serviceRefs;
+    }
+
+}


[17/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-webapp-remote/src/main/java/org/apache/tomee/arquillian/webapp/TomEEWebappContainer.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-webapp-remote/src/main/java/org/apache/tomee/arquillian/webapp/TomEEWebappContainer.java b/arquillian/arquillian-tomee-webapp-remote/src/main/java/org/apache/tomee/arquillian/webapp/TomEEWebappContainer.java
index 738e375..381be1e 100644
--- a/arquillian/arquillian-tomee-webapp-remote/src/main/java/org/apache/tomee/arquillian/webapp/TomEEWebappContainer.java
+++ b/arquillian/arquillian-tomee-webapp-remote/src/main/java/org/apache/tomee/arquillian/webapp/TomEEWebappContainer.java
@@ -1,247 +1,247 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.tomee.arquillian.webapp;
-
-import org.apache.openejb.arquillian.common.ArquillianFilterRunner;
-import org.apache.openejb.arquillian.common.Files;
-import org.apache.openejb.arquillian.common.IO;
-import org.apache.openejb.arquillian.common.Setup;
-import org.apache.openejb.arquillian.common.TomEEContainer;
-import org.apache.openejb.arquillian.common.Zips;
-import org.apache.openejb.config.RemoteServer;
-import org.apache.tomee.installer.Installer;
-import org.apache.tomee.installer.Paths;
-import org.jboss.arquillian.container.spi.client.container.LifecycleException;
-import org.jboss.arquillian.protocol.servlet.ServletMethodExecutor;
-
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.Arrays;
-import java.util.Map;
-import java.util.TreeMap;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/*
- * TODO: delete old embedded adapter, move the tests and set those up
- */
-public class TomEEWebappContainer extends TomEEContainer<TomEEWebappConfiguration> {
-
-    private static final Logger logger = Logger.getLogger(TomEEWebappContainer.class.getName());
-
-    private RemoteServer container;
-    private boolean shutdown;
-    private File openejbHome;
-    private boolean wereOpenejbHomeSet = true;
-
-    @Override
-    public void start() throws LifecycleException {
-        // see if TomEE is already running by checking the http port
-        final int httpPort = configuration.getHttpPort();
-        if (Setup.isRunning(configuration.getHost(), httpPort)) {
-
-            logger.info(String.format("Tomcat found running on port %s", httpPort));
-
-            return;
-        }
-
-        shutdown = true;
-
-        final String s = File.separator;
-        try {
-            final File workingDirectory = new File(configuration.getDir());
-
-            if (workingDirectory.exists()) {
-
-                Files.assertDir(workingDirectory);
-
-            } else {
-
-                Files.mkdir(workingDirectory);
-                Files.deleteOnExit(workingDirectory);
-            }
-
-            Files.readable(workingDirectory);
-            Files.writable(workingDirectory);
-
-            openejbHome = Setup.findHome(workingDirectory);
-            Installer installer = null;
-
-            if (openejbHome == null) {
-
-                downloadTomcat(workingDirectory, configuration.getTomcatVersion());
-
-                openejbHome = Setup.findHome(workingDirectory);
-
-                Files.deleteOnExit(openejbHome);
-
-                final File webapp = new File(openejbHome, "webapps" + s + "tomee");
-
-                Files.mkdir(webapp);
-                downloadOpenEJBWebapp(webapp);
-
-                System.setProperty("catalina.home", openejbHome.getAbsolutePath());
-                System.setProperty("catalina.base", openejbHome.getAbsolutePath());
-
-                System.setProperty("openejb.deploymentId.format", System.getProperty("openejb.deploymentId.format", "{appId}/{ejbJarId}/{ejbName}"));
-
-                final Paths paths = new Paths(webapp);
-                installer = new Installer(paths, true);
-                if (!configuration.isUseInstallerServlet()) {
-                    installer.installAll();
-
-                }
-
-                wereOpenejbHomeSet = false;
-            }
-
-            Files.assertDir(openejbHome);
-            Files.readable(openejbHome);
-            Files.writable(openejbHome);
-
-            Setup.configureServerXml(openejbHome, configuration);
-            Setup.configureSystemProperties(openejbHome, configuration);
-
-            Setup.exportProperties(openejbHome, configuration, true);
-
-            final URL logging = Thread.currentThread().getContextClassLoader().getResource("default.remote.logging.properties");
-            if (logging != null) {
-                write(logging, new File(openejbHome, "conf" + s + "logging.properties"));
-            }
-
-            if (configuration.isRemoveUnusedWebapps()) {
-                Setup.removeUselessWebapps(openejbHome, "tomee");
-            }
-
-            if (logger.isLoggable(Level.FINE)) {
-                final Map<Object, Object> map = new TreeMap<Object, Object>(System.getProperties());
-                for (final Map.Entry<Object, Object> entry : map.entrySet()) {
-                    System.out.printf("%s = %s\n", entry.getKey(), entry.getValue());
-                }
-            }
-
-            Setup.installArquillianBeanDiscoverer(openejbHome);
-
-            if (!wereOpenejbHomeSet && configuration.isUseInstallerServlet()) {
-                // instead of calling the Installer, let's just do like users do
-                // call the servlet installer instead
-                final String baseUrl = "http://" + configuration.getHost() + ":" + httpPort + "/tomee/installer";
-
-                assert installer != null;
-                installer.addTomEEAdminConfInTomcatUsers(true);
-
-                final RemoteServer tmpContainer = new RemoteServer();
-                tmpContainer.setPortStartup(httpPort);
-                try {
-                    tmpContainer.start();
-                } catch (final Exception e) {
-                    tmpContainer.destroy();
-                    throw e;
-                }
-
-                final URL url = new URL(baseUrl);
-                logger.info("Calling TomEE Installer Servlet on " + url);
-
-                for (int i = 0; i < 3; i++) {
-                    final URLConnection uc = url.openConnection();
-                    // dG9tZWU6dG9tZWU= --> Base64 of tomee:tomee
-                    final String authorizationString = "Basic dG9tZWU6dG9tZWU=";
-                    uc.setRequestProperty("Authorization", authorizationString);
-                    try {
-                        final InputStream is = uc.getInputStream();
-                        org.apache.openejb.loader.IO.slurp(is);
-                        is.close();
-                        break;
-                    } catch (final Exception e) {
-                        logger.warning(e.getMessage());
-                        Thread.sleep(1000);
-                    }
-                }
-
-                tmpContainer.stop();
-                tmpContainer.getServer().waitFor();
-            }
-
-            container = new RemoteServer();
-            container.setPortStartup(httpPort);
-            container.start(Arrays.asList("-Dorg.apache.openejb.servlet.filters=" + ArquillianFilterRunner.class.getName() + "=" + ServletMethodExecutor.ARQUILLIAN_SERVLET_MAPPING), "start", true);
-            container.killOnExit();
-        } catch (final Exception e) {
-            container.destroy();
-            throw new LifecycleException("Unable to start remote container", e);
-        }
-    }
-
-    private static void write(final URL resource, final File file) throws IOException {
-        if (file.exists()) {
-            Files.delete(file);
-        }
-        final InputStream is = org.apache.openejb.loader.IO.read(resource);
-
-        try {
-            IO.copy(is, file);
-        } finally {
-            is.close();
-        }
-    }
-
-    protected void downloadOpenEJBWebapp(final File targetDirectory) throws LifecycleException {
-        final String artifactName = configuration.getArtifactName();
-        final File zipFile = Setup.downloadFile(artifactName, null);
-        Zips.unzip(zipFile, targetDirectory);
-    }
-
-    protected void downloadTomcat(final File catalinaDirectory, final String tomcatVersion) throws LifecycleException {
-        String source = null;
-
-        if (tomcatVersion.startsWith("7.")) {
-            source = "http://archive.apache.org/dist/tomcat/tomcat-7/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
-        }
-
-        if (tomcatVersion.startsWith("6.")) {
-            source = "http://archive.apache.org/dist/tomcat/tomcat-6/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
-        }
-
-        if (tomcatVersion.startsWith("5.5")) {
-            source = "http://archive.apache.org/dist/tomcat/tomcat-5/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
-        }
-
-        if (source == null) {
-            throw new LifecycleException("Unable to find URL for Tomcat " + tomcatVersion);
-        }
-
-        final File zipFile = Setup.downloadFile("org.apache.tomcat:tomcat:" + tomcatVersion + ":zip", source);
-        Zips.unzip(zipFile, catalinaDirectory);
-    }
-
-    @Override
-    public void stop() throws LifecycleException {
-        // only stop the container if we started it
-        if (shutdown) {
-            Setup.removeArquillianBeanDiscoverer(openejbHome);
-            container.destroy();
-        }
-    }
-
-    @Override
-    public Class<TomEEWebappConfiguration> getConfigurationClass() {
-        return TomEEWebappConfiguration.class;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.tomee.arquillian.webapp;
+
+import org.apache.openejb.arquillian.common.ArquillianFilterRunner;
+import org.apache.openejb.arquillian.common.Files;
+import org.apache.openejb.arquillian.common.IO;
+import org.apache.openejb.arquillian.common.Setup;
+import org.apache.openejb.arquillian.common.TomEEContainer;
+import org.apache.openejb.arquillian.common.Zips;
+import org.apache.openejb.config.RemoteServer;
+import org.apache.tomee.installer.Installer;
+import org.apache.tomee.installer.Paths;
+import org.jboss.arquillian.container.spi.client.container.LifecycleException;
+import org.jboss.arquillian.protocol.servlet.ServletMethodExecutor;
+
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URL;
+import java.net.URLConnection;
+import java.util.Arrays;
+import java.util.Map;
+import java.util.TreeMap;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+/*
+ * TODO: delete old embedded adapter, move the tests and set those up
+ */
+public class TomEEWebappContainer extends TomEEContainer<TomEEWebappConfiguration> {
+
+    private static final Logger logger = Logger.getLogger(TomEEWebappContainer.class.getName());
+
+    private RemoteServer container;
+    private boolean shutdown;
+    private File openejbHome;
+    private boolean wereOpenejbHomeSet = true;
+
+    @Override
+    public void start() throws LifecycleException {
+        // see if TomEE is already running by checking the http port
+        final int httpPort = configuration.getHttpPort();
+        if (Setup.isRunning(configuration.getHost(), httpPort)) {
+
+            logger.info(String.format("Tomcat found running on port %s", httpPort));
+
+            return;
+        }
+
+        shutdown = true;
+
+        final String s = File.separator;
+        try {
+            final File workingDirectory = new File(configuration.getDir());
+
+            if (workingDirectory.exists()) {
+
+                Files.assertDir(workingDirectory);
+
+            } else {
+
+                Files.mkdir(workingDirectory);
+                Files.deleteOnExit(workingDirectory);
+            }
+
+            Files.readable(workingDirectory);
+            Files.writable(workingDirectory);
+
+            openejbHome = Setup.findHome(workingDirectory);
+            Installer installer = null;
+
+            if (openejbHome == null) {
+
+                downloadTomcat(workingDirectory, configuration.getTomcatVersion());
+
+                openejbHome = Setup.findHome(workingDirectory);
+
+                Files.deleteOnExit(openejbHome);
+
+                final File webapp = new File(openejbHome, "webapps" + s + "tomee");
+
+                Files.mkdir(webapp);
+                downloadOpenEJBWebapp(webapp);
+
+                System.setProperty("catalina.home", openejbHome.getAbsolutePath());
+                System.setProperty("catalina.base", openejbHome.getAbsolutePath());
+
+                System.setProperty("openejb.deploymentId.format", System.getProperty("openejb.deploymentId.format", "{appId}/{ejbJarId}/{ejbName}"));
+
+                final Paths paths = new Paths(webapp);
+                installer = new Installer(paths, true);
+                if (!configuration.isUseInstallerServlet()) {
+                    installer.installAll();
+
+                }
+
+                wereOpenejbHomeSet = false;
+            }
+
+            Files.assertDir(openejbHome);
+            Files.readable(openejbHome);
+            Files.writable(openejbHome);
+
+            Setup.configureServerXml(openejbHome, configuration);
+            Setup.configureSystemProperties(openejbHome, configuration);
+
+            Setup.exportProperties(openejbHome, configuration, true);
+
+            final URL logging = Thread.currentThread().getContextClassLoader().getResource("default.remote.logging.properties");
+            if (logging != null) {
+                write(logging, new File(openejbHome, "conf" + s + "logging.properties"));
+            }
+
+            if (configuration.isRemoveUnusedWebapps()) {
+                Setup.removeUselessWebapps(openejbHome, "tomee");
+            }
+
+            if (logger.isLoggable(Level.FINE)) {
+                final Map<Object, Object> map = new TreeMap<Object, Object>(System.getProperties());
+                for (final Map.Entry<Object, Object> entry : map.entrySet()) {
+                    System.out.printf("%s = %s\n", entry.getKey(), entry.getValue());
+                }
+            }
+
+            Setup.installArquillianBeanDiscoverer(openejbHome);
+
+            if (!wereOpenejbHomeSet && configuration.isUseInstallerServlet()) {
+                // instead of calling the Installer, let's just do like users do
+                // call the servlet installer instead
+                final String baseUrl = "http://" + configuration.getHost() + ":" + httpPort + "/tomee/installer";
+
+                assert installer != null;
+                installer.addTomEEAdminConfInTomcatUsers(true);
+
+                final RemoteServer tmpContainer = new RemoteServer();
+                tmpContainer.setPortStartup(httpPort);
+                try {
+                    tmpContainer.start();
+                } catch (final Exception e) {
+                    tmpContainer.destroy();
+                    throw e;
+                }
+
+                final URL url = new URL(baseUrl);
+                logger.info("Calling TomEE Installer Servlet on " + url);
+
+                for (int i = 0; i < 3; i++) {
+                    final URLConnection uc = url.openConnection();
+                    // dG9tZWU6dG9tZWU= --> Base64 of tomee:tomee
+                    final String authorizationString = "Basic dG9tZWU6dG9tZWU=";
+                    uc.setRequestProperty("Authorization", authorizationString);
+                    try {
+                        final InputStream is = uc.getInputStream();
+                        org.apache.openejb.loader.IO.slurp(is);
+                        is.close();
+                        break;
+                    } catch (final Exception e) {
+                        logger.warning(e.getMessage());
+                        Thread.sleep(1000);
+                    }
+                }
+
+                tmpContainer.stop();
+                tmpContainer.getServer().waitFor();
+            }
+
+            container = new RemoteServer();
+            container.setPortStartup(httpPort);
+            container.start(Arrays.asList("-Dorg.apache.openejb.servlet.filters=" + ArquillianFilterRunner.class.getName() + "=" + ServletMethodExecutor.ARQUILLIAN_SERVLET_MAPPING), "start", true);
+            container.killOnExit();
+        } catch (final Exception e) {
+            container.destroy();
+            throw new LifecycleException("Unable to start remote container", e);
+        }
+    }
+
+    private static void write(final URL resource, final File file) throws IOException {
+        if (file.exists()) {
+            Files.delete(file);
+        }
+        final InputStream is = org.apache.openejb.loader.IO.read(resource);
+
+        try {
+            IO.copy(is, file);
+        } finally {
+            is.close();
+        }
+    }
+
+    protected void downloadOpenEJBWebapp(final File targetDirectory) throws LifecycleException {
+        final String artifactName = configuration.getArtifactName();
+        final File zipFile = Setup.downloadFile(artifactName, null);
+        Zips.unzip(zipFile, targetDirectory);
+    }
+
+    protected void downloadTomcat(final File catalinaDirectory, final String tomcatVersion) throws LifecycleException {
+        String source = null;
+
+        if (tomcatVersion.startsWith("7.")) {
+            source = "http://archive.apache.org/dist/tomcat/tomcat-7/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
+        }
+
+        if (tomcatVersion.startsWith("6.")) {
+            source = "http://archive.apache.org/dist/tomcat/tomcat-6/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
+        }
+
+        if (tomcatVersion.startsWith("5.5")) {
+            source = "http://archive.apache.org/dist/tomcat/tomcat-5/v" + tomcatVersion + "/bin/apache-tomcat-" + tomcatVersion + ".zip";
+        }
+
+        if (source == null) {
+            throw new LifecycleException("Unable to find URL for Tomcat " + tomcatVersion);
+        }
+
+        final File zipFile = Setup.downloadFile("org.apache.tomcat:tomcat:" + tomcatVersion + ":zip", source);
+        Zips.unzip(zipFile, catalinaDirectory);
+    }
+
+    @Override
+    public void stop() throws LifecycleException {
+        // only stop the container if we started it
+        if (shutdown) {
+            Setup.removeArquillianBeanDiscoverer(openejbHome);
+            container.destroy();
+        }
+    }
+
+    @Override
+    public Class<TomEEWebappConfiguration> getConfigurationClass() {
+        return TomEEWebappConfiguration.class;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/README.html
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/README.html b/assembly/openejb-standalone/README.html
index aaeb6a5..04f4504 100644
--- a/assembly/openejb-standalone/README.html
+++ b/assembly/openejb-standalone/README.html
@@ -1,24 +1,24 @@
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
-
--->
-
-<!-- $Rev$ $Date$ -->
-
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
 <HTML><HEAD><TITLE>Apache OpenEJB 6.0.14</TITLE>
 <META http-equiv=Content-Type content="text/html">

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/assembly/component.xml
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/assembly/component.xml b/assembly/openejb-standalone/src/main/assembly/component.xml
index 81e9b5c..9687511 100644
--- a/assembly/openejb-standalone/src/main/assembly/component.xml
+++ b/assembly/openejb-standalone/src/main/assembly/component.xml
@@ -1,22 +1,22 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one
-    or more contributor license agreements.  See the NOTICE file
-    distributed with this work for additional information
-    regarding copyright ownership.  The ASF licenses this file
-    to you under the Apache License, Version 2.0 (the
-    "License"); you may not use this file except in compliance
-    with the License.  You may obtain a copy of the License at
-
-    http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing,
-    software distributed under the License is distributed on an
-    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-    KIND, either express or implied.  See the License for the
-    specific language governing permissions and limitations
-    under the License.
--->
-<component>
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License.
+-->
+<component>
+
 </component>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/assembly/dos.xml
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/assembly/dos.xml b/assembly/openejb-standalone/src/main/assembly/dos.xml
index b2b5e46..538e924 100644
--- a/assembly/openejb-standalone/src/main/assembly/dos.xml
+++ b/assembly/openejb-standalone/src/main/assembly/dos.xml
@@ -1,125 +1,125 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev: 1482826 $ $Date: 2013-05-15 15:31:58 +0200 (Wed, 15 May 2013) $ -->
-
-<assembly>
-  <id>bin-dos</id>
-  <formats>
-    <format>zip</format>
-  </formats>
-  <fileSets>
-    <fileSet>
-      <lineEnding>dos</lineEnding>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>/</outputDirectory>
-      <includes>
-        <include>README.txt</include>
-        <include>NOTICE</include>
-        <include>LICENSE</include>
-      </includes>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>*.bat</include>
-        <include>service.readme.txt</include>
-      </includes>
-      <lineEnding>dos</lineEnding>
-      <fileMode>0755</fileMode>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>openejb</include>
-      </includes>
-      <lineEnding>unix</lineEnding>
-      <fileMode>0755</fileMode>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/src/main/resources</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>*.exe</include>
-      </includes>
-    </fileSet>
-    <fileSet>
-      <lineEnding>dos</lineEnding>
-      <directory>${basedir}/src/main/conf</directory>
-      <includes>
-        <include>README.txt</include>
-        <include>logging.properties</include>
-        <include>system.properties</include>
-      </includes>
-      <outputDirectory>conf/</outputDirectory>
-    </fileSet>
-    <fileSet>
-      <lineEnding>dos</lineEnding>
-      <outputDirectory>logs/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-    <fileSet>
-      <lineEnding>dos</lineEnding>
-      <outputDirectory>apps/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-    <fileSet>
-      <outputDirectory>data/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-  </fileSets>
-  <files>
-    <file>
-      <lineEnding>dos</lineEnding>
-      <source>${basedir}/target/classes/DATA-README.txt</source>
-      <outputDirectory>data/</outputDirectory>
-      <destName>README.txt</destName>
-      <fileMode>0755</fileMode>
-    </file>
-  </files>
-  <dependencySets>
-    <dependencySet>
-      <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
-      </outputFileNameMapping>
-      <outputDirectory>lib</outputDirectory>
-      <scope>runtime</scope>
-      <excludes>
-        <exclude>junit:junit</exclude>
-      </excludes>
-    </dependencySet>
-  </dependencySets>
-</assembly>
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev: 1482826 $ $Date: 2013-05-15 15:31:58 +0200 (Wed, 15 May 2013) $ -->
+
+<assembly>
+  <id>bin-dos</id>
+  <formats>
+    <format>zip</format>
+  </formats>
+  <fileSets>
+    <fileSet>
+      <lineEnding>dos</lineEnding>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>/</outputDirectory>
+      <includes>
+        <include>README.txt</include>
+        <include>NOTICE</include>
+        <include>LICENSE</include>
+      </includes>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>*.bat</include>
+        <include>service.readme.txt</include>
+      </includes>
+      <lineEnding>dos</lineEnding>
+      <fileMode>0755</fileMode>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>openejb</include>
+      </includes>
+      <lineEnding>unix</lineEnding>
+      <fileMode>0755</fileMode>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/src/main/resources</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>*.exe</include>
+      </includes>
+    </fileSet>
+    <fileSet>
+      <lineEnding>dos</lineEnding>
+      <directory>${basedir}/src/main/conf</directory>
+      <includes>
+        <include>README.txt</include>
+        <include>logging.properties</include>
+        <include>system.properties</include>
+      </includes>
+      <outputDirectory>conf/</outputDirectory>
+    </fileSet>
+    <fileSet>
+      <lineEnding>dos</lineEnding>
+      <outputDirectory>logs/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+    <fileSet>
+      <lineEnding>dos</lineEnding>
+      <outputDirectory>apps/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+    <fileSet>
+      <outputDirectory>data/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+  </fileSets>
+  <files>
+    <file>
+      <lineEnding>dos</lineEnding>
+      <source>${basedir}/target/classes/DATA-README.txt</source>
+      <outputDirectory>data/</outputDirectory>
+      <destName>README.txt</destName>
+      <fileMode>0755</fileMode>
+    </file>
+  </files>
+  <dependencySets>
+    <dependencySet>
+      <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
+      </outputFileNameMapping>
+      <outputDirectory>lib</outputDirectory>
+      <scope>runtime</scope>
+      <excludes>
+        <exclude>junit:junit</exclude>
+      </excludes>
+    </dependencySet>
+  </dependencySets>
+</assembly>
+

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/assembly/unix.xml
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/assembly/unix.xml b/assembly/openejb-standalone/src/main/assembly/unix.xml
index 8830f5a..77ab54c 100644
--- a/assembly/openejb-standalone/src/main/assembly/unix.xml
+++ b/assembly/openejb-standalone/src/main/assembly/unix.xml
@@ -1,124 +1,124 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev: 1482826 $ $Date: 2013-05-15 15:31:58 +0200 (Wed, 15 May 2013) $ -->
-
-<assembly>
-  <id>bin-unix</id>
-  <formats>
-    <format>tar.gz</format>
-  </formats>
-  <fileSets>
-    <fileSet>
-      <lineEnding>unix</lineEnding>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>/</outputDirectory>
-      <includes>
-        <include>README.txt</include>
-        <include>NOTICE</include>
-        <include>LICENSE</include>
-      </includes>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>*.bat</include>
-        <include>service.readme.txt</include>
-      </includes>
-      <lineEnding>dos</lineEnding>
-      <fileMode>0755</fileMode>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/target/classes</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>openejb</include>
-      </includes>
-      <lineEnding>unix</lineEnding>
-      <fileMode>0755</fileMode>
-    </fileSet>
-    <fileSet>
-      <directory>${basedir}/src/main/resources</directory>
-      <outputDirectory>bin/</outputDirectory>
-      <includes>
-        <include>*.exe</include>
-      </includes>
-    </fileSet>
-    <fileSet>
-      <lineEnding>unix</lineEnding>
-      <directory>${basedir}/src/main/conf</directory>
-      <includes>
-        <include>README.txt</include>
-        <include>logging.properties</include>
-        <include>system.properties</include>
-      </includes>
-      <outputDirectory>conf/</outputDirectory>
-    </fileSet>
-    <fileSet>
-      <lineEnding>unix</lineEnding>
-      <outputDirectory>logs/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-    <fileSet>
-      <lineEnding>unix</lineEnding>
-      <outputDirectory>apps/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-    <fileSet>
-      <outputDirectory>data/</outputDirectory>
-      <directory>${project.basedir}/src/main/assembly</directory>
-      <excludes>
-        <exclude>component.xml</exclude>
-        <exclude>dos.xml</exclude>
-        <exclude>unix.xml</exclude>
-      </excludes>
-    </fileSet>
-  </fileSets>
-  <files>
-    <file>
-      <lineEnding>unix</lineEnding>
-      <source>${basedir}/target/classes/DATA-README.txt</source>
-      <outputDirectory>data/</outputDirectory>
-      <destName>README.txt</destName>
-      <fileMode>0755</fileMode>
-    </file>
-  </files>
-  <dependencySets>
-    <dependencySet>
-      <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
-      </outputFileNameMapping>
-      <outputDirectory>lib</outputDirectory>
-      <scope>runtime</scope>
-      <excludes>
-        <exclude>junit:junit</exclude>
-      </excludes>
-    </dependencySet>
-  </dependencySets>
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev: 1482826 $ $Date: 2013-05-15 15:31:58 +0200 (Wed, 15 May 2013) $ -->
+
+<assembly>
+  <id>bin-unix</id>
+  <formats>
+    <format>tar.gz</format>
+  </formats>
+  <fileSets>
+    <fileSet>
+      <lineEnding>unix</lineEnding>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>/</outputDirectory>
+      <includes>
+        <include>README.txt</include>
+        <include>NOTICE</include>
+        <include>LICENSE</include>
+      </includes>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>*.bat</include>
+        <include>service.readme.txt</include>
+      </includes>
+      <lineEnding>dos</lineEnding>
+      <fileMode>0755</fileMode>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/target/classes</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>openejb</include>
+      </includes>
+      <lineEnding>unix</lineEnding>
+      <fileMode>0755</fileMode>
+    </fileSet>
+    <fileSet>
+      <directory>${basedir}/src/main/resources</directory>
+      <outputDirectory>bin/</outputDirectory>
+      <includes>
+        <include>*.exe</include>
+      </includes>
+    </fileSet>
+    <fileSet>
+      <lineEnding>unix</lineEnding>
+      <directory>${basedir}/src/main/conf</directory>
+      <includes>
+        <include>README.txt</include>
+        <include>logging.properties</include>
+        <include>system.properties</include>
+      </includes>
+      <outputDirectory>conf/</outputDirectory>
+    </fileSet>
+    <fileSet>
+      <lineEnding>unix</lineEnding>
+      <outputDirectory>logs/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+    <fileSet>
+      <lineEnding>unix</lineEnding>
+      <outputDirectory>apps/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+    <fileSet>
+      <outputDirectory>data/</outputDirectory>
+      <directory>${project.basedir}/src/main/assembly</directory>
+      <excludes>
+        <exclude>component.xml</exclude>
+        <exclude>dos.xml</exclude>
+        <exclude>unix.xml</exclude>
+      </excludes>
+    </fileSet>
+  </fileSets>
+  <files>
+    <file>
+      <lineEnding>unix</lineEnding>
+      <source>${basedir}/target/classes/DATA-README.txt</source>
+      <outputDirectory>data/</outputDirectory>
+      <destName>README.txt</destName>
+      <fileMode>0755</fileMode>
+    </file>
+  </files>
+  <dependencySets>
+    <dependencySet>
+      <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
+      </outputFileNameMapping>
+      <outputDirectory>lib</outputDirectory>
+      <scope>runtime</scope>
+      <excludes>
+        <exclude>junit:junit</exclude>
+      </excludes>
+    </dependencySet>
+  </dependencySets>
 </assembly>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/resources/Start.bat
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/resources/Start.bat b/assembly/openejb-standalone/src/main/resources/Start.bat
index f8804e1..9bd7d9a 100644
--- a/assembly/openejb-standalone/src/main/resources/Start.bat
+++ b/assembly/openejb-standalone/src/main/resources/Start.bat
@@ -1,34 +1,34 @@
-@echo off
-REM================================================
-REM Licensed to the Apache Software Foundation (ASF) under one or more
-REM contributor license agreements.  See the NOTICE file distributed with
-REM this work for additional information regarding copyright ownership.
-REM The ASF licenses this file to You under the Apache License, Version 2.0
-REM (the "License"); you may not use this file except in compliance with
-REM the License.  You may obtain a copy of the License at
-REM
-REM    http://www.apache.org/licenses/LICENSE-2.0
-REM
-REM Unless required by applicable law or agreed to in writing, software
-REM distributed under the License is distributed on an "AS IS" BASIS,
-REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-REM See the License for the specific language governing permissions and
-REM limitations under the License.
-REM _______________________________________________
-REM $Rev$
-REM================================================
-
-@if not "%ECHO%" == ""  echo %ECHO%
-@if "%OS%" == "Windows_NT" setlocal
-
-if "%OS%" == "Windows_NT" (
-  set "DIRNAME=%~dp0%"
-) else (
-  set DIRNAME=.\
-)
-
-pushd "%DIRNAME%"
-
-cd ..
-
+@echo off
+REM================================================
+REM Licensed to the Apache Software Foundation (ASF) under one or more
+REM contributor license agreements.  See the NOTICE file distributed with
+REM this work for additional information regarding copyright ownership.
+REM The ASF licenses this file to You under the Apache License, Version 2.0
+REM (the "License"); you may not use this file except in compliance with
+REM the License.  You may obtain a copy of the License at
+REM
+REM    http://www.apache.org/licenses/LICENSE-2.0
+REM
+REM Unless required by applicable law or agreed to in writing, software
+REM distributed under the License is distributed on an "AS IS" BASIS,
+REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+REM See the License for the specific language governing permissions and
+REM limitations under the License.
+REM _______________________________________________
+REM $Rev$
+REM================================================
+
+@if not "%ECHO%" == ""  echo %ECHO%
+@if "%OS%" == "Windows_NT" setlocal
+
+if "%OS%" == "Windows_NT" (
+  set "DIRNAME=%~dp0%"
+) else (
+  set DIRNAME=.\
+)
+
+pushd "%DIRNAME%"
+
+cd ..
+
 cmd /C ".\bin\openejb.bat start"
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/resources/Stop.bat
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/resources/Stop.bat b/assembly/openejb-standalone/src/main/resources/Stop.bat
index 66cdd00..50130c2 100644
--- a/assembly/openejb-standalone/src/main/resources/Stop.bat
+++ b/assembly/openejb-standalone/src/main/resources/Stop.bat
@@ -1,34 +1,34 @@
-@echo off
-REM================================================
-REM Licensed to the Apache Software Foundation (ASF) under one or more
-REM contributor license agreements.  See the NOTICE file distributed with
-REM this work for additional information regarding copyright ownership.
-REM The ASF licenses this file to You under the Apache License, Version 2.0
-REM (the "License"); you may not use this file except in compliance with
-REM the License.  You may obtain a copy of the License at
-REM
-REM    http://www.apache.org/licenses/LICENSE-2.0
-REM
-REM Unless required by applicable law or agreed to in writing, software
-REM distributed under the License is distributed on an "AS IS" BASIS,
-REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-REM See the License for the specific language governing permissions and
-REM limitations under the License.
-REM _______________________________________________
-REM $Rev$
-REM================================================
-
-@if not "%ECHO%" == ""  echo %ECHO%
-@if "%OS%" == "Windows_NT" setlocal
-
-if "%OS%" == "Windows_NT" (
-  set "DIRNAME=%~dp0%"
-) else (
-  set DIRNAME=.\
-)
-
-pushd "%DIRNAME%"
-
-cd ..
-
+@echo off
+REM================================================
+REM Licensed to the Apache Software Foundation (ASF) under one or more
+REM contributor license agreements.  See the NOTICE file distributed with
+REM this work for additional information regarding copyright ownership.
+REM The ASF licenses this file to You under the Apache License, Version 2.0
+REM (the "License"); you may not use this file except in compliance with
+REM the License.  You may obtain a copy of the License at
+REM
+REM    http://www.apache.org/licenses/LICENSE-2.0
+REM
+REM Unless required by applicable law or agreed to in writing, software
+REM distributed under the License is distributed on an "AS IS" BASIS,
+REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+REM See the License for the specific language governing permissions and
+REM limitations under the License.
+REM _______________________________________________
+REM $Rev$
+REM================================================
+
+@if not "%ECHO%" == ""  echo %ECHO%
+@if "%OS%" == "Windows_NT" setlocal
+
+if "%OS%" == "Windows_NT" (
+  set "DIRNAME=%~dp0%"
+) else (
+  set DIRNAME=.\
+)
+
+pushd "%DIRNAME%"
+
+cd ..
+
 cmd /C ".\bin\openejb.bat stop"
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/resources/service.install.as.admin.bat
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/resources/service.install.as.admin.bat b/assembly/openejb-standalone/src/main/resources/service.install.as.admin.bat
index 62ec736..678ff74 100644
--- a/assembly/openejb-standalone/src/main/resources/service.install.as.admin.bat
+++ b/assembly/openejb-standalone/src/main/resources/service.install.as.admin.bat
@@ -1,151 +1,151 @@
-@ECHO off
-CLS
-setlocal
-REM ================================================
-REM Licensed to the Apache Software Foundation (ASF) under one or more
-REM contributor license agreements.  See the NOTICE file distributed with
-REM this work for additional information regarding copyright ownership.
-REM The ASF licenses this file to You under the Apache License, Version 2.0
-REM (the "License"); you may not use this file except in compliance with
-REM the License.  You may obtain a copy of the License at
-REM
-REM    http://www.apache.org/licenses/LICENSE-2.0
-REM
-REM Unless required by applicable law or agreed to in writing, software
-REM distributed under the License is distributed on an "AS IS" BASIS,
-REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-REM See the License for the specific language governing permissions and
-REM limitations under the License.
-REM _______________________________________________
-REM $Rev$
-REM ================================================
-
-@IF NOT "%ECHO%" == ""  ECHO %ECHO%
-@IF "%OS%" == "Windows_NT" setlocal
-
-IF "%OS%" == "Windows_NT" (
-  SET "DIRNAME=%~dp0%"
-) ELSE (
-  SET DIRNAME=.\
-)
-
-pushd %DIRNAME%
-
-SET proc=undefined
-
-IF /i %PROCESSOR_ARCHITECTURE% EQU X86 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-IF /i %PROCESSOR_ARCHITECTURE% EQU AMD64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-IF /i %PROCESSOR_ARCHITECTURE% EQU IA64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-
-IF /i %proc% EQU undefined (
-	ECHO Failed to determine OS architecture
-	GOTO failed
-)
-
-SET jvm=auto
-REM SET JAVA_HOME=[Full path to JDK or JRE]
-
-REM Prefer a local JRE or JDK if we find one in the current or parent directory
-pushd..
-set dir=%cd%
-popd
-
-IF EXIST "%dir%\jre" (
-	SET JAVA_HOME="%dir%"
-	ECHO Found local JRE
-	GOTO found_java_home
-)
-
-IF EXIST "%dir%\jdk" (
-	SET JAVA_HOME="%dir%\jdk"
-	ECHO Found local JDK
-	GOTO found_java_home
-)
-
-if not "%JAVA_HOME%" == "" GOTO found_java_home
-
-ECHO Environment variable JAVA_HOME is not set and no local JRE was found.
-ECHO Please set JAVA_HOME to the directory of your local JDK or JRE to avoid this message.
-GOTO skip_java_home
-
-:found_java_home
-
-REM Make an attempt to find either the server or client jvm.dll
-IF EXIST "%JAVA_HOME%\jre\bin\server\jvm.dll" (
-	SET jvm="%JAVA_HOME%\jre\bin\server\jvm.dll"
-) ELSE (
-	IF EXIST "%JAVA_HOME%\jre\bin\client\jvm.dll" (
-		SET jvm="%JAVA_HOME%\jre\bin\client\jvm.dll"
-	) ELSE (
-		IF EXIST "%JAVA_HOME%\bin\server\jvm.dll" (
-			SET jvm="%JAVA_HOME%\bin\server\jvm.dll"
-		) ELSE (
-			IF EXIST "%JAVA_HOME%\bin\client\jvm.dll" (
-				SET jvm="%JAVA_HOME%\bin\client\jvm.dll"
-			) ELSE (
-				ECHO Cannot locate a jvm.dll - Are you sure JAVA_HOME is set correctly?
-				ECHO The service installer will now attempt to locate and use 'any' JVM.
-			)
-		)
-	)
-)
-
-:skip_java_home
-
-SET openejb=.
-CD ..
-
-SET "openejb=%CD%"
-SET logs=%openejb%\logs
-SET lib=%openejb%\lib
-SET corejar="%lib%\openejb-core-*.jar"
-SET daemonjar="%lib%\openejb-daemon-*.jar"
-
-FOR %%a IN (%corejar%) DO (
-  SET corejar="%%a"
-)
-
-FOR %%a IN (%daemonjar%) DO (
-  SET daemonjar="%%a"
-)
-
-SET classpath="%corejar%;%daemonjar%"
-
-ECHO Installing service using JVM: %jvm%
-
-REM Allow file access to Local System 
-cacls "%openejb%" /E /P System:F
-
-REM Extensive documentation can be found here - http://commons.apache.org/daemon/procrun.html
-
-%proc% //IS//OpenEJBServer --DisplayName="OpenEJB Server" ^
-	--Install=%proc% ^
-	--Startup auto ^
-	--StartPath="%openejb%" ^
-	--Description="OpenEJB Server Service" ^
-	--Jvm="%jvm%" ^
-	--Classpath=%classpath% ^
-	--StartMode=jvm ^
-	--StartClass=org.apache.openejb.daemon.NTService --StartMethod=start ^
-	--StopMode=jvm ^
-	--JvmMs=512 ^
-	--JvmMx=1024 ^
-	--JvmSs=2048 ^
-	--StopClass=org.apache.openejb.daemon.NTService --StopMethod=stop ^
-	--LogPrefix=service ^
-	--LogPath="%logs%" --StdOutput="%logs%\service.out.log" --StdError="%logs%\service.err.log" --PidFile=service.pid ^
-	--LogLevel=Info ^
-	--LibraryPath="%openejb%\bin" ^
-	++JvmOptions=-Dopenejb.home="%openejb%";-XX:MaxPermSize=256M
-	REM ++DependsOn=AnotherServiceName
-	REM Add ^ symbol to end of ++JvmOptions line if ++DependsOn is uncommented 
-
-NET START OpenEJBServer
-
-GOTO complete
-
-:failed
-
-ECHO Failed to install service
-
+@ECHO off
+CLS
+setlocal
+REM ================================================
+REM Licensed to the Apache Software Foundation (ASF) under one or more
+REM contributor license agreements.  See the NOTICE file distributed with
+REM this work for additional information regarding copyright ownership.
+REM The ASF licenses this file to You under the Apache License, Version 2.0
+REM (the "License"); you may not use this file except in compliance with
+REM the License.  You may obtain a copy of the License at
+REM
+REM    http://www.apache.org/licenses/LICENSE-2.0
+REM
+REM Unless required by applicable law or agreed to in writing, software
+REM distributed under the License is distributed on an "AS IS" BASIS,
+REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+REM See the License for the specific language governing permissions and
+REM limitations under the License.
+REM _______________________________________________
+REM $Rev$
+REM ================================================
+
+@IF NOT "%ECHO%" == ""  ECHO %ECHO%
+@IF "%OS%" == "Windows_NT" setlocal
+
+IF "%OS%" == "Windows_NT" (
+  SET "DIRNAME=%~dp0%"
+) ELSE (
+  SET DIRNAME=.\
+)
+
+pushd %DIRNAME%
+
+SET proc=undefined
+
+IF /i %PROCESSOR_ARCHITECTURE% EQU X86 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+IF /i %PROCESSOR_ARCHITECTURE% EQU AMD64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+IF /i %PROCESSOR_ARCHITECTURE% EQU IA64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+
+IF /i %proc% EQU undefined (
+	ECHO Failed to determine OS architecture
+	GOTO failed
+)
+
+SET jvm=auto
+REM SET JAVA_HOME=[Full path to JDK or JRE]
+
+REM Prefer a local JRE or JDK if we find one in the current or parent directory
+pushd..
+set dir=%cd%
+popd
+
+IF EXIST "%dir%\jre" (
+	SET JAVA_HOME="%dir%"
+	ECHO Found local JRE
+	GOTO found_java_home
+)
+
+IF EXIST "%dir%\jdk" (
+	SET JAVA_HOME="%dir%\jdk"
+	ECHO Found local JDK
+	GOTO found_java_home
+)
+
+if not "%JAVA_HOME%" == "" GOTO found_java_home
+
+ECHO Environment variable JAVA_HOME is not set and no local JRE was found.
+ECHO Please set JAVA_HOME to the directory of your local JDK or JRE to avoid this message.
+GOTO skip_java_home
+
+:found_java_home
+
+REM Make an attempt to find either the server or client jvm.dll
+IF EXIST "%JAVA_HOME%\jre\bin\server\jvm.dll" (
+	SET jvm="%JAVA_HOME%\jre\bin\server\jvm.dll"
+) ELSE (
+	IF EXIST "%JAVA_HOME%\jre\bin\client\jvm.dll" (
+		SET jvm="%JAVA_HOME%\jre\bin\client\jvm.dll"
+	) ELSE (
+		IF EXIST "%JAVA_HOME%\bin\server\jvm.dll" (
+			SET jvm="%JAVA_HOME%\bin\server\jvm.dll"
+		) ELSE (
+			IF EXIST "%JAVA_HOME%\bin\client\jvm.dll" (
+				SET jvm="%JAVA_HOME%\bin\client\jvm.dll"
+			) ELSE (
+				ECHO Cannot locate a jvm.dll - Are you sure JAVA_HOME is set correctly?
+				ECHO The service installer will now attempt to locate and use 'any' JVM.
+			)
+		)
+	)
+)
+
+:skip_java_home
+
+SET openejb=.
+CD ..
+
+SET "openejb=%CD%"
+SET logs=%openejb%\logs
+SET lib=%openejb%\lib
+SET corejar="%lib%\openejb-core-*.jar"
+SET daemonjar="%lib%\openejb-daemon-*.jar"
+
+FOR %%a IN (%corejar%) DO (
+  SET corejar="%%a"
+)
+
+FOR %%a IN (%daemonjar%) DO (
+  SET daemonjar="%%a"
+)
+
+SET classpath="%corejar%;%daemonjar%"
+
+ECHO Installing service using JVM: %jvm%
+
+REM Allow file access to Local System 
+cacls "%openejb%" /E /P System:F
+
+REM Extensive documentation can be found here - http://commons.apache.org/daemon/procrun.html
+
+%proc% //IS//OpenEJBServer --DisplayName="OpenEJB Server" ^
+	--Install=%proc% ^
+	--Startup auto ^
+	--StartPath="%openejb%" ^
+	--Description="OpenEJB Server Service" ^
+	--Jvm="%jvm%" ^
+	--Classpath=%classpath% ^
+	--StartMode=jvm ^
+	--StartClass=org.apache.openejb.daemon.NTService --StartMethod=start ^
+	--StopMode=jvm ^
+	--JvmMs=512 ^
+	--JvmMx=1024 ^
+	--JvmSs=2048 ^
+	--StopClass=org.apache.openejb.daemon.NTService --StopMethod=stop ^
+	--LogPrefix=service ^
+	--LogPath="%logs%" --StdOutput="%logs%\service.out.log" --StdError="%logs%\service.err.log" --PidFile=service.pid ^
+	--LogLevel=Info ^
+	--LibraryPath="%openejb%\bin" ^
+	++JvmOptions=-Dopenejb.home="%openejb%";-XX:MaxPermSize=256M
+	REM ++DependsOn=AnotherServiceName
+	REM Add ^ symbol to end of ++JvmOptions line if ++DependsOn is uncommented 
+
+NET START OpenEJBServer
+
+GOTO complete
+
+:failed
+
+ECHO Failed to install service
+
 :complete
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/assembly/openejb-standalone/src/main/resources/service.remove.as.admin.bat
----------------------------------------------------------------------
diff --git a/assembly/openejb-standalone/src/main/resources/service.remove.as.admin.bat b/assembly/openejb-standalone/src/main/resources/service.remove.as.admin.bat
index d3f2fdd..b7794fc 100644
--- a/assembly/openejb-standalone/src/main/resources/service.remove.as.admin.bat
+++ b/assembly/openejb-standalone/src/main/resources/service.remove.as.admin.bat
@@ -1,49 +1,49 @@
-@echo off
-cls
-REM================================================
-REM Licensed to the Apache Software Foundation (ASF) under one or more
-REM contributor license agreements.  See the NOTICE file distributed with
-REM this work for additional information regarding copyright ownership.
-REM The ASF licenses this file to You under the Apache License, Version 2.0
-REM (the "License"); you may not use this file except in compliance with
-REM the License.  You may obtain a copy of the License at
-REM
-REM    http://www.apache.org/licenses/LICENSE-2.0
-REM
-REM Unless required by applicable law or agreed to in writing, software
-REM distributed under the License is distributed on an "AS IS" BASIS,
-REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-REM See the License for the specific language governing permissions and
-REM limitations under the License.
-REM _______________________________________________
-REM $Rev$
-REM================================================
-
-@if not "%ECHO%" == ""  echo %ECHO%
-@if "%OS%" == "Windows_NT" setlocal
-
-if "%OS%" == "Windows_NT" (
-  set "DIRNAME=%~dp0%"
-) else (
-  set DIRNAME=.\
-)
-
-pushd %DIRNAME%
-
-SET proc=undefined
-
-if /i %PROCESSOR_ARCHITECTURE% EQU X86 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-if /i %PROCESSOR_ARCHITECTURE% EQU AMD64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-if /i %PROCESSOR_ARCHITECTURE% EQU IA64 SET proc=%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
-
-if /i %proc% EQU undefined GOTO failed
-
-%proc% //DS//OpenEJBServer
-
-GOTO complete
-
-:failed
-
-ECHO Failed to determine OS architecture
-
+@echo off
+cls
+REM================================================
+REM Licensed to the Apache Software Foundation (ASF) under one or more
+REM contributor license agreements.  See the NOTICE file distributed with
+REM this work for additional information regarding copyright ownership.
+REM The ASF licenses this file to You under the Apache License, Version 2.0
+REM (the "License"); you may not use this file except in compliance with
+REM the License.  You may obtain a copy of the License at
+REM
+REM    http://www.apache.org/licenses/LICENSE-2.0
+REM
+REM Unless required by applicable law or agreed to in writing, software
+REM distributed under the License is distributed on an "AS IS" BASIS,
+REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+REM See the License for the specific language governing permissions and
+REM limitations under the License.
+REM _______________________________________________
+REM $Rev$
+REM================================================
+
+@if not "%ECHO%" == ""  echo %ECHO%
+@if "%OS%" == "Windows_NT" setlocal
+
+if "%OS%" == "Windows_NT" (
+  set "DIRNAME=%~dp0%"
+) else (
+  set DIRNAME=.\
+)
+
+pushd %DIRNAME%
+
+SET proc=undefined
+
+if /i %PROCESSOR_ARCHITECTURE% EQU X86 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+if /i %PROCESSOR_ARCHITECTURE% EQU AMD64 SET proc="%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+if /i %PROCESSOR_ARCHITECTURE% EQU IA64 SET proc=%~dp0OpenEJB.%PROCESSOR_ARCHITECTURE%.exe"
+
+if /i %proc% EQU undefined GOTO failed
+
+%proc% //DS//OpenEJBServer
+
+GOTO complete
+
+:failed
+
+ECHO Failed to determine OS architecture
+
 :complete
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/EntityManagerFactoryCallable.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/EntityManagerFactoryCallable.java b/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/EntityManagerFactoryCallable.java
index b8b6721..cb5706b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/EntityManagerFactoryCallable.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/EntityManagerFactoryCallable.java
@@ -1,101 +1,101 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.assembler.classic;
-
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.persistence.PersistenceUnitInfoImpl;
-
-import javax.persistence.EntityManagerFactory;
-import javax.persistence.ValidationMode;
-import javax.persistence.spi.PersistenceProvider;
-import javax.validation.ValidatorFactory;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.concurrent.Callable;
-
-public class EntityManagerFactoryCallable implements Callable<EntityManagerFactory> {
-    public static final String OPENEJB_JPA_INIT_ENTITYMANAGER = "openejb.jpa.init-entitymanager";
-    public static final String OPENJPA_ENTITY_MANAGER_FACTORY_POOL = "openjpa.EntityManagerFactoryPool";
-
-    private final String persistenceProviderClassName;
-    private final PersistenceUnitInfoImpl unitInfo;
-    private final Map<ComparableValidationConfig, ValidatorFactory> potentialValidators;
-    private ClassLoader appClassLoader;
-
-    public EntityManagerFactoryCallable(final String persistenceProviderClassName, final PersistenceUnitInfoImpl unitInfo,
-                                        final ClassLoader cl, final Map<ComparableValidationConfig, ValidatorFactory> validators) {
-        this.persistenceProviderClassName = persistenceProviderClassName;
-        this.unitInfo = unitInfo;
-        this.appClassLoader = cl;
-        this.potentialValidators = validators;
-    }
-
-    @Override
-    public EntityManagerFactory call() throws Exception {
-        final ClassLoader old = Thread.currentThread().getContextClassLoader();
-        Thread.currentThread().setContextClassLoader(appClassLoader);
-        try {
-            final Class<?> clazz = appClassLoader.loadClass(persistenceProviderClassName);
-            final PersistenceProvider persistenceProvider = (PersistenceProvider) clazz.newInstance();
-
-            // Create entity manager factories with the validator factory
-            final Map<String, Object> properties = new HashMap<String, Object>();
-            if (!ValidationMode.NONE.equals(unitInfo.getValidationMode())) {
-                properties.put("javax.persistence.validation.factory", new ValidatorFactoryWrapper(potentialValidators));
-            }
-
-            customizeProperties(properties);
-
-            final EntityManagerFactory emf = persistenceProvider.createContainerEntityManagerFactory(unitInfo, properties);
-
-            if (unitInfo.getProperties() != null
-                && "true".equalsIgnoreCase(unitInfo.getProperties().getProperty(OPENEJB_JPA_INIT_ENTITYMANAGER))
-                || SystemInstance.get().getOptions().get(OPENEJB_JPA_INIT_ENTITYMANAGER, false)) {
-                emf.createEntityManager().close();
-            }
-
-            if (unitInfo.getNonJtaDataSource() != null) {
-                final ImportSql importer = new ImportSql(appClassLoader, unitInfo.getPersistenceUnitName(), unitInfo.getNonJtaDataSource());
-                if (importer.hasSomethingToImport()) {
-                    emf.createEntityManager().close(); // to let OpenJPA create the database if configured this way
-                    importer.doImport();
-                }
-            }
-
-            return emf;
-        } finally {
-            Thread.currentThread().setContextClassLoader(old);
-        }
-    }
-
-    // properties that have to be passed to properties parameters and not unit properties
-    private void customizeProperties(final Map<String, Object> properties) {
-        final String pool = SystemInstance.get().getProperty(OPENJPA_ENTITY_MANAGER_FACTORY_POOL);
-        if (pool != null) {
-            properties.put(OPENJPA_ENTITY_MANAGER_FACTORY_POOL, pool);
-        }
-    }
-
-    public PersistenceUnitInfoImpl getUnitInfo() {
-        return unitInfo;
-    }
-
-    public void overrideClassLoader(final ClassLoader loader) {
-        appClassLoader = loader;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.assembler.classic;
+
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.persistence.PersistenceUnitInfoImpl;
+
+import javax.persistence.EntityManagerFactory;
+import javax.persistence.ValidationMode;
+import javax.persistence.spi.PersistenceProvider;
+import javax.validation.ValidatorFactory;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.concurrent.Callable;
+
+public class EntityManagerFactoryCallable implements Callable<EntityManagerFactory> {
+    public static final String OPENEJB_JPA_INIT_ENTITYMANAGER = "openejb.jpa.init-entitymanager";
+    public static final String OPENJPA_ENTITY_MANAGER_FACTORY_POOL = "openjpa.EntityManagerFactoryPool";
+
+    private final String persistenceProviderClassName;
+    private final PersistenceUnitInfoImpl unitInfo;
+    private final Map<ComparableValidationConfig, ValidatorFactory> potentialValidators;
+    private ClassLoader appClassLoader;
+
+    public EntityManagerFactoryCallable(final String persistenceProviderClassName, final PersistenceUnitInfoImpl unitInfo,
+                                        final ClassLoader cl, final Map<ComparableValidationConfig, ValidatorFactory> validators) {
+        this.persistenceProviderClassName = persistenceProviderClassName;
+        this.unitInfo = unitInfo;
+        this.appClassLoader = cl;
+        this.potentialValidators = validators;
+    }
+
+    @Override
+    public EntityManagerFactory call() throws Exception {
+        final ClassLoader old = Thread.currentThread().getContextClassLoader();
+        Thread.currentThread().setContextClassLoader(appClassLoader);
+        try {
+            final Class<?> clazz = appClassLoader.loadClass(persistenceProviderClassName);
+            final PersistenceProvider persistenceProvider = (PersistenceProvider) clazz.newInstance();
+
+            // Create entity manager factories with the validator factory
+            final Map<String, Object> properties = new HashMap<String, Object>();
+            if (!ValidationMode.NONE.equals(unitInfo.getValidationMode())) {
+                properties.put("javax.persistence.validation.factory", new ValidatorFactoryWrapper(potentialValidators));
+            }
+
+            customizeProperties(properties);
+
+            final EntityManagerFactory emf = persistenceProvider.createContainerEntityManagerFactory(unitInfo, properties);
+
+            if (unitInfo.getProperties() != null
+                && "true".equalsIgnoreCase(unitInfo.getProperties().getProperty(OPENEJB_JPA_INIT_ENTITYMANAGER))
+                || SystemInstance.get().getOptions().get(OPENEJB_JPA_INIT_ENTITYMANAGER, false)) {
+                emf.createEntityManager().close();
+            }
+
+            if (unitInfo.getNonJtaDataSource() != null) {
+                final ImportSql importer = new ImportSql(appClassLoader, unitInfo.getPersistenceUnitName(), unitInfo.getNonJtaDataSource());
+                if (importer.hasSomethingToImport()) {
+                    emf.createEntityManager().close(); // to let OpenJPA create the database if configured this way
+                    importer.doImport();
+                }
+            }
+
+            return emf;
+        } finally {
+            Thread.currentThread().setContextClassLoader(old);
+        }
+    }
+
+    // properties that have to be passed to properties parameters and not unit properties
+    private void customizeProperties(final Map<String, Object> properties) {
+        final String pool = SystemInstance.get().getProperty(OPENJPA_ENTITY_MANAGER_FACTORY_POOL);
+        if (pool != null) {
+            properties.put(OPENJPA_ENTITY_MANAGER_FACTORY_POOL, pool);
+        }
+    }
+
+    public PersistenceUnitInfoImpl getUnitInfo() {
+        return unitInfo;
+    }
+
+    public void overrideClassLoader(final ClassLoader loader) {
+        appClassLoader = loader;
+    }
+}


[08/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/DynamicDataSourceTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/DynamicDataSourceTest.java b/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/DynamicDataSourceTest.java
index f4f8efe..8b03d45 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/DynamicDataSourceTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/DynamicDataSourceTest.java
@@ -1,329 +1,329 @@
-/**
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.resource.jdbc;
-
-import org.apache.openejb.OpenEJB;
-import org.apache.openejb.assembler.classic.Assembler;
-import org.apache.openejb.assembler.classic.ProxyFactoryInfo;
-import org.apache.openejb.assembler.classic.ResourceInfo;
-import org.apache.openejb.assembler.classic.SecurityServiceInfo;
-import org.apache.openejb.assembler.classic.StatelessSessionContainerInfo;
-import org.apache.openejb.assembler.classic.TransactionServiceInfo;
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.ConfigurationFactory;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.config.PersistenceModule;
-import org.apache.openejb.config.sys.Resource;
-import org.apache.openejb.core.LocalInitialContextFactory;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.jee.jpa.unit.Persistence;
-import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
-import org.apache.openejb.jee.jpa.unit.TransactionType;
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.resource.jdbc.router.Router;
-import org.apache.openejb.spi.ContainerSystem;
-import org.junit.After;
-import org.junit.Test;
-
-import javax.ejb.Local;
-import javax.ejb.Stateless;
-import javax.ejb.TransactionAttribute;
-import javax.ejb.TransactionAttributeType;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import javax.naming.NamingException;
-import javax.persistence.Entity;
-import javax.persistence.EntityManager;
-import javax.persistence.Id;
-import javax.persistence.PersistenceContext;
-import javax.sql.DataSource;
-import java.sql.Connection;
-import java.sql.DriverManager;
-import java.sql.ResultSet;
-import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-import java.util.concurrent.ConcurrentHashMap;
-
-import static org.junit.Assert.assertEquals;
-
-public class DynamicDataSourceTest {
-
-    @After
-    public void tearDown() throws Exception {
-        OpenEJB.destroy();
-    }
-
-    @Test
-    public void route() throws Exception {
-        System.setProperty(javax.naming.Context.INITIAL_CONTEXT_FACTORY, LocalInitialContextFactory.class.getName());
-
-        final ConfigurationFactory config = new ConfigurationFactory();
-
-        final Assembler assembler = new Assembler();
-        assembler.createProxyFactory(config.configureService(ProxyFactoryInfo.class));
-        assembler.createTransactionManager(config.configureService(TransactionServiceInfo.class));
-        assembler.createSecurityService(config.configureService(SecurityServiceInfo.class));
-
-        // resources
-        for (int i = 1; i <= 3; i++) {
-            final String dbName = "database" + i;
-            final Resource resourceDs = new Resource(dbName, "DataSource");
-            final Properties p = resourceDs.getProperties();
-            p.put("JdbcDriver", "org.hsqldb.jdbcDriver");
-            p.put("JdbcUrl", "jdbc:hsqldb:mem:db" + i);
-            p.put("UserName", "sa");
-            p.put("Password", "");
-            p.put("JtaManaged", "true");
-            assembler.createResource(config.configureService(resourceDs, ResourceInfo.class));
-        }
-        final Resource resourceRouter = new Resource("My Router", "org.apache.openejb.router.test.DynamicDataSourceTest$DeterminedRouter", "org.router:DeterminedRouter");
-        resourceRouter.getProperties().setProperty("DatasourceNames", "database1 database2 database3");
-        resourceRouter.getProperties().setProperty("DefaultDataSourceName", "database1");
-        assembler.createResource(config.configureService(resourceRouter, ResourceInfo.class));
-
-        final Resource resourceRoutedDs = new Resource("Routed Datasource", "org.apache.openejb.resource.jdbc.Router", "RoutedDataSource");
-        resourceRoutedDs.getProperties().setProperty("Router", "My Router");
-        assembler.createResource(config.configureService(resourceRoutedDs, ResourceInfo.class));
-
-        // containers
-        final StatelessSessionContainerInfo statelessContainerInfo = config.configureService(StatelessSessionContainerInfo.class);
-        assembler.createContainer(statelessContainerInfo);
-
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(RoutedEJBBean.class));
-        ejbJar.addEnterpriseBean(new StatelessBean(UtilityBean.class));
-
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-
-        // Create an "ear"
-        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), "test-dynamic-data-source");
-        appModule.getEjbModules().add(ejbModule);
-
-        // Create a persistence-units
-        final PersistenceUnit unit = new PersistenceUnit("router");
-        unit.addClass(Person.class);
-        unit.getProperties().put("openjpa.jdbc.SynchronizeMappings", "buildSchema");
-        unit.setTransactionType(TransactionType.JTA);
-        unit.setJtaDataSource("Routed Datasource");
-        appModule.addPersistenceModule(new PersistenceModule("root", new Persistence(unit)));
-        for (int i = 1; i <= 3; i++) {
-            final PersistenceUnit u = new PersistenceUnit("db" + i);
-            u.addClass(Person.class);
-            u.getProperties().put("openjpa.jdbc.SynchronizeMappings", "buildSchema");
-            u.setTransactionType(TransactionType.JTA);
-            u.setJtaDataSource("database" + i);
-            appModule.addPersistenceModule(new PersistenceModule("root", new Persistence(u)));
-        }
-
-        assembler.createApplication(config.configureApplication(appModule));
-
-        // context
-        final Context ctx = new InitialContext();
-
-        // running persist on all "routed" databases
-        final List<String> databases = new ArrayList<String>();
-        databases.add("database1");
-        databases.add("database2");
-        databases.add("database3");
-
-        // convinient bean to create tables for each persistence unit
-        final Utility utility = (Utility) ctx.lookup("UtilityBeanLocal");
-        utility.initDatabase();
-
-        final RoutedEJB ejb = (RoutedEJB) ctx.lookup("RoutedEJBBeanLocal");
-        for (int i = 0; i < 18; i++) {
-            final String name = "record " + i;
-            final String db = databases.get(i % 3);
-            ejb.persist(i, name, db);
-        }
-
-        // assert database records number using jdbc
-        for (int i = 1; i <= 3; i++) {
-            final Connection connection = DriverManager.getConnection("jdbc:hsqldb:mem:db" + i, "sa", "");
-            final Statement st = connection.createStatement();
-            final ResultSet rs = st.executeQuery("select count(*) from \"DynamicDataSourceTest$Person\"");
-            rs.next();
-            assertEquals(6, rs.getInt(1));
-            st.close();
-            connection.close();
-        }
-    }
-
-    @Stateless
-    @Local(RoutedEJB.class)
-    public static class RoutedEJBBean implements RoutedEJB {
-        @PersistenceContext(unitName = "router")
-        private EntityManager em;
-
-        @javax.annotation.Resource(name = "My Router", type = DeterminedRouter.class)
-        private DeterminedRouter router;
-
-        public void persist(final int id, final String name, final String ds) {
-            router.setDataSource(ds);
-            em.persist(new Person(id, name));
-        }
-
-    }
-
-    @Stateless
-    @Local(Utility.class)
-    public static class UtilityBean implements Utility {
-
-        @PersistenceContext(unitName = "db1")
-        private EntityManager em1;
-        @PersistenceContext(unitName = "db2")
-        private EntityManager em2;
-        @PersistenceContext(unitName = "db3")
-        private EntityManager em3;
-
-        @TransactionAttribute(TransactionAttributeType.SUPPORTS)
-        public void initDatabase() {
-            em1.find(Person.class, 0);
-            em2.find(Person.class, 0);
-            em3.find(Person.class, 0);
-        }
-    }
-
-    public static interface RoutedEJB {
-        void persist(int id, String name, String ds);
-    }
-
-    public static interface Utility {
-        void initDatabase();
-    }
-
-    @Entity
-    public static class Person {
-        @Id
-        private long id;
-        private String name;
-
-        public Person() {
-            // no-op
-        }
-
-        public Person(final int i, final String n) {
-            id = i;
-            name = n;
-        }
-
-        public long getId() {
-            return id;
-        }
-
-        public void setId(final long id) {
-            this.id = id;
-        }
-
-        public String getName() {
-            return name;
-        }
-
-        public void setName(final String name) {
-            this.name = name;
-        }
-    }
-
-    public static class DeterminedRouter implements Router {
-        private String dataSourceNames;
-        private String defaultDataSourceName;
-        private Map<String, DataSource> dataSources = null;
-        private final ThreadLocal<DataSource> currentDataSource = new ThreadLocal<DataSource>();
-
-        /**
-         * @param datasourceList datasource resource name, separator is a space
-         */
-        public void setDataSourceNames(final String datasourceList) {
-            dataSourceNames = datasourceList;
-        }
-
-        /**
-         * lookup datasource in openejb resources
-         */
-        private void init() {
-            dataSources = new ConcurrentHashMap<String, DataSource>();
-            for (final String ds : dataSourceNames.split(" ")) {
-                final ContainerSystem containerSystem = SystemInstance.get().getComponent(ContainerSystem.class);
-
-                Object o = null;
-                final Context ctx = containerSystem.getJNDIContext();
-                try {
-                    o = ctx.lookup("openejb:Resource/" + ds);
-                    if (o instanceof DataSource) {
-                        dataSources.put(ds, (DataSource) o);
-                    }
-                } catch (final NamingException e) {
-                }
-            }
-        }
-
-        /**
-         * @return the user selected data source if it is set
-         * or the default one
-         * @throws IllegalArgumentException if the data source is not found
-         */
-        public DataSource getDataSource() {
-            // lazy init of routed datasources
-            if (dataSources == null) {
-                init();
-            }
-
-            // if no datasource is selected use the default one
-            if (currentDataSource.get() == null) {
-                if (dataSources.containsKey(defaultDataSourceName)) {
-                    return dataSources.get(defaultDataSourceName);
-
-                } else {
-                    throw new IllegalArgumentException("you have to specify at least one datasource");
-                }
-            }
-
-            // the developper set the datasource to use
-            return currentDataSource.get();
-        }
-
-        /**
-         * @param datasourceName data source name
-         */
-        public void setDataSource(final String datasourceName) {
-            if (dataSources == null) {
-                init();
-            }
-            if (!dataSources.containsKey(datasourceName)) {
-                throw new IllegalArgumentException("data source called " + datasourceName + " can't be found.");
-            }
-            final DataSource ds = dataSources.get(datasourceName);
-            currentDataSource.set(ds);
-        }
-
-        /**
-         * reset the data source
-         */
-        public void clear() {
-            currentDataSource.remove();
-        }
-
-        public void setDefaultDataSourceName(final String name) {
-            this.defaultDataSourceName = name;
-        }
-    }
-}
+/**
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.resource.jdbc;
+
+import org.apache.openejb.OpenEJB;
+import org.apache.openejb.assembler.classic.Assembler;
+import org.apache.openejb.assembler.classic.ProxyFactoryInfo;
+import org.apache.openejb.assembler.classic.ResourceInfo;
+import org.apache.openejb.assembler.classic.SecurityServiceInfo;
+import org.apache.openejb.assembler.classic.StatelessSessionContainerInfo;
+import org.apache.openejb.assembler.classic.TransactionServiceInfo;
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.ConfigurationFactory;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.config.PersistenceModule;
+import org.apache.openejb.config.sys.Resource;
+import org.apache.openejb.core.LocalInitialContextFactory;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.jee.jpa.unit.Persistence;
+import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
+import org.apache.openejb.jee.jpa.unit.TransactionType;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.resource.jdbc.router.Router;
+import org.apache.openejb.spi.ContainerSystem;
+import org.junit.After;
+import org.junit.Test;
+
+import javax.ejb.Local;
+import javax.ejb.Stateless;
+import javax.ejb.TransactionAttribute;
+import javax.ejb.TransactionAttributeType;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import javax.persistence.Entity;
+import javax.persistence.EntityManager;
+import javax.persistence.Id;
+import javax.persistence.PersistenceContext;
+import javax.sql.DataSource;
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.ResultSet;
+import java.sql.Statement;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.concurrent.ConcurrentHashMap;
+
+import static org.junit.Assert.assertEquals;
+
+public class DynamicDataSourceTest {
+
+    @After
+    public void tearDown() throws Exception {
+        OpenEJB.destroy();
+    }
+
+    @Test
+    public void route() throws Exception {
+        System.setProperty(javax.naming.Context.INITIAL_CONTEXT_FACTORY, LocalInitialContextFactory.class.getName());
+
+        final ConfigurationFactory config = new ConfigurationFactory();
+
+        final Assembler assembler = new Assembler();
+        assembler.createProxyFactory(config.configureService(ProxyFactoryInfo.class));
+        assembler.createTransactionManager(config.configureService(TransactionServiceInfo.class));
+        assembler.createSecurityService(config.configureService(SecurityServiceInfo.class));
+
+        // resources
+        for (int i = 1; i <= 3; i++) {
+            final String dbName = "database" + i;
+            final Resource resourceDs = new Resource(dbName, "DataSource");
+            final Properties p = resourceDs.getProperties();
+            p.put("JdbcDriver", "org.hsqldb.jdbcDriver");
+            p.put("JdbcUrl", "jdbc:hsqldb:mem:db" + i);
+            p.put("UserName", "sa");
+            p.put("Password", "");
+            p.put("JtaManaged", "true");
+            assembler.createResource(config.configureService(resourceDs, ResourceInfo.class));
+        }
+        final Resource resourceRouter = new Resource("My Router", "org.apache.openejb.router.test.DynamicDataSourceTest$DeterminedRouter", "org.router:DeterminedRouter");
+        resourceRouter.getProperties().setProperty("DatasourceNames", "database1 database2 database3");
+        resourceRouter.getProperties().setProperty("DefaultDataSourceName", "database1");
+        assembler.createResource(config.configureService(resourceRouter, ResourceInfo.class));
+
+        final Resource resourceRoutedDs = new Resource("Routed Datasource", "org.apache.openejb.resource.jdbc.Router", "RoutedDataSource");
+        resourceRoutedDs.getProperties().setProperty("Router", "My Router");
+        assembler.createResource(config.configureService(resourceRoutedDs, ResourceInfo.class));
+
+        // containers
+        final StatelessSessionContainerInfo statelessContainerInfo = config.configureService(StatelessSessionContainerInfo.class);
+        assembler.createContainer(statelessContainerInfo);
+
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(RoutedEJBBean.class));
+        ejbJar.addEnterpriseBean(new StatelessBean(UtilityBean.class));
+
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+
+        // Create an "ear"
+        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), "test-dynamic-data-source");
+        appModule.getEjbModules().add(ejbModule);
+
+        // Create a persistence-units
+        final PersistenceUnit unit = new PersistenceUnit("router");
+        unit.addClass(Person.class);
+        unit.getProperties().put("openjpa.jdbc.SynchronizeMappings", "buildSchema");
+        unit.setTransactionType(TransactionType.JTA);
+        unit.setJtaDataSource("Routed Datasource");
+        appModule.addPersistenceModule(new PersistenceModule("root", new Persistence(unit)));
+        for (int i = 1; i <= 3; i++) {
+            final PersistenceUnit u = new PersistenceUnit("db" + i);
+            u.addClass(Person.class);
+            u.getProperties().put("openjpa.jdbc.SynchronizeMappings", "buildSchema");
+            u.setTransactionType(TransactionType.JTA);
+            u.setJtaDataSource("database" + i);
+            appModule.addPersistenceModule(new PersistenceModule("root", new Persistence(u)));
+        }
+
+        assembler.createApplication(config.configureApplication(appModule));
+
+        // context
+        final Context ctx = new InitialContext();
+
+        // running persist on all "routed" databases
+        final List<String> databases = new ArrayList<String>();
+        databases.add("database1");
+        databases.add("database2");
+        databases.add("database3");
+
+        // convinient bean to create tables for each persistence unit
+        final Utility utility = (Utility) ctx.lookup("UtilityBeanLocal");
+        utility.initDatabase();
+
+        final RoutedEJB ejb = (RoutedEJB) ctx.lookup("RoutedEJBBeanLocal");
+        for (int i = 0; i < 18; i++) {
+            final String name = "record " + i;
+            final String db = databases.get(i % 3);
+            ejb.persist(i, name, db);
+        }
+
+        // assert database records number using jdbc
+        for (int i = 1; i <= 3; i++) {
+            final Connection connection = DriverManager.getConnection("jdbc:hsqldb:mem:db" + i, "sa", "");
+            final Statement st = connection.createStatement();
+            final ResultSet rs = st.executeQuery("select count(*) from \"DynamicDataSourceTest$Person\"");
+            rs.next();
+            assertEquals(6, rs.getInt(1));
+            st.close();
+            connection.close();
+        }
+    }
+
+    @Stateless
+    @Local(RoutedEJB.class)
+    public static class RoutedEJBBean implements RoutedEJB {
+        @PersistenceContext(unitName = "router")
+        private EntityManager em;
+
+        @javax.annotation.Resource(name = "My Router", type = DeterminedRouter.class)
+        private DeterminedRouter router;
+
+        public void persist(final int id, final String name, final String ds) {
+            router.setDataSource(ds);
+            em.persist(new Person(id, name));
+        }
+
+    }
+
+    @Stateless
+    @Local(Utility.class)
+    public static class UtilityBean implements Utility {
+
+        @PersistenceContext(unitName = "db1")
+        private EntityManager em1;
+        @PersistenceContext(unitName = "db2")
+        private EntityManager em2;
+        @PersistenceContext(unitName = "db3")
+        private EntityManager em3;
+
+        @TransactionAttribute(TransactionAttributeType.SUPPORTS)
+        public void initDatabase() {
+            em1.find(Person.class, 0);
+            em2.find(Person.class, 0);
+            em3.find(Person.class, 0);
+        }
+    }
+
+    public static interface RoutedEJB {
+        void persist(int id, String name, String ds);
+    }
+
+    public static interface Utility {
+        void initDatabase();
+    }
+
+    @Entity
+    public static class Person {
+        @Id
+        private long id;
+        private String name;
+
+        public Person() {
+            // no-op
+        }
+
+        public Person(final int i, final String n) {
+            id = i;
+            name = n;
+        }
+
+        public long getId() {
+            return id;
+        }
+
+        public void setId(final long id) {
+            this.id = id;
+        }
+
+        public String getName() {
+            return name;
+        }
+
+        public void setName(final String name) {
+            this.name = name;
+        }
+    }
+
+    public static class DeterminedRouter implements Router {
+        private String dataSourceNames;
+        private String defaultDataSourceName;
+        private Map<String, DataSource> dataSources = null;
+        private final ThreadLocal<DataSource> currentDataSource = new ThreadLocal<DataSource>();
+
+        /**
+         * @param datasourceList datasource resource name, separator is a space
+         */
+        public void setDataSourceNames(final String datasourceList) {
+            dataSourceNames = datasourceList;
+        }
+
+        /**
+         * lookup datasource in openejb resources
+         */
+        private void init() {
+            dataSources = new ConcurrentHashMap<String, DataSource>();
+            for (final String ds : dataSourceNames.split(" ")) {
+                final ContainerSystem containerSystem = SystemInstance.get().getComponent(ContainerSystem.class);
+
+                Object o = null;
+                final Context ctx = containerSystem.getJNDIContext();
+                try {
+                    o = ctx.lookup("openejb:Resource/" + ds);
+                    if (o instanceof DataSource) {
+                        dataSources.put(ds, (DataSource) o);
+                    }
+                } catch (final NamingException e) {
+                }
+            }
+        }
+
+        /**
+         * @return the user selected data source if it is set
+         * or the default one
+         * @throws IllegalArgumentException if the data source is not found
+         */
+        public DataSource getDataSource() {
+            // lazy init of routed datasources
+            if (dataSources == null) {
+                init();
+            }
+
+            // if no datasource is selected use the default one
+            if (currentDataSource.get() == null) {
+                if (dataSources.containsKey(defaultDataSourceName)) {
+                    return dataSources.get(defaultDataSourceName);
+
+                } else {
+                    throw new IllegalArgumentException("you have to specify at least one datasource");
+                }
+            }
+
+            // the developper set the datasource to use
+            return currentDataSource.get();
+        }
+
+        /**
+         * @param datasourceName data source name
+         */
+        public void setDataSource(final String datasourceName) {
+            if (dataSources == null) {
+                init();
+            }
+            if (!dataSources.containsKey(datasourceName)) {
+                throw new IllegalArgumentException("data source called " + datasourceName + " can't be found.");
+            }
+            final DataSource ds = dataSources.get(datasourceName);
+            currentDataSource.set(ds);
+        }
+
+        /**
+         * reset the data source
+         */
+        public void clear() {
+            currentDataSource.remove();
+        }
+
+        public void setDefaultDataSourceName(final String name) {
+            this.defaultDataSourceName = name;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/driver/AlternateDriverJarTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/driver/AlternateDriverJarTest.java b/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/driver/AlternateDriverJarTest.java
index 600a81e..f0b4758 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/driver/AlternateDriverJarTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/resource/jdbc/driver/AlternateDriverJarTest.java
@@ -1,130 +1,130 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.resource.jdbc.driver;
-
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.SingletonBean;
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.testing.Configuration;
-import org.apache.openejb.testing.Module;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.annotation.Resource;
-import javax.ejb.EJB;
-import javax.ejb.LocalBean;
-import javax.ejb.Singleton;
-import javax.sql.DataSource;
-import java.io.File;
-import java.sql.Connection;
-import java.sql.DatabaseMetaData;
-import java.util.Properties;
-
-@RunWith(ApplicationComposer.class)
-public class AlternateDriverJarTest {
-
-    private static final String USER = "SA";
-    private static final String PASSWORD = "";
-
-    @Configuration
-    public Properties config() {
-
-        final File drivers = new File(new File(System.getProperty("openejb.home")).getParentFile(), "drivers").getAbsoluteFile();
-
-        final Properties p = new Properties();
-        p.put("openejb.jdbc.datasource-creator", "dbcp-alternative");
-
-        File file = new File(drivers, "derby-10.10.1.1.jar");
-        Assert.assertTrue("Failed to find: " + file, file.exists());
-
-        p.put("JdbcOne", "new://Resource?type=DataSource&classpath="
-            + file.getAbsolutePath().replace("\\", "/"));
-        p.put("JdbcOne.JdbcDriver", "org.apache.derby.jdbc.EmbeddedDriver");
-        p.put("JdbcOne.JdbcUrl", "jdbc:derby:memory:JdbcOne;create=true");
-        p.put("JdbcOne.UserName", USER);
-        p.put("JdbcOne.Password", PASSWORD);
-        p.put("JdbcOne.JtaManaged", "false");
-
-        file = new File(drivers, "derby-10.9.1.0.jar");
-        Assert.assertTrue("Failed to find: " + file, file.exists());
-
-        p.put("JdbcTwo", "new://Resource?type=DataSource&classpath="
-            + file.getAbsolutePath().replace("\\", "/"));
-        p.put("JdbcTwo.JdbcDriver", "org.apache.derby.jdbc.EmbeddedDriver");
-        p.put("JdbcTwo.JdbcUrl", "jdbc:derby:memory:JdbcTwo;create=true");
-        p.put("JdbcTwo.UserName", USER);
-        p.put("JdbcTwo.Password", PASSWORD);
-        p.put("JdbcTwo.JtaManaged", "false");
-        return p;
-    }
-
-    @Module
-    public EjbJar app() throws Exception {
-        return new EjbJar()
-            .enterpriseBean(new SingletonBean(JdbcOne.class).localBean())
-            .enterpriseBean(new SingletonBean(JdbcTwo.class).localBean());
-    }
-
-    @EJB
-    private JdbcOne one;
-
-    @EJB
-    private JdbcTwo two;
-
-    @Test
-    public void testBoth() throws Exception {
-
-        final String oneDriverVersion = one.getDriverVersion();
-        System.out.println("oneDriverVersion = " + oneDriverVersion);
-        Assert.assertEquals("Should be using 10.10.1.1 - (1458268)", "10.10.1.1 - (1458268)", oneDriverVersion);
-
-        final String twoDriverVersion = two.getDriverVersion();
-        System.out.println("twoDriverVersion = " + twoDriverVersion);
-        Assert.assertEquals("Should be using 10.9.1.0 - (1344872)", "10.9.1.0 - (1344872)", twoDriverVersion);
-    }
-
-    @LocalBean
-    @Singleton
-    public static class JdbcOne {
-
-        @Resource(name = "JdbcOne")
-        private DataSource ds;
-
-        public String getDriverVersion() throws Exception {
-
-            final Connection con = ds.getConnection();
-            final DatabaseMetaData md = con.getMetaData();
-            return md.getDriverVersion();
-        }
-    }
-
-    @LocalBean
-    @Singleton
-    public static class JdbcTwo {
-
-        @Resource(name = "JdbcTwo")
-        private DataSource ds;
-
-        public String getDriverVersion() throws Exception {
-
-            final Connection con = ds.getConnection();
-            final DatabaseMetaData md = con.getMetaData();
-            return md.getDriverVersion();
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.resource.jdbc.driver;
+
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.SingletonBean;
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.testing.Configuration;
+import org.apache.openejb.testing.Module;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.annotation.Resource;
+import javax.ejb.EJB;
+import javax.ejb.LocalBean;
+import javax.ejb.Singleton;
+import javax.sql.DataSource;
+import java.io.File;
+import java.sql.Connection;
+import java.sql.DatabaseMetaData;
+import java.util.Properties;
+
+@RunWith(ApplicationComposer.class)
+public class AlternateDriverJarTest {
+
+    private static final String USER = "SA";
+    private static final String PASSWORD = "";
+
+    @Configuration
+    public Properties config() {
+
+        final File drivers = new File(new File(System.getProperty("openejb.home")).getParentFile(), "drivers").getAbsoluteFile();
+
+        final Properties p = new Properties();
+        p.put("openejb.jdbc.datasource-creator", "dbcp-alternative");
+
+        File file = new File(drivers, "derby-10.10.1.1.jar");
+        Assert.assertTrue("Failed to find: " + file, file.exists());
+
+        p.put("JdbcOne", "new://Resource?type=DataSource&classpath="
+            + file.getAbsolutePath().replace("\\", "/"));
+        p.put("JdbcOne.JdbcDriver", "org.apache.derby.jdbc.EmbeddedDriver");
+        p.put("JdbcOne.JdbcUrl", "jdbc:derby:memory:JdbcOne;create=true");
+        p.put("JdbcOne.UserName", USER);
+        p.put("JdbcOne.Password", PASSWORD);
+        p.put("JdbcOne.JtaManaged", "false");
+
+        file = new File(drivers, "derby-10.9.1.0.jar");
+        Assert.assertTrue("Failed to find: " + file, file.exists());
+
+        p.put("JdbcTwo", "new://Resource?type=DataSource&classpath="
+            + file.getAbsolutePath().replace("\\", "/"));
+        p.put("JdbcTwo.JdbcDriver", "org.apache.derby.jdbc.EmbeddedDriver");
+        p.put("JdbcTwo.JdbcUrl", "jdbc:derby:memory:JdbcTwo;create=true");
+        p.put("JdbcTwo.UserName", USER);
+        p.put("JdbcTwo.Password", PASSWORD);
+        p.put("JdbcTwo.JtaManaged", "false");
+        return p;
+    }
+
+    @Module
+    public EjbJar app() throws Exception {
+        return new EjbJar()
+            .enterpriseBean(new SingletonBean(JdbcOne.class).localBean())
+            .enterpriseBean(new SingletonBean(JdbcTwo.class).localBean());
+    }
+
+    @EJB
+    private JdbcOne one;
+
+    @EJB
+    private JdbcTwo two;
+
+    @Test
+    public void testBoth() throws Exception {
+
+        final String oneDriverVersion = one.getDriverVersion();
+        System.out.println("oneDriverVersion = " + oneDriverVersion);
+        Assert.assertEquals("Should be using 10.10.1.1 - (1458268)", "10.10.1.1 - (1458268)", oneDriverVersion);
+
+        final String twoDriverVersion = two.getDriverVersion();
+        System.out.println("twoDriverVersion = " + twoDriverVersion);
+        Assert.assertEquals("Should be using 10.9.1.0 - (1344872)", "10.9.1.0 - (1344872)", twoDriverVersion);
+    }
+
+    @LocalBean
+    @Singleton
+    public static class JdbcOne {
+
+        @Resource(name = "JdbcOne")
+        private DataSource ds;
+
+        public String getDriverVersion() throws Exception {
+
+            final Connection con = ds.getConnection();
+            final DatabaseMetaData md = con.getMetaData();
+            return md.getDriverVersion();
+        }
+    }
+
+    @LocalBean
+    @Singleton
+    public static class JdbcTwo {
+
+        @Resource(name = "JdbcTwo")
+        private DataSource ds;
+
+        public String getDriverVersion() throws Exception {
+
+            final Connection con = ds.getConnection();
+            final DatabaseMetaData md = con.getMetaData();
+            return md.getDriverVersion();
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Green.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Green.java b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Green.java
index 7e22c15..9333805 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Green.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Green.java
@@ -1,33 +1,33 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.test.annotated;
-
-import javax.ejb.Stateful;
-import javax.interceptor.AroundInvoke;
-import javax.jws.WebService;
-
-
-@Stateful(description = "test")
-@WebService
-public class Green {
-
-    // need to add this @AroundInvoke to cause validation to fail. Validation does not
-    // fail on warnings, which causes this framework to not work properly
-    @AroundInvoke
-    public void sayCheese() {
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.test.annotated;
+
+import javax.ejb.Stateful;
+import javax.interceptor.AroundInvoke;
+import javax.jws.WebService;
+
+
+@Stateful(description = "test")
+@WebService
+public class Green {
+
+    // need to add this @AroundInvoke to cause validation to fail. Validation does not
+    // fail on warnings, which causes this framework to not work properly
+    @AroundInvoke
+    public void sayCheese() {
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Red.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Red.java b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Red.java
index 5cff367..69632ec 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Red.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Red.java
@@ -1,32 +1,32 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.test.annotated;
-
-import javax.annotation.ManagedBean;
-import javax.interceptor.AroundInvoke;
-import javax.jws.WebService;
-
-@ManagedBean
-@WebService
-public class Red {
-
-    // need to add this @AroundInvoke to cause validation to fail. Validation does not
-    // fail on warnings, which causes this framework to not work properly
-    @AroundInvoke
-    public void sayCheese() {
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.test.annotated;
+
+import javax.annotation.ManagedBean;
+import javax.interceptor.AroundInvoke;
+import javax.jws.WebService;
+
+@ManagedBean
+@WebService
+public class Red {
+
+    // need to add this @AroundInvoke to cause validation to fail. Validation does not
+    // fail on warnings, which causes this framework to not work properly
+    @AroundInvoke
+    public void sayCheese() {
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Yellow.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Yellow.java b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Yellow.java
index f8774ff..d16c274 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Yellow.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/test/annotated/Yellow.java
@@ -1,40 +1,40 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.test.annotated;
-
-import javax.ejb.MessageDriven;
-import javax.interceptor.AroundInvoke;
-import javax.jms.Message;
-import javax.jms.MessageListener;
-import javax.jws.WebService;
-
-
-@MessageDriven
-@WebService
-public class Yellow implements MessageListener {
-
-    // need to add this @AroundInvoke to cause validation to fail. Validation does not
-    // fail on warnings, which causes this framework to not work properly
-    @AroundInvoke
-    public void sayCheese() {
-    }
-
-    @Override
-    public void onMessage(final Message message) {
-        //To change body of implemented methods use File | Settings | File Templates.
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.test.annotated;
+
+import javax.ejb.MessageDriven;
+import javax.interceptor.AroundInvoke;
+import javax.jms.Message;
+import javax.jms.MessageListener;
+import javax.jws.WebService;
+
+
+@MessageDriven
+@WebService
+public class Yellow implements MessageListener {
+
+    // need to add this @AroundInvoke to cause validation to fail. Validation does not
+    // fail on warnings, which causes this framework to not work properly
+    @AroundInvoke
+    public void sayCheese() {
+    }
+
+    @Override
+    public void onMessage(final Message message) {
+        //To change body of implemented methods use File | Settings | File Templates.
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/util/BeanTypeComparisonTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/util/BeanTypeComparisonTest.java b/container/openejb-core/src/test/java/org/apache/openejb/util/BeanTypeComparisonTest.java
index 67aa55f..7bc1d27 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/util/BeanTypeComparisonTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/util/BeanTypeComparisonTest.java
@@ -1,35 +1,35 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.util;
-
-import org.apache.openejb.BeanType;
-import org.apache.openejb.jee.SessionType;
-import org.junit.Test;
-
-import static org.junit.Assert.assertFalse;
-
-public class BeanTypeComparisonTest {
-
-    @Test
-    public void testEqualsMethodForDifferentClassTypes() {
-        final BeanType beanType = BeanType.STATELESS;
-        final SessionType sessionType = SessionType.STATELESS;
-        assertFalse(beanType.equals(sessionType));
-    }
-
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.util;
+
+import org.apache.openejb.BeanType;
+import org.apache.openejb.jee.SessionType;
+import org.junit.Test;
+
+import static org.junit.Assert.assertFalse;
+
+public class BeanTypeComparisonTest {
+
+    @Test
+    public void testEqualsMethodForDifferentClassTypes() {
+        final BeanType beanType = BeanType.STATELESS;
+        final SessionType sessionType = SessionType.STATELESS;
+        assertFalse(beanType.equals(sessionType));
+    }
+
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/util/CollectionsUtilTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/util/CollectionsUtilTest.java b/container/openejb-core/src/test/java/org/apache/openejb/util/CollectionsUtilTest.java
index 7eca925..fe7373d 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/util/CollectionsUtilTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/util/CollectionsUtilTest.java
@@ -1,34 +1,34 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.util;
-
-import org.junit.Test;
-
-import java.util.List;
-
-public class CollectionsUtilTest {
-
-    @Test
-    public void safeIterationForNullList() {
-        final List<String> stringList = null;
-        for (final String string : CollectionsUtil.safe(stringList)) {
-        }
-
-        //PASS: No NPE thrown
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.util;
+
+import org.junit.Test;
+
+import java.util.List;
+
+public class CollectionsUtilTest {
+
+    @Test
+    public void safeIterationForNullList() {
+        final List<String> stringList = null;
+        for (final String string : CollectionsUtil.safe(stringList)) {
+        }
+
+        //PASS: No NPE thrown
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/util/NetworkUtilTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/util/NetworkUtilTest.java b/container/openejb-core/src/test/java/org/apache/openejb/util/NetworkUtilTest.java
index c64889f..25082f6 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/util/NetworkUtilTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/util/NetworkUtilTest.java
@@ -1,132 +1,132 @@
-/**
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.util;
-
-import org.junit.AfterClass;
-import org.junit.Assert;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-import java.io.File;
-import java.net.InetAddress;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.concurrent.CopyOnWriteArrayList;
-import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.TimeUnit;
-
-public class NetworkUtilTest {
-
-    private static File f = null;
-
-    @BeforeClass
-    public static void beforeClass() throws Exception {
-        f = File.createTempFile("tomee", "lock");
-    }
-
-    @AfterClass
-    public static void afterClass() {
-        if (null != f && !f.delete()) {
-            f.deleteOnExit();
-        }
-    }
-
-
-    @Test
-    public void testNext() throws Exception {
-
-        NetworkUtil.clearLockFile();
-
-        final int count = 20;
-        final CountDownLatch latch = new CountDownLatch(count);
-        final long start = System.currentTimeMillis();
-        final CopyOnWriteArrayList<Integer> list = new CopyOnWriteArrayList<Integer>();
-
-        final List<NetworkUtil.LastPort> lastPorts = new ArrayList<NetworkUtil.LastPort>();
-        for (int i = 0; i < count; i++) {
-            final Thread thread = new Thread(new Runnable() {
-                public void run() {
-                    final int nextAvailablePort = NetworkUtil.getNextAvailablePort();
-                    if (list.contains(nextAvailablePort)) {
-                        if ((System.currentTimeMillis() - start) < 10000) {
-                            Assert.fail("Got a duplicate port with ten seconds");
-                        }
-                    } else {
-                        list.add(nextAvailablePort);
-                    }
-
-                    latch.countDown();
-                }
-            }, "test-thread-" + count);
-            thread.setDaemon(false);
-            thread.start();
-        }
-
-        final boolean success = latch.await(15, TimeUnit.SECONDS);
-        Assert.assertTrue(success);
-
-        System.out.println("VM safe port list = " + list);
-    }
-
-    @Test
-    public void testNextLock() throws Exception {
-
-        System.setProperty(NetworkUtil.TOMEE_LOCK_FILE, f.getAbsolutePath());
-
-        final int count = 20;
-        final CountDownLatch latch = new CountDownLatch(count);
-        final long start = System.currentTimeMillis();
-        final CopyOnWriteArrayList<Integer> list = new CopyOnWriteArrayList<Integer>();
-
-        final List<NetworkUtil.LastPort> lastPorts = new ArrayList<NetworkUtil.LastPort>();
-        for (int i = 0; i < count; i++) {
-            final Thread thread = new Thread(new Runnable() {
-                public void run() {
-                    final int nextAvailablePort = NetworkUtil.getNextAvailablePort(NetworkUtil.PORT_MIN, NetworkUtil.PORT_MAX, Collections.<Integer>emptyList(), lastPorts);
-                    if (list.contains(nextAvailablePort)) {
-                        if ((System.currentTimeMillis() - start) < 10000) {
-                            Assert.fail("Got a duplicate port with ten seconds");
-                        }
-                    } else {
-                        list.add(nextAvailablePort);
-                    }
-
-                    latch.countDown();
-                }
-            }, "test-thread-" + count);
-            thread.setDaemon(false);
-            thread.start();
-        }
-
-        final boolean success = latch.await(15, TimeUnit.SECONDS);
-        Assert.assertTrue(success);
-
-        System.out.println("Machine safe port list = " + list);
-    }
-
-    @Test
-    public void testLocal() throws Exception {
-        Assert.assertTrue(NetworkUtil.isLocalAddress(InetAddress.getLocalHost()));
-    }
-
-    @Test
-    public void testLocalhost() throws Exception {
-        Assert.assertTrue(NetworkUtil.isLocalAddress("localhost"));
-    }
-}
+/**
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.util;
+
+import org.junit.AfterClass;
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import java.io.File;
+import java.net.InetAddress;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
+
+public class NetworkUtilTest {
+
+    private static File f = null;
+
+    @BeforeClass
+    public static void beforeClass() throws Exception {
+        f = File.createTempFile("tomee", "lock");
+    }
+
+    @AfterClass
+    public static void afterClass() {
+        if (null != f && !f.delete()) {
+            f.deleteOnExit();
+        }
+    }
+
+
+    @Test
+    public void testNext() throws Exception {
+
+        NetworkUtil.clearLockFile();
+
+        final int count = 20;
+        final CountDownLatch latch = new CountDownLatch(count);
+        final long start = System.currentTimeMillis();
+        final CopyOnWriteArrayList<Integer> list = new CopyOnWriteArrayList<Integer>();
+
+        final List<NetworkUtil.LastPort> lastPorts = new ArrayList<NetworkUtil.LastPort>();
+        for (int i = 0; i < count; i++) {
+            final Thread thread = new Thread(new Runnable() {
+                public void run() {
+                    final int nextAvailablePort = NetworkUtil.getNextAvailablePort();
+                    if (list.contains(nextAvailablePort)) {
+                        if ((System.currentTimeMillis() - start) < 10000) {
+                            Assert.fail("Got a duplicate port with ten seconds");
+                        }
+                    } else {
+                        list.add(nextAvailablePort);
+                    }
+
+                    latch.countDown();
+                }
+            }, "test-thread-" + count);
+            thread.setDaemon(false);
+            thread.start();
+        }
+
+        final boolean success = latch.await(15, TimeUnit.SECONDS);
+        Assert.assertTrue(success);
+
+        System.out.println("VM safe port list = " + list);
+    }
+
+    @Test
+    public void testNextLock() throws Exception {
+
+        System.setProperty(NetworkUtil.TOMEE_LOCK_FILE, f.getAbsolutePath());
+
+        final int count = 20;
+        final CountDownLatch latch = new CountDownLatch(count);
+        final long start = System.currentTimeMillis();
+        final CopyOnWriteArrayList<Integer> list = new CopyOnWriteArrayList<Integer>();
+
+        final List<NetworkUtil.LastPort> lastPorts = new ArrayList<NetworkUtil.LastPort>();
+        for (int i = 0; i < count; i++) {
+            final Thread thread = new Thread(new Runnable() {
+                public void run() {
+                    final int nextAvailablePort = NetworkUtil.getNextAvailablePort(NetworkUtil.PORT_MIN, NetworkUtil.PORT_MAX, Collections.<Integer>emptyList(), lastPorts);
+                    if (list.contains(nextAvailablePort)) {
+                        if ((System.currentTimeMillis() - start) < 10000) {
+                            Assert.fail("Got a duplicate port with ten seconds");
+                        }
+                    } else {
+                        list.add(nextAvailablePort);
+                    }
+
+                    latch.countDown();
+                }
+            }, "test-thread-" + count);
+            thread.setDaemon(false);
+            thread.start();
+        }
+
+        final boolean success = latch.await(15, TimeUnit.SECONDS);
+        Assert.assertTrue(success);
+
+        System.out.println("Machine safe port list = " + list);
+    }
+
+    @Test
+    public void testLocal() throws Exception {
+        Assert.assertTrue(NetworkUtil.isLocalAddress(InetAddress.getLocalHost()));
+    }
+
+    @Test
+    public void testLocalhost() throws Exception {
+        Assert.assertTrue(NetworkUtil.isLocalAddress("localhost"));
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/META-INF/jpa-test-mappings.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/META-INF/jpa-test-mappings.xml b/container/openejb-core/src/test/resources/META-INF/jpa-test-mappings.xml
index a644fac..fe6eae5 100644
--- a/container/openejb-core/src/test/resources/META-INF/jpa-test-mappings.xml
+++ b/container/openejb-core/src/test/resources/META-INF/jpa-test-mappings.xml
@@ -1,24 +1,24 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" version="1.0">
     <mapped-superclass class="org.apache.openejb.test.entity.cmp.BasicCmpBean">
         <attributes>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/META-INF/org.acme/service-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/META-INF/org.acme/service-jar.xml b/container/openejb-core/src/test/resources/META-INF/org.acme/service-jar.xml
index c9bceb1..147189f 100644
--- a/container/openejb-core/src/test/resources/META-INF/org.acme/service-jar.xml
+++ b/container/openejb-core/src/test/resources/META-INF/org.acme/service-jar.xml
@@ -1,24 +1,24 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <ServiceJar>
 
   <ServiceProvider id="CheddarContainer" service="Container" class-name="org.acme.SuperContainer">

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/META-INF/org.router/service-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/META-INF/org.router/service-jar.xml b/container/openejb-core/src/test/resources/META-INF/org.router/service-jar.xml
index cb86297..e409d7d 100644
--- a/container/openejb-core/src/test/resources/META-INF/org.router/service-jar.xml
+++ b/container/openejb-core/src/test/resources/META-INF/org.router/service-jar.xml
@@ -1,28 +1,28 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ -->
-<ServiceJar>
-  <ServiceProvider id="DeterminedRouter" service="Resource"
-    type="org.apache.openejb.resource.jdbc.router.Router"
-    class-name="org.apache.openejb.resource.jdbc.DynamicDataSourceTest$DeterminedRouter">
-    DataSourceNames
-    DefaultDataSourceName
-  </ServiceProvider>
-</ServiceJar>
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ -->
+<ServiceJar>
+  <ServiceProvider id="DeterminedRouter" service="Resource"
+    type="org.apache.openejb.resource.jdbc.router.Router"
+    class-name="org.apache.openejb.resource.jdbc.DynamicDataSourceTest$DeterminedRouter">
+    DataSourceNames
+    DefaultDataSourceName
+  </ServiceProvider>
+</ServiceJar>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-openejb-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-openejb-jar.xml b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-openejb-jar.xml
index 9ea2e3d..e2017c0 100644
--- a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-openejb-jar.xml
+++ b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-openejb-jar.xml
@@ -1,23 +1,23 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <openejb-jar xmlns="http://tomee.apache.org/xml/ns/openejb-jar-2.2"
   xmlns:naming="http://geronimo.apache.org/xml/ns/naming-1.2"
  xmlns:sys="http://geronimo.apache.org/xml/ns/deployment-1.2">


[14/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/activemq/ActiveMQFactory.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/activemq/ActiveMQFactory.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/activemq/ActiveMQFactory.java
index 19fc6df..52da2af 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/activemq/ActiveMQFactory.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/activemq/ActiveMQFactory.java
@@ -1,154 +1,154 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.activemq;
-
-import org.apache.activemq.broker.BrokerService;
-import org.apache.openejb.OpenEJBRuntimeException;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.net.URI;
-import java.util.Collection;
-import java.util.Properties;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-public class ActiveMQFactory {
-
-    private static final AtomicBoolean initialized = new AtomicBoolean(false);
-    private static Method setThreadProperties;
-    private static Method createBroker;
-    private static Method getBrokers;
-    private static Object instance;
-    private static String brokerPrefix;
-
-    private static void init() {
-
-        synchronized (initialized) {
-
-            if (!initialized.getAndSet(true)) {
-
-                Class tmp;
-
-                try {
-                    tmp = Class.forName("org.apache.openejb.resource.activemq.ActiveMQ5Factory");
-                    brokerPrefix = "amq5factory:";
-                } catch (final Throwable t1) {
-                    try {
-                        tmp = Class.forName("org.apache.openejb.resource.activemq.ActiveMQ4Factory");
-                        brokerPrefix = "amq4factory:";
-                    } catch (final Throwable t2) {
-                        throw new OpenEJBRuntimeException("Unable to load ActiveMQFactory: Check ActiveMQ jar files are on classpath", t1);
-                    }
-                }
-
-                final Class clazz = tmp;
-
-                try {
-                    instance = clazz.newInstance();
-                } catch (final InstantiationException e) {
-                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory instance", e);
-                } catch (final IllegalAccessException e) {
-                    throw new OpenEJBRuntimeException("Unable to access ActiveMQFactory instance", e);
-                }
-
-                try {
-                    setThreadProperties = clazz.getDeclaredMethod("setThreadProperties", new Class[]{Properties.class});
-                } catch (final NoSuchMethodException e) {
-                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory setThreadProperties method", e);
-                }
-
-                try {
-                    createBroker = clazz.getDeclaredMethod("createBroker", new Class[]{URI.class});
-                } catch (final NoSuchMethodException e) {
-                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory createBroker method", e);
-                }
-
-                try {
-                    getBrokers = clazz.getDeclaredMethod("getBrokers", (Class[]) null);
-                } catch (final NoSuchMethodException e) {
-                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory createBroker method", e);
-                }
-            }
-        }
-    }
-
-    /**
-     * Returns the prefix metafile name of the poperties file that ActiveMQ should be
-     * provided with. This file is located at META-INF/services/org/apache/activemq/broker/
-     * and defines the BrokerFactoryHandler to load.
-     *
-     * @return String name - will be either 'amq5factory:' or 'amq4factory:' - note the trailing ':'
-     */
-    public static String getBrokerMetaFile() {
-        ActiveMQFactory.init();
-        return brokerPrefix;
-    }
-
-    public static void setThreadProperties(final Properties p) {
-
-        ActiveMQFactory.init();
-
-        try {
-            setThreadProperties.invoke(instance, p);
-        } catch (final IllegalAccessException e) {
-            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.IllegalAccessException", e);
-        } catch (final IllegalArgumentException e) {
-            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.IllegalArgumentException", e);
-        } catch (final InvocationTargetException e) {
-            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.InvocationTargetException", e);
-        }
-    }
-
-    public static BrokerService createBroker(final URI brokerURI) throws Exception {
-
-        ActiveMQFactory.init();
-
-        try {
-            return (BrokerService) createBroker.invoke(instance, brokerURI);
-        } catch (final IllegalAccessException e) {
-            throw new Exception("ActiveMQFactory.createBroker.IllegalAccessException", e);
-        } catch (final IllegalArgumentException e) {
-            throw new Exception("ActiveMQFactory.createBroker.IllegalArgumentException", e);
-        } catch (final InvocationTargetException e) {
-            throw new Exception("ActiveMQFactory.createBroker.InvocationTargetException", e);
-        }
-    }
-
-    /**
-     * Returns a map of configured brokers.
-     * This intended for access upon RA shutdown in order to wait for the brokers to finish.
-     *
-     * @return Map(URI, BrokerService)
-     * @throws Exception On error
-     */
-    public static Collection<BrokerService> getBrokers() throws Exception {
-
-        ActiveMQFactory.init();
-
-        try {
-            //noinspection unchecked
-            return (Collection<BrokerService>) getBrokers.invoke(instance, (Object[]) null);
-        } catch (final IllegalAccessException e) {
-            throw new Exception("ActiveMQFactory.createBroker.IllegalAccessException", e);
-        } catch (final IllegalArgumentException e) {
-            throw new Exception("ActiveMQFactory.createBroker.IllegalArgumentException", e);
-        } catch (final InvocationTargetException e) {
-            throw new Exception("ActiveMQFactory.createBroker.InvocationTargetException", e);
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.activemq;
+
+import org.apache.activemq.broker.BrokerService;
+import org.apache.openejb.OpenEJBRuntimeException;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.net.URI;
+import java.util.Collection;
+import java.util.Properties;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+public class ActiveMQFactory {
+
+    private static final AtomicBoolean initialized = new AtomicBoolean(false);
+    private static Method setThreadProperties;
+    private static Method createBroker;
+    private static Method getBrokers;
+    private static Object instance;
+    private static String brokerPrefix;
+
+    private static void init() {
+
+        synchronized (initialized) {
+
+            if (!initialized.getAndSet(true)) {
+
+                Class tmp;
+
+                try {
+                    tmp = Class.forName("org.apache.openejb.resource.activemq.ActiveMQ5Factory");
+                    brokerPrefix = "amq5factory:";
+                } catch (final Throwable t1) {
+                    try {
+                        tmp = Class.forName("org.apache.openejb.resource.activemq.ActiveMQ4Factory");
+                        brokerPrefix = "amq4factory:";
+                    } catch (final Throwable t2) {
+                        throw new OpenEJBRuntimeException("Unable to load ActiveMQFactory: Check ActiveMQ jar files are on classpath", t1);
+                    }
+                }
+
+                final Class clazz = tmp;
+
+                try {
+                    instance = clazz.newInstance();
+                } catch (final InstantiationException e) {
+                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory instance", e);
+                } catch (final IllegalAccessException e) {
+                    throw new OpenEJBRuntimeException("Unable to access ActiveMQFactory instance", e);
+                }
+
+                try {
+                    setThreadProperties = clazz.getDeclaredMethod("setThreadProperties", new Class[]{Properties.class});
+                } catch (final NoSuchMethodException e) {
+                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory setThreadProperties method", e);
+                }
+
+                try {
+                    createBroker = clazz.getDeclaredMethod("createBroker", new Class[]{URI.class});
+                } catch (final NoSuchMethodException e) {
+                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory createBroker method", e);
+                }
+
+                try {
+                    getBrokers = clazz.getDeclaredMethod("getBrokers", (Class[]) null);
+                } catch (final NoSuchMethodException e) {
+                    throw new OpenEJBRuntimeException("Unable to create ActiveMQFactory createBroker method", e);
+                }
+            }
+        }
+    }
+
+    /**
+     * Returns the prefix metafile name of the poperties file that ActiveMQ should be
+     * provided with. This file is located at META-INF/services/org/apache/activemq/broker/
+     * and defines the BrokerFactoryHandler to load.
+     *
+     * @return String name - will be either 'amq5factory:' or 'amq4factory:' - note the trailing ':'
+     */
+    public static String getBrokerMetaFile() {
+        ActiveMQFactory.init();
+        return brokerPrefix;
+    }
+
+    public static void setThreadProperties(final Properties p) {
+
+        ActiveMQFactory.init();
+
+        try {
+            setThreadProperties.invoke(instance, p);
+        } catch (final IllegalAccessException e) {
+            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.IllegalAccessException", e);
+        } catch (final IllegalArgumentException e) {
+            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.IllegalArgumentException", e);
+        } catch (final InvocationTargetException e) {
+            throw new OpenEJBRuntimeException("ActiveMQFactory.setThreadProperties.InvocationTargetException", e);
+        }
+    }
+
+    public static BrokerService createBroker(final URI brokerURI) throws Exception {
+
+        ActiveMQFactory.init();
+
+        try {
+            return (BrokerService) createBroker.invoke(instance, brokerURI);
+        } catch (final IllegalAccessException e) {
+            throw new Exception("ActiveMQFactory.createBroker.IllegalAccessException", e);
+        } catch (final IllegalArgumentException e) {
+            throw new Exception("ActiveMQFactory.createBroker.IllegalArgumentException", e);
+        } catch (final InvocationTargetException e) {
+            throw new Exception("ActiveMQFactory.createBroker.InvocationTargetException", e);
+        }
+    }
+
+    /**
+     * Returns a map of configured brokers.
+     * This intended for access upon RA shutdown in order to wait for the brokers to finish.
+     *
+     * @return Map(URI, BrokerService)
+     * @throws Exception On error
+     */
+    public static Collection<BrokerService> getBrokers() throws Exception {
+
+        ActiveMQFactory.init();
+
+        try {
+            //noinspection unchecked
+            return (Collection<BrokerService>) getBrokers.invoke(instance, (Object[]) null);
+        } catch (final IllegalAccessException e) {
+            throw new Exception("ActiveMQFactory.createBroker.IllegalAccessException", e);
+        } catch (final IllegalArgumentException e) {
+            throw new Exception("ActiveMQFactory.createBroker.IllegalArgumentException", e);
+        } catch (final InvocationTargetException e) {
+            throw new Exception("ActiveMQFactory.createBroker.InvocationTargetException", e);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/RoutedDataSource.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/RoutedDataSource.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/RoutedDataSource.java
index dd727c3..9e94cd2 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/RoutedDataSource.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/RoutedDataSource.java
@@ -1,129 +1,129 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc;
-
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.resource.jdbc.router.Router;
-import org.apache.openejb.spi.ContainerSystem;
-import org.apache.openejb.util.reflection.Reflections;
-
-import javax.naming.NamingException;
-import javax.sql.DataSource;
-import java.io.PrintWriter;
-import java.sql.Connection;
-import java.sql.SQLException;
-import java.sql.SQLFeatureNotSupportedException;
-import java.util.logging.Logger;
-
-public class RoutedDataSource implements DataSource {
-    private static final String OPENEJB_RESOURCE_PREFIX = "openejb:Resource/";
-
-    private Router delegate;
-
-    public RoutedDataSource() {
-        // no-op
-    }
-
-    public RoutedDataSource(final String router) {
-        setRouter(router);
-    }
-
-    public void setRouter(final String router) {
-        final Object o;
-        try {
-            o = SystemInstance.get().getComponent(ContainerSystem.class).getJNDIContext().lookup(OPENEJB_RESOURCE_PREFIX + router);
-        } catch (final NamingException e) {
-            throw new IllegalArgumentException("Can't find router [" + router + "]", e);
-        }
-
-        if (Router.class.isInstance(o)) {
-            delegate = Router.class.cast(o);
-        } else {
-            throw new IllegalArgumentException(o + " is not a router");
-        }
-    }
-
-    public PrintWriter getLogWriter() throws SQLException {
-        if (getTargetDataSource() == null) {
-            return null;
-        }
-        return getTargetDataSource().getLogWriter();
-    }
-
-    public void setLogWriter(final PrintWriter out) throws SQLException {
-        if (getTargetDataSource() != null) {
-            getTargetDataSource().setLogWriter(out);
-        }
-    }
-
-    public void setLoginTimeout(final int seconds) throws SQLException {
-        if (getTargetDataSource() != null) {
-            getTargetDataSource().setLoginTimeout(seconds);
-        }
-    }
-
-    public int getLoginTimeout() throws SQLException {
-        if (getTargetDataSource() == null) {
-            return -1;
-        }
-        return getTargetDataSource().getLoginTimeout();
-    }
-
-    public <T> T unwrap(final Class<T> iface) throws SQLException {
-        if (getTargetDataSource() == null) {
-            return null;
-        }
-        return (T) Reflections.invokeByReflection(getTargetDataSource(), "unwrap",
-            new Class<?>[]{Class.class}, new Object[]{iface});
-    }
-
-    public Logger getParentLogger() throws SQLFeatureNotSupportedException {
-        if (getTargetDataSource() == null) {
-            return null;
-        }
-        return (Logger) Reflections.invokeByReflection(getTargetDataSource(), "getParentLogger", new Class<?>[0], null);
-    }
-
-    public boolean isWrapperFor(final Class<?> iface) throws SQLException {
-        if (getTargetDataSource() == null) {
-            return false;
-        }
-        return (Boolean) Reflections.invokeByReflection(getTargetDataSource(), "isWrapperFor",
-            new Class<?>[]{Class.class}, new Object[]{iface});
-    }
-
-    public Connection getConnection() throws SQLException {
-        return getTargetDataSource().getConnection();
-    }
-
-    public Connection getConnection(final String username, final String password)
-        throws SQLException {
-        return getTargetDataSource().getConnection(username, password);
-    }
-
-    public Router getDelegate() {
-        if (delegate == null) {
-            throw new IllegalStateException("a router has to be defined");
-        }
-        return delegate;
-    }
-
-    private DataSource getTargetDataSource() {
-        return getDelegate().getDataSource();
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc;
+
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.resource.jdbc.router.Router;
+import org.apache.openejb.spi.ContainerSystem;
+import org.apache.openejb.util.reflection.Reflections;
+
+import javax.naming.NamingException;
+import javax.sql.DataSource;
+import java.io.PrintWriter;
+import java.sql.Connection;
+import java.sql.SQLException;
+import java.sql.SQLFeatureNotSupportedException;
+import java.util.logging.Logger;
+
+public class RoutedDataSource implements DataSource {
+    private static final String OPENEJB_RESOURCE_PREFIX = "openejb:Resource/";
+
+    private Router delegate;
+
+    public RoutedDataSource() {
+        // no-op
+    }
+
+    public RoutedDataSource(final String router) {
+        setRouter(router);
+    }
+
+    public void setRouter(final String router) {
+        final Object o;
+        try {
+            o = SystemInstance.get().getComponent(ContainerSystem.class).getJNDIContext().lookup(OPENEJB_RESOURCE_PREFIX + router);
+        } catch (final NamingException e) {
+            throw new IllegalArgumentException("Can't find router [" + router + "]", e);
+        }
+
+        if (Router.class.isInstance(o)) {
+            delegate = Router.class.cast(o);
+        } else {
+            throw new IllegalArgumentException(o + " is not a router");
+        }
+    }
+
+    public PrintWriter getLogWriter() throws SQLException {
+        if (getTargetDataSource() == null) {
+            return null;
+        }
+        return getTargetDataSource().getLogWriter();
+    }
+
+    public void setLogWriter(final PrintWriter out) throws SQLException {
+        if (getTargetDataSource() != null) {
+            getTargetDataSource().setLogWriter(out);
+        }
+    }
+
+    public void setLoginTimeout(final int seconds) throws SQLException {
+        if (getTargetDataSource() != null) {
+            getTargetDataSource().setLoginTimeout(seconds);
+        }
+    }
+
+    public int getLoginTimeout() throws SQLException {
+        if (getTargetDataSource() == null) {
+            return -1;
+        }
+        return getTargetDataSource().getLoginTimeout();
+    }
+
+    public <T> T unwrap(final Class<T> iface) throws SQLException {
+        if (getTargetDataSource() == null) {
+            return null;
+        }
+        return (T) Reflections.invokeByReflection(getTargetDataSource(), "unwrap",
+            new Class<?>[]{Class.class}, new Object[]{iface});
+    }
+
+    public Logger getParentLogger() throws SQLFeatureNotSupportedException {
+        if (getTargetDataSource() == null) {
+            return null;
+        }
+        return (Logger) Reflections.invokeByReflection(getTargetDataSource(), "getParentLogger", new Class<?>[0], null);
+    }
+
+    public boolean isWrapperFor(final Class<?> iface) throws SQLException {
+        if (getTargetDataSource() == null) {
+            return false;
+        }
+        return (Boolean) Reflections.invokeByReflection(getTargetDataSource(), "isWrapperFor",
+            new Class<?>[]{Class.class}, new Object[]{iface});
+    }
+
+    public Connection getConnection() throws SQLException {
+        return getTargetDataSource().getConnection();
+    }
+
+    public Connection getConnection(final String username, final String password)
+        throws SQLException {
+        return getTargetDataSource().getConnection(username, password);
+    }
+
+    public Router getDelegate() {
+        if (delegate == null) {
+            throw new IllegalStateException("a router has to be defined");
+        }
+        return delegate;
+    }
+
+    private DataSource getTargetDataSource() {
+        return getDelegate().getDataSource();
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PasswordCipher.java
index 2c67f7a..d9665ca 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PasswordCipher.java
@@ -1,29 +1,29 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc.cipher;
-
-/**
- * In order to reuse that same interface for every passwords in TomEE, it has been moved
- * to another package. Just keeping that interface for compatibility reasons.
- *
- * @See org.apache.openejb.cipher.PasswordCipher
- */
-@Deprecated
-public interface PasswordCipher extends org.apache.openejb.cipher.PasswordCipher {
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc.cipher;
+
+/**
+ * In order to reuse that same interface for every passwords in TomEE, it has been moved
+ * to another package. Just keeping that interface for compatibility reasons.
+ *
+ * @See org.apache.openejb.cipher.PasswordCipher
+ */
+@Deprecated
+public interface PasswordCipher extends org.apache.openejb.cipher.PasswordCipher {
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PlainTextPasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PlainTextPasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PlainTextPasswordCipher.java
index df1fcea..6297a37 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PlainTextPasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/PlainTextPasswordCipher.java
@@ -1,22 +1,22 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc.cipher;
-
-@Deprecated
-public class PlainTextPasswordCipher extends org.apache.openejb.cipher.PlainTextPasswordCipher implements PasswordCipher {
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc.cipher;
+
+@Deprecated
+public class PlainTextPasswordCipher extends org.apache.openejb.cipher.PlainTextPasswordCipher implements PasswordCipher {
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/StaticDESPasswordCipher.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/StaticDESPasswordCipher.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/StaticDESPasswordCipher.java
index e62d00d..1a820c0 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/StaticDESPasswordCipher.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/cipher/StaticDESPasswordCipher.java
@@ -1,23 +1,23 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc.cipher;
-
-@Deprecated
-@SuppressWarnings("deprecation")
-public class StaticDESPasswordCipher extends org.apache.openejb.cipher.StaticDESPasswordCipher implements PasswordCipher {
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc.cipher;
+
+@Deprecated
+@SuppressWarnings("deprecation")
+public class StaticDESPasswordCipher extends org.apache.openejb.cipher.StaticDESPasswordCipher implements PasswordCipher {
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/AbstractRouter.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/AbstractRouter.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/AbstractRouter.java
index 425a10d..c904670 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/AbstractRouter.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/AbstractRouter.java
@@ -1,42 +1,42 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc.router;
-
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.spi.ContainerSystem;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-public abstract class AbstractRouter implements Router {
-    private static final String OPENEJB_RESOURCE = "openejb:Resource/";
-
-    private final Context ctx;
-
-    public AbstractRouter() {
-        ctx = SystemInstance.get().getComponent(ContainerSystem.class).getJNDIContext();
-    }
-
-    protected Object getJndiResource(final String name) throws NamingException {
-        return ctx.lookup(name);
-    }
-
-    protected Object getOpenEJBResource(final String name) throws NamingException {
-        return getJndiResource(OPENEJB_RESOURCE + name);
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc.router;
+
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.spi.ContainerSystem;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+
+public abstract class AbstractRouter implements Router {
+    private static final String OPENEJB_RESOURCE = "openejb:Resource/";
+
+    private final Context ctx;
+
+    public AbstractRouter() {
+        ctx = SystemInstance.get().getComponent(ContainerSystem.class).getJNDIContext();
+    }
+
+    protected Object getJndiResource(final String name) throws NamingException {
+        return ctx.lookup(name);
+    }
+
+    protected Object getOpenEJBResource(final String name) throws NamingException {
+        return getJndiResource(OPENEJB_RESOURCE + name);
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/Router.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/Router.java b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/Router.java
index ea00735..05e2683 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/Router.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/resource/jdbc/router/Router.java
@@ -1,37 +1,37 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.resource.jdbc.router;
-
-import org.apache.openejb.resource.jdbc.RoutedDataSource;
-
-import javax.sql.DataSource;
-
-/**
- * The Router interface is responsible for providing the target data source to the ${@link RoutedDataSource}}.
- * <p/>
- * $Rev:$
- */
-public interface Router {
-
-    /**
-     * Used by ${@link RoutedDataSource} to get the active data source.
-     *
-     * @return the data source to delegate to
-     */
-    DataSource getDataSource();
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.resource.jdbc.router;
+
+import org.apache.openejb.resource.jdbc.RoutedDataSource;
+
+import javax.sql.DataSource;
+
+/**
+ * The Router interface is responsible for providing the target data source to the ${@link RoutedDataSource}}.
+ * <p/>
+ * $Rev:$
+ */
+public interface Router {
+
+    /**
+     * Used by ${@link RoutedDataSource} to get the active data source.
+     *
+     * @return the data source to delegate to
+     */
+    DataSource getDataSource();
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/rest/ThreadLocalContextManager.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/rest/ThreadLocalContextManager.java b/container/openejb-core/src/main/java/org/apache/openejb/rest/ThreadLocalContextManager.java
index 5e41a0b..52b4265 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/rest/ThreadLocalContextManager.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/rest/ThreadLocalContextManager.java
@@ -1,96 +1,96 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.rest;
-
-import javax.servlet.ServletConfig;
-import javax.servlet.ServletContext;
-import javax.servlet.ServletRequest;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import javax.ws.rs.core.Application;
-import javax.ws.rs.core.HttpHeaders;
-import javax.ws.rs.core.Request;
-import javax.ws.rs.core.SecurityContext;
-import javax.ws.rs.core.UriInfo;
-import javax.ws.rs.ext.ContextResolver;
-import javax.ws.rs.ext.Providers;
-import java.util.Map;
-
-public class ThreadLocalContextManager {
-    public static final ThreadLocalRequest REQUEST = new ThreadLocalRequest();
-    public static final ThreadLocalServletConfig SERVLET_CONFIG = new ThreadLocalServletConfig();
-    public static final ThreadLocalServletContext SERVLET_CONTEXT = new ThreadLocalServletContext();
-    public static final ThreadLocalServletRequest SERVLET_REQUEST = new ThreadLocalServletRequest();
-    public static final ThreadLocalHttpServletRequest HTTP_SERVLET_REQUEST = new ThreadLocalHttpServletRequest();
-    public static final ThreadLocalHttpServletResponse HTTP_SERVLET_RESPONSE = new ThreadLocalHttpServletResponse();
-    public static final ThreadLocalUriInfo URI_INFO = new ThreadLocalUriInfo();
-    public static final ThreadLocalHttpHeaders HTTP_HEADERS = new ThreadLocalHttpHeaders();
-    public static final ThreadLocalSecurityContext SECURITY_CONTEXT = new ThreadLocalSecurityContext();
-    public static final ThreadLocalContextResolver CONTEXT_RESOLVER = new ThreadLocalContextResolver();
-    public static final ThreadLocalProviders PROVIDERS = new ThreadLocalProviders();
-    public static final ThreadLocal<Application> APPLICATION = new ThreadLocal<Application>();
-    public static final ThreadLocal<Map<String, Object>> OTHERS = new ThreadLocal<Map<String, Object>>();
-
-    public static void reset() {
-        REQUEST.remove();
-        SERVLET_REQUEST.remove();
-        SERVLET_CONFIG.remove();
-        SERVLET_CONTEXT.remove();
-        HTTP_SERVLET_REQUEST.remove();
-        HTTP_SERVLET_RESPONSE.remove();
-        URI_INFO.remove();
-        HTTP_HEADERS.remove();
-        SECURITY_CONTEXT.remove();
-        CONTEXT_RESOLVER.remove();
-        PROVIDERS.remove();
-        APPLICATION.remove();
-
-        final Map<String, Object> map = OTHERS.get();
-        if (map != null) {
-            map.clear();
-        }
-        OTHERS.remove();
-    }
-
-    public static Object findThreadLocal(final Class<?> type) {
-        if (Request.class.equals(type)) {
-            return ThreadLocalContextManager.REQUEST;
-        } else if (UriInfo.class.equals(type)) {
-            return ThreadLocalContextManager.URI_INFO;
-        } else if (HttpHeaders.class.equals(type)) {
-            return ThreadLocalContextManager.HTTP_HEADERS;
-        } else if (SecurityContext.class.equals(type)) {
-            return ThreadLocalContextManager.SECURITY_CONTEXT;
-        } else if (ContextResolver.class.equals(type)) {
-            return ThreadLocalContextManager.CONTEXT_RESOLVER;
-        } else if (Providers.class.equals(type)) {
-            return ThreadLocalContextManager.PROVIDERS;
-        } else if (ServletRequest.class.equals(type)) {
-            return ThreadLocalContextManager.SERVLET_REQUEST;
-        } else if (HttpServletRequest.class.equals(type)) {
-            return ThreadLocalContextManager.HTTP_SERVLET_REQUEST;
-        } else if (HttpServletResponse.class.equals(type)) {
-            return ThreadLocalContextManager.HTTP_SERVLET_RESPONSE;
-        } else if (ServletConfig.class.equals(type)) {
-            return ThreadLocalContextManager.SERVLET_CONFIG;
-        } else if (ServletContext.class.equals(type)) {
-            return ThreadLocalContextManager.SERVLET_CONTEXT;
-        }
-        return null;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.rest;
+
+import javax.servlet.ServletConfig;
+import javax.servlet.ServletContext;
+import javax.servlet.ServletRequest;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.ws.rs.core.Application;
+import javax.ws.rs.core.HttpHeaders;
+import javax.ws.rs.core.Request;
+import javax.ws.rs.core.SecurityContext;
+import javax.ws.rs.core.UriInfo;
+import javax.ws.rs.ext.ContextResolver;
+import javax.ws.rs.ext.Providers;
+import java.util.Map;
+
+public class ThreadLocalContextManager {
+    public static final ThreadLocalRequest REQUEST = new ThreadLocalRequest();
+    public static final ThreadLocalServletConfig SERVLET_CONFIG = new ThreadLocalServletConfig();
+    public static final ThreadLocalServletContext SERVLET_CONTEXT = new ThreadLocalServletContext();
+    public static final ThreadLocalServletRequest SERVLET_REQUEST = new ThreadLocalServletRequest();
+    public static final ThreadLocalHttpServletRequest HTTP_SERVLET_REQUEST = new ThreadLocalHttpServletRequest();
+    public static final ThreadLocalHttpServletResponse HTTP_SERVLET_RESPONSE = new ThreadLocalHttpServletResponse();
+    public static final ThreadLocalUriInfo URI_INFO = new ThreadLocalUriInfo();
+    public static final ThreadLocalHttpHeaders HTTP_HEADERS = new ThreadLocalHttpHeaders();
+    public static final ThreadLocalSecurityContext SECURITY_CONTEXT = new ThreadLocalSecurityContext();
+    public static final ThreadLocalContextResolver CONTEXT_RESOLVER = new ThreadLocalContextResolver();
+    public static final ThreadLocalProviders PROVIDERS = new ThreadLocalProviders();
+    public static final ThreadLocal<Application> APPLICATION = new ThreadLocal<Application>();
+    public static final ThreadLocal<Map<String, Object>> OTHERS = new ThreadLocal<Map<String, Object>>();
+
+    public static void reset() {
+        REQUEST.remove();
+        SERVLET_REQUEST.remove();
+        SERVLET_CONFIG.remove();
+        SERVLET_CONTEXT.remove();
+        HTTP_SERVLET_REQUEST.remove();
+        HTTP_SERVLET_RESPONSE.remove();
+        URI_INFO.remove();
+        HTTP_HEADERS.remove();
+        SECURITY_CONTEXT.remove();
+        CONTEXT_RESOLVER.remove();
+        PROVIDERS.remove();
+        APPLICATION.remove();
+
+        final Map<String, Object> map = OTHERS.get();
+        if (map != null) {
+            map.clear();
+        }
+        OTHERS.remove();
+    }
+
+    public static Object findThreadLocal(final Class<?> type) {
+        if (Request.class.equals(type)) {
+            return ThreadLocalContextManager.REQUEST;
+        } else if (UriInfo.class.equals(type)) {
+            return ThreadLocalContextManager.URI_INFO;
+        } else if (HttpHeaders.class.equals(type)) {
+            return ThreadLocalContextManager.HTTP_HEADERS;
+        } else if (SecurityContext.class.equals(type)) {
+            return ThreadLocalContextManager.SECURITY_CONTEXT;
+        } else if (ContextResolver.class.equals(type)) {
+            return ThreadLocalContextManager.CONTEXT_RESOLVER;
+        } else if (Providers.class.equals(type)) {
+            return ThreadLocalContextManager.PROVIDERS;
+        } else if (ServletRequest.class.equals(type)) {
+            return ThreadLocalContextManager.SERVLET_REQUEST;
+        } else if (HttpServletRequest.class.equals(type)) {
+            return ThreadLocalContextManager.HTTP_SERVLET_REQUEST;
+        } else if (HttpServletResponse.class.equals(type)) {
+            return ThreadLocalContextManager.HTTP_SERVLET_RESPONSE;
+        } else if (ServletConfig.class.equals(type)) {
+            return ThreadLocalContextManager.SERVLET_CONFIG;
+        } else if (ServletContext.class.equals(type)) {
+            return ThreadLocalContextManager.SERVLET_CONTEXT;
+        }
+        return null;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/testng/PropertiesBuilder.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/testng/PropertiesBuilder.java b/container/openejb-core/src/main/java/org/apache/openejb/testng/PropertiesBuilder.java
index c1db6b1..572e20d 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/testng/PropertiesBuilder.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/testng/PropertiesBuilder.java
@@ -1,47 +1,47 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.testng;
-
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Properties;
-
-public class PropertiesBuilder {
-    private final Properties properties = new Properties();
-
-    public PropertiesBuilder p(final String key, final String value) {
-        return property(key, value);
-    }
-
-    public PropertiesBuilder property(final String key, final String value) {
-        properties.setProperty(key, value);
-        return this;
-    }
-
-    public Properties build() {
-        return properties;
-    }
-
-    public Map<String, String> asMap() {
-        final Map<String, String> map = new HashMap<String, String>();
-        for (final Map.Entry<Object, Object> entry : properties.entrySet()) {
-            map.put(String.class.cast(entry.getKey()), String.class.cast(entry.getValue()));
-        }
-        return map;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.testng;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Properties;
+
+public class PropertiesBuilder {
+    private final Properties properties = new Properties();
+
+    public PropertiesBuilder p(final String key, final String value) {
+        return property(key, value);
+    }
+
+    public PropertiesBuilder property(final String key, final String value) {
+        properties.setProperty(key, value);
+        return this;
+    }
+
+    public Properties build() {
+        return properties;
+    }
+
+    public Map<String, String> asMap() {
+        final Map<String, String> map = new HashMap<String, String>();
+        for (final Map.Entry<Object, Object> entry : properties.entrySet()) {
+            map.put(String.class.cast(entry.getKey()), String.class.cast(entry.getValue()));
+        }
+        return map;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/util/CollectionsUtil.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/util/CollectionsUtil.java b/container/openejb-core/src/main/java/org/apache/openejb/util/CollectionsUtil.java
index 8ceff40..2daa42f 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/util/CollectionsUtil.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/util/CollectionsUtil.java
@@ -1,30 +1,30 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.util;
-
-import java.util.Collections;
-import java.util.List;
-
-public class CollectionsUtil {
-    public static <T> List<T> safe(final List<T> list) {
-        if (list == null) {
-            return Collections.emptyList();
-        }
-        return list;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.util;
+
+import java.util.Collections;
+import java.util.List;
+
+public class CollectionsUtil {
+    public static <T> List<T> safe(final List<T> list) {
+        if (list == null) {
+            return Collections.emptyList();
+        }
+        return list;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/main/java/org/apache/openejb/util/LogStreamAsync.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/util/LogStreamAsync.java b/container/openejb-core/src/main/java/org/apache/openejb/util/LogStreamAsync.java
index f514df8..eabd0c1 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/util/LogStreamAsync.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/util/LogStreamAsync.java
@@ -1,224 +1,224 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.util;
-
-import java.io.Closeable;
-import java.io.IOException;
-import java.util.concurrent.BlockingQueue;
-import java.util.concurrent.LinkedBlockingQueue;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-public class LogStreamAsync implements LogStream, Closeable {
-
-    private static final LinkedBlockingQueue<Message> log = new LinkedBlockingQueue<Message>();
-    private static final Thread t = new Thread(new Consumer(LogStreamAsync.log), "LogStreamAsync.Thread");
-    private static final AtomicBoolean started = new AtomicBoolean(false);
-    private final LogStream ls;
-
-    private enum level {
-        fatal,
-        error,
-        warn,
-        info,
-        debug,
-        quit,
-    }
-
-    public LogStreamAsync(final LogStream ls) {
-        this.ls = ls;
-
-        if (!started.getAndSet(true)) {
-            t.setDaemon(true);
-            t.start();
-        }
-    }
-
-    @Override
-    public void close() throws IOException {
-        LogStreamAsync.log.clear();
-        try {
-            LogStreamAsync.log.put(new Message(this.ls, level.quit, ""));
-        } catch (final InterruptedException e) {
-            //Ignore
-        }
-    }
-
-    @Override
-    public boolean isFatalEnabled() {
-        return ls.isFatalEnabled();
-    }
-
-    @Override
-    public void fatal(final String message) {
-        this.log(level.fatal, message);
-    }
-
-    @Override
-    public void fatal(final String message, final Throwable t) {
-        this.log(level.fatal, message, t);
-    }
-
-    @Override
-    public boolean isErrorEnabled() {
-        return ls.isErrorEnabled();
-    }
-
-    @Override
-    public void error(final String message) {
-        this.log(level.error, message);
-    }
-
-    @Override
-    public void error(final String message, final Throwable t) {
-        this.log(level.error, message, t);
-    }
-
-    @Override
-    public boolean isWarnEnabled() {
-        return ls.isWarnEnabled();
-    }
-
-    @Override
-    public void warn(final String message) {
-        this.log(level.warn, message);
-    }
-
-    @Override
-    public void warn(final String message, final Throwable t) {
-        this.log(level.warn, message, t);
-    }
-
-    @Override
-    public boolean isInfoEnabled() {
-        return ls.isInfoEnabled();
-    }
-
-    @Override
-    public void info(final String message) {
-        this.log(level.info, message, null);
-    }
-
-    @Override
-    public void info(final String message, final Throwable t) {
-        this.log(level.info, message, null);
-    }
-
-    @Override
-    public boolean isDebugEnabled() {
-        return ls.isDebugEnabled();
-    }
-
-    @Override
-    public void debug(final String message) {
-        this.log(level.debug, message);
-    }
-
-    @Override
-    public void debug(final String message, final Throwable t) {
-        this.log(level.debug, message, t);
-    }
-
-    public void log(final level l, final String s) {
-        this.log(l, s, null);
-    }
-
-    public void log(final level l, final String s, final Throwable t) {
-        try {
-            LogStreamAsync.log.put(new Message(this.ls, l, s, t));
-        } catch (final InterruptedException e) {
-            //Ignore
-        }
-    }
-
-    private static final class Message {
-
-        private final LogStream ls;
-        private final level l;
-        private final String s;
-        private final Throwable t;
-
-        private Message(final LogStream ls, final level l, final String s) {
-            this(ls, l, s, null);
-        }
-
-        private Message(final LogStream ls, final level l, final String s, final Throwable t) {
-            this.ls = ls;
-            this.l = l;
-            this.s = s;
-            this.t = t;
-        }
-    }
-
-    private static final class Consumer implements Runnable {
-
-        private final BlockingQueue<Message> queue;
-
-        private Consumer(final BlockingQueue<Message> queue) {
-            this.queue = queue;
-        }
-
-        public void run() {
-
-            try {
-                Message msg;
-                while (!level.quit.equals((msg = queue.take()).l)) {
-                    final Throwable t = msg.t;
-
-                    if (null != t) {
-                        switch (msg.l) {
-                            case fatal:
-                                msg.ls.fatal(msg.s, t);
-                                break;
-                            case error:
-                                msg.ls.error(msg.s, t);
-                                break;
-                            case warn:
-                                msg.ls.warn(msg.s, t);
-                                break;
-                            case info:
-                                msg.ls.info(msg.s, t);
-                                break;
-                            case debug:
-                                msg.ls.debug(msg.s, t);
-                                break;
-                        }
-                    } else {
-                        switch (msg.l) {
-                            case fatal:
-                                msg.ls.fatal(msg.s);
-                                break;
-                            case error:
-                                msg.ls.error(msg.s);
-                                break;
-                            case warn:
-                                msg.ls.warn(msg.s);
-                                break;
-                            case info:
-                                msg.ls.info(msg.s);
-                                break;
-                            case debug:
-                                msg.ls.debug(msg.s);
-                                break;
-                        }
-                    }
-                }
-            } catch (final InterruptedException e) {
-                //Exit
-            }
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.util;
+
+import java.io.Closeable;
+import java.io.IOException;
+import java.util.concurrent.BlockingQueue;
+import java.util.concurrent.LinkedBlockingQueue;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+public class LogStreamAsync implements LogStream, Closeable {
+
+    private static final LinkedBlockingQueue<Message> log = new LinkedBlockingQueue<Message>();
+    private static final Thread t = new Thread(new Consumer(LogStreamAsync.log), "LogStreamAsync.Thread");
+    private static final AtomicBoolean started = new AtomicBoolean(false);
+    private final LogStream ls;
+
+    private enum level {
+        fatal,
+        error,
+        warn,
+        info,
+        debug,
+        quit,
+    }
+
+    public LogStreamAsync(final LogStream ls) {
+        this.ls = ls;
+
+        if (!started.getAndSet(true)) {
+            t.setDaemon(true);
+            t.start();
+        }
+    }
+
+    @Override
+    public void close() throws IOException {
+        LogStreamAsync.log.clear();
+        try {
+            LogStreamAsync.log.put(new Message(this.ls, level.quit, ""));
+        } catch (final InterruptedException e) {
+            //Ignore
+        }
+    }
+
+    @Override
+    public boolean isFatalEnabled() {
+        return ls.isFatalEnabled();
+    }
+
+    @Override
+    public void fatal(final String message) {
+        this.log(level.fatal, message);
+    }
+
+    @Override
+    public void fatal(final String message, final Throwable t) {
+        this.log(level.fatal, message, t);
+    }
+
+    @Override
+    public boolean isErrorEnabled() {
+        return ls.isErrorEnabled();
+    }
+
+    @Override
+    public void error(final String message) {
+        this.log(level.error, message);
+    }
+
+    @Override
+    public void error(final String message, final Throwable t) {
+        this.log(level.error, message, t);
+    }
+
+    @Override
+    public boolean isWarnEnabled() {
+        return ls.isWarnEnabled();
+    }
+
+    @Override
+    public void warn(final String message) {
+        this.log(level.warn, message);
+    }
+
+    @Override
+    public void warn(final String message, final Throwable t) {
+        this.log(level.warn, message, t);
+    }
+
+    @Override
+    public boolean isInfoEnabled() {
+        return ls.isInfoEnabled();
+    }
+
+    @Override
+    public void info(final String message) {
+        this.log(level.info, message, null);
+    }
+
+    @Override
+    public void info(final String message, final Throwable t) {
+        this.log(level.info, message, null);
+    }
+
+    @Override
+    public boolean isDebugEnabled() {
+        return ls.isDebugEnabled();
+    }
+
+    @Override
+    public void debug(final String message) {
+        this.log(level.debug, message);
+    }
+
+    @Override
+    public void debug(final String message, final Throwable t) {
+        this.log(level.debug, message, t);
+    }
+
+    public void log(final level l, final String s) {
+        this.log(l, s, null);
+    }
+
+    public void log(final level l, final String s, final Throwable t) {
+        try {
+            LogStreamAsync.log.put(new Message(this.ls, l, s, t));
+        } catch (final InterruptedException e) {
+            //Ignore
+        }
+    }
+
+    private static final class Message {
+
+        private final LogStream ls;
+        private final level l;
+        private final String s;
+        private final Throwable t;
+
+        private Message(final LogStream ls, final level l, final String s) {
+            this(ls, l, s, null);
+        }
+
+        private Message(final LogStream ls, final level l, final String s, final Throwable t) {
+            this.ls = ls;
+            this.l = l;
+            this.s = s;
+            this.t = t;
+        }
+    }
+
+    private static final class Consumer implements Runnable {
+
+        private final BlockingQueue<Message> queue;
+
+        private Consumer(final BlockingQueue<Message> queue) {
+            this.queue = queue;
+        }
+
+        public void run() {
+
+            try {
+                Message msg;
+                while (!level.quit.equals((msg = queue.take()).l)) {
+                    final Throwable t = msg.t;
+
+                    if (null != t) {
+                        switch (msg.l) {
+                            case fatal:
+                                msg.ls.fatal(msg.s, t);
+                                break;
+                            case error:
+                                msg.ls.error(msg.s, t);
+                                break;
+                            case warn:
+                                msg.ls.warn(msg.s, t);
+                                break;
+                            case info:
+                                msg.ls.info(msg.s, t);
+                                break;
+                            case debug:
+                                msg.ls.debug(msg.s, t);
+                                break;
+                        }
+                    } else {
+                        switch (msg.l) {
+                            case fatal:
+                                msg.ls.fatal(msg.s);
+                                break;
+                            case error:
+                                msg.ls.error(msg.s);
+                                break;
+                            case warn:
+                                msg.ls.warn(msg.s);
+                                break;
+                            case info:
+                                msg.ls.info(msg.s);
+                                break;
+                            case debug:
+                                msg.ls.debug(msg.s);
+                                break;
+                        }
+                    }
+                }
+            } catch (final InterruptedException e) {
+                //Exit
+            }
+        }
+    }
+}


[07/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-pojo-openejb-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-pojo-openejb-jar.xml b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-pojo-openejb-jar.xml
index cd8fbb3..229900c 100644
--- a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-pojo-openejb-jar.xml
+++ b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-pojo-openejb-jar.xml
@@ -1,234 +1,234 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
-<openejb-jar xmlns="http://tomee.apache.org/xml/ns/openejb-jar-2.2"
-  xmlns:naming="http://geronimo.apache.org/xml/ns/naming-1.2"
- xmlns:sys="http://geronimo.apache.org/xml/ns/deployment-1.2">
-    <!--xmlns:pkgen="http://tomee.apache.org/xml/ns/pkgen-2.1"-->
-
-    <environment>
-        <moduleId>
-            <groupId>org.apache.openejb</groupId>
-            <artifactId>openejb-itests-core</artifactId>
-            <version>${openejbVersion}</version>
-            <type>car</type>
-        </moduleId>
-
-        <dependencies>
-          <dependency>
-              <groupId>org.apache.geronimo.configs</groupId>
-              <artifactId>j2ee-corba-yoko</artifactId>
-              <version>${version}</version>
-              <type>car</type>
-          </dependency>
-            <dependency>
-                <groupId>org.apache.geronimo.configs</groupId>
-                <artifactId>system-database</artifactId>
-                <version>${version}</version>
-                <type>car</type>
-            </dependency>
-            <dependency>
-                <groupId>junit</groupId>
-                <artifactId>junit</artifactId>
-            </dependency>
-        </dependencies>
-    </environment>
-
-    <cmp-connection-factory>
-        <resource-link>SystemDatasource</resource-link>
-    </cmp-connection-factory>
-
-    <enterprise-beans>
-        <session>
-            <ejb-name>BasicStatelessBean</ejb-name>
-            <jndi-name>client/tests/stateless/BasicStatelessHome</jndi-name>
-            <resource-ref>
-                <ref-name>stateless/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>BasicBMTStatelessBean</ejb-name>
-            <jndi-name>client/tests/stateless/BeanManagedBasicStatelessHome</jndi-name>
-            <resource-ref>
-                <ref-name>stateless/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>DatabaseBean</ejb-name>
-            <jndi-name>client/tools/DatabaseHome</jndi-name>
-            <resource-ref>
-                <ref-name>database</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>BMTStatelessBean</ejb-name>
-            <jndi-name>client/tests/stateless/BeanManagedTransactionTests/EJBHome</jndi-name>
-            <resource-ref>
-                <ref-name>database</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>EncStatelessBean</ejb-name>
-            <jndi-name>client/tests/stateless/EncBean</jndi-name>
-            <resource-ref>
-                <ref-name>datasource</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>StatelessRMIIIOPBean</ejb-name>
-            <jndi-name>client/tests/stateless/RMI-over-IIOP/EJBHome</jndi-name>
-        </session>
-        <session>
-            <ejb-name>BasicStatelessBean</ejb-name>
-            <jndi-name>client/tests/stateless/BasicStatelessHome</jndi-name>
-            <resource-ref>
-                <ref-name>stateless/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>SessionFacadeBean</ejb-name>
-            <jndi-name>client/tests/entity/cmp/SessionFacadeBean</jndi-name>
-        </session>
-        <session>
-            <ejb-name>BasicStatefulBean</ejb-name>
-            <jndi-name>client/tests/stateful/BasicStatefulHome</jndi-name>
-            <resource-ref>
-                <ref-name>stateful/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>BasicBMTStatefulBean</ejb-name>
-            <jndi-name>client/tests/stateful/BeanManagedBasicStatefulHome</jndi-name>
-            <resource-ref>
-                <ref-name>stateful/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>BMTStatefulBean</ejb-name>
-            <jndi-name>client/tests/stateful/BeanManagedTransactionTests/EJBHome</jndi-name>
-            <resource-ref>
-                <ref-name>datasource</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>EncStatefulBean</ejb-name>
-            <jndi-name>client/tests/stateful/EncBean</jndi-name>
-            <resource-ref>
-                <ref-name>datasource</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </session>
-        <session>
-            <ejb-name>StatefulRMIIIOPBean</ejb-name>
-            <jndi-name>client/tests/stateful/RMI-over-IIOP/EJBHome</jndi-name>
-        </session>
-        <entity>
-            <ejb-name>BasicBmpBean</ejb-name>
-            <jndi-name>client/tests/entity/bmp/BasicBmpHome</jndi-name>
-            <resource-ref>
-                <ref-name>jdbc/basic/entityDatabase</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </entity>
-        <entity>
-            <ejb-name>AOBasicBmpBean</ejb-name>
-            <jndi-name>client/tests/entity/bmp/allowed_operations/EntityHome</jndi-name>
-            <resource-ref>
-                <ref-name>jdbc/basic/entityDatabase</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-            <resource-ref>
-                <ref-name>entity/references/Resource_manager_access</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
+<openejb-jar xmlns="http://tomee.apache.org/xml/ns/openejb-jar-2.2"
+  xmlns:naming="http://geronimo.apache.org/xml/ns/naming-1.2"
+ xmlns:sys="http://geronimo.apache.org/xml/ns/deployment-1.2">
+    <!--xmlns:pkgen="http://tomee.apache.org/xml/ns/pkgen-2.1"-->
+
+    <environment>
+        <moduleId>
+            <groupId>org.apache.openejb</groupId>
+            <artifactId>openejb-itests-core</artifactId>
+            <version>${openejbVersion}</version>
+            <type>car</type>
+        </moduleId>
+
+        <dependencies>
+          <dependency>
+              <groupId>org.apache.geronimo.configs</groupId>
+              <artifactId>j2ee-corba-yoko</artifactId>
+              <version>${version}</version>
+              <type>car</type>
+          </dependency>
+            <dependency>
+                <groupId>org.apache.geronimo.configs</groupId>
+                <artifactId>system-database</artifactId>
+                <version>${version}</version>
+                <type>car</type>
+            </dependency>
+            <dependency>
+                <groupId>junit</groupId>
+                <artifactId>junit</artifactId>
+            </dependency>
+        </dependencies>
+    </environment>
+
+    <cmp-connection-factory>
+        <resource-link>SystemDatasource</resource-link>
+    </cmp-connection-factory>
+
+    <enterprise-beans>
+        <session>
+            <ejb-name>BasicStatelessBean</ejb-name>
+            <jndi-name>client/tests/stateless/BasicStatelessHome</jndi-name>
+            <resource-ref>
+                <ref-name>stateless/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>BasicBMTStatelessBean</ejb-name>
+            <jndi-name>client/tests/stateless/BeanManagedBasicStatelessHome</jndi-name>
+            <resource-ref>
+                <ref-name>stateless/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>DatabaseBean</ejb-name>
+            <jndi-name>client/tools/DatabaseHome</jndi-name>
+            <resource-ref>
+                <ref-name>database</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>BMTStatelessBean</ejb-name>
+            <jndi-name>client/tests/stateless/BeanManagedTransactionTests/EJBHome</jndi-name>
+            <resource-ref>
+                <ref-name>database</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>EncStatelessBean</ejb-name>
+            <jndi-name>client/tests/stateless/EncBean</jndi-name>
+            <resource-ref>
+                <ref-name>datasource</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>StatelessRMIIIOPBean</ejb-name>
+            <jndi-name>client/tests/stateless/RMI-over-IIOP/EJBHome</jndi-name>
+        </session>
+        <session>
+            <ejb-name>BasicStatelessBean</ejb-name>
+            <jndi-name>client/tests/stateless/BasicStatelessHome</jndi-name>
+            <resource-ref>
+                <ref-name>stateless/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>SessionFacadeBean</ejb-name>
+            <jndi-name>client/tests/entity/cmp/SessionFacadeBean</jndi-name>
+        </session>
+        <session>
+            <ejb-name>BasicStatefulBean</ejb-name>
+            <jndi-name>client/tests/stateful/BasicStatefulHome</jndi-name>
+            <resource-ref>
+                <ref-name>stateful/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>BasicBMTStatefulBean</ejb-name>
+            <jndi-name>client/tests/stateful/BeanManagedBasicStatefulHome</jndi-name>
+            <resource-ref>
+                <ref-name>stateful/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>BMTStatefulBean</ejb-name>
+            <jndi-name>client/tests/stateful/BeanManagedTransactionTests/EJBHome</jndi-name>
+            <resource-ref>
+                <ref-name>datasource</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>EncStatefulBean</ejb-name>
+            <jndi-name>client/tests/stateful/EncBean</jndi-name>
+            <resource-ref>
+                <ref-name>datasource</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </session>
+        <session>
+            <ejb-name>StatefulRMIIIOPBean</ejb-name>
+            <jndi-name>client/tests/stateful/RMI-over-IIOP/EJBHome</jndi-name>
+        </session>
+        <entity>
+            <ejb-name>BasicBmpBean</ejb-name>
+            <jndi-name>client/tests/entity/bmp/BasicBmpHome</jndi-name>
+            <resource-ref>
+                <ref-name>jdbc/basic/entityDatabase</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </entity>
+        <entity>
+            <ejb-name>AOBasicBmpBean</ejb-name>
+            <jndi-name>client/tests/entity/bmp/allowed_operations/EntityHome</jndi-name>
+            <resource-ref>
+                <ref-name>jdbc/basic/entityDatabase</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+            <resource-ref>
+                <ref-name>entity/references/Resource_manager_access</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
                     <name>SystemDatasource</name>
                 </pattern>
             </resource-ref>
@@ -291,38 +291,38 @@
                 </pattern>
             </resource-ref>
         </entity>
-        <entity>
-            <ejb-name>BasicCmp2PojoBean</ejb-name>
-            <jndi-name>client/tests/entity/cmp2/BasicCmpPojoHome</jndi-name>
-            <table-name>entity</table-name>
-            <cmp-field-mapping>
-                <cmp-field-name>id</cmp-field-name>
-                <table-column>id</table-column>
-            </cmp-field-mapping>
-            <cmp-field-mapping>
-                <cmp-field-name>firstName</cmp-field-name>
-                <table-column>first_name</table-column>
-            </cmp-field-mapping>
-            <cmp-field-mapping>
-                <cmp-field-name>lastName</cmp-field-name>
-                <table-column>last_name</table-column>
-            </cmp-field-mapping>
-            <key-generator>
-                <auto-increment-table>
-                    <sql>INSERT INTO entity (first_name) VALUES ('AUTO_GENERATED')</sql>
-                    <return-type>java.lang.Integer</return-type>
-                </auto-increment-table>
-            </key-generator>
-            <resource-ref>
-                <ref-name>jdbc/basic/entityDatabase</ref-name>
-                <pattern>
-                    <groupId>org.apache.geronimo.configs</groupId>
-                    <artifactId>system-database</artifactId>
-                    <version>${version}</version>
-                    <name>SystemDatasource</name>
-                </pattern>
-            </resource-ref>
-        </entity>
+        <entity>
+            <ejb-name>BasicCmp2PojoBean</ejb-name>
+            <jndi-name>client/tests/entity/cmp2/BasicCmpPojoHome</jndi-name>
+            <table-name>entity</table-name>
+            <cmp-field-mapping>
+                <cmp-field-name>id</cmp-field-name>
+                <table-column>id</table-column>
+            </cmp-field-mapping>
+            <cmp-field-mapping>
+                <cmp-field-name>firstName</cmp-field-name>
+                <table-column>first_name</table-column>
+            </cmp-field-mapping>
+            <cmp-field-mapping>
+                <cmp-field-name>lastName</cmp-field-name>
+                <table-column>last_name</table-column>
+            </cmp-field-mapping>
+            <key-generator>
+                <auto-increment-table>
+                    <sql>INSERT INTO entity (first_name) VALUES ('AUTO_GENERATED')</sql>
+                    <return-type>java.lang.Integer</return-type>
+                </auto-increment-table>
+            </key-generator>
+            <resource-ref>
+                <ref-name>jdbc/basic/entityDatabase</ref-name>
+                <pattern>
+                    <groupId>org.apache.geronimo.configs</groupId>
+                    <artifactId>system-database</artifactId>
+                    <version>${version}</version>
+                    <name>SystemDatasource</name>
+                </pattern>
+            </resource-ref>
+        </entity>
         <entity>
             <ejb-name>AOBasicCmp2Bean</ejb-name>
             <jndi-name>client/tests/entity/cmp2/allowed_operations/EntityHome</jndi-name>
@@ -821,4 +821,4 @@
     <gbean name="ORBConfigAdapter" class="org.apache.openejb.yoko.ORBConfigAdapterGBean"/>
 
 </openejb-jar>
-
+

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-cmp-mappings.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-cmp-mappings.xml b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-cmp-mappings.xml
index ceb9bd1..8926f7a 100644
--- a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-cmp-mappings.xml
+++ b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-cmp-mappings.xml
@@ -1,23 +1,23 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
+
 <!DOCTYPE sun-cmp-mappings PUBLIC "-//Sun Microsystems, Inc.//DTD Sun ONE Application Server 7.0 CMP 1.0//EN" "http://www.sun.com/software/sunone/appserver/dtds/sun-cmp-mapping_1_0.dtd">
 <sun-cmp-mappings>
     <sun-cmp-mapping>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml
index 10404cc..8c1876c 100644
--- a/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml
+++ b/container/openejb-core/src/test/resources/convert/oej2/cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml
@@ -1,22 +1,22 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-
-<!-- $Rev$ $Date$ -->
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev$ $Date$ -->
 
 <!DOCTYPE sun-ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Sun ONE Application Server 8.0 EJB 2.1//EN" "http://www.sun.com/software/sunone/appserver/dtds/sun-ejb-jar_2_1-0.dtd">
 <sun-ejb-jar>

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/CollectionTable.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/CollectionTable.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/CollectionTable.java
index f7ece7f..91c5605 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/CollectionTable.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/CollectionTable.java
@@ -1,193 +1,193 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlType;
-import java.util.ArrayList;
-import java.util.List;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface CollectionTable {
- * String name() default "";
- * String catalog() default "";
- * String schema() default "";
- * JoinColumn[] joinColumns() default {};
- * UniqueConstraint[] uniqueConstraints() default {};
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for collection-table complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="collection-table">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;element name="join-column" type="{http://java.sun.com/xml/ns/persistence/orm}join-column" maxOccurs="unbounded" minOccurs="0"/>
- *         &lt;element name="unique-constraint" type="{http://java.sun.com/xml/ns/persistence/orm}unique-constraint" maxOccurs="unbounded" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="catalog" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="schema" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "collection-table", propOrder = {
-    "joinColumn",
-    "uniqueConstraint"
-})
-public class CollectionTable {
-
-    @XmlElement(name = "join-column")
-    protected List<JoinColumn> joinColumn;
-    @XmlElement(name = "unique-constraint")
-    protected List<UniqueConstraint> uniqueConstraint;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected String catalog;
-    @XmlAttribute
-    protected String schema;
-
-    /**
-     * Gets the value of the joinColumn property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the joinColumn property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getJoinColumn().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link org.apache.openejb.jee.jpa.JoinColumn }
-     */
-    public List<JoinColumn> getJoinColumn() {
-        if (joinColumn == null) {
-            joinColumn = new ArrayList<JoinColumn>();
-        }
-        return this.joinColumn;
-    }
-
-    /**
-     * Gets the value of the uniqueConstraint property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the uniqueConstraint property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getUniqueConstraint().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link org.apache.openejb.jee.jpa.UniqueConstraint }
-     */
-    public List<UniqueConstraint> getUniqueConstraint() {
-        if (uniqueConstraint == null) {
-            uniqueConstraint = new ArrayList<UniqueConstraint>();
-        }
-        return this.uniqueConstraint;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the catalog property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getCatalog() {
-        return catalog;
-    }
-
-    /**
-     * Sets the value of the catalog property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setCatalog(final String value) {
-        this.catalog = value;
-    }
-
-    /**
-     * Gets the value of the schema property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getSchema() {
-        return schema;
-    }
-
-    /**
-     * Sets the value of the schema property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setSchema(final String value) {
-        this.schema = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface CollectionTable {
+ * String name() default "";
+ * String catalog() default "";
+ * String schema() default "";
+ * JoinColumn[] joinColumns() default {};
+ * UniqueConstraint[] uniqueConstraints() default {};
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for collection-table complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="collection-table">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;sequence>
+ *         &lt;element name="join-column" type="{http://java.sun.com/xml/ns/persistence/orm}join-column" maxOccurs="unbounded" minOccurs="0"/>
+ *         &lt;element name="unique-constraint" type="{http://java.sun.com/xml/ns/persistence/orm}unique-constraint" maxOccurs="unbounded" minOccurs="0"/>
+ *       &lt;/sequence>
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="catalog" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="schema" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "collection-table", propOrder = {
+    "joinColumn",
+    "uniqueConstraint"
+})
+public class CollectionTable {
+
+    @XmlElement(name = "join-column")
+    protected List<JoinColumn> joinColumn;
+    @XmlElement(name = "unique-constraint")
+    protected List<UniqueConstraint> uniqueConstraint;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected String catalog;
+    @XmlAttribute
+    protected String schema;
+
+    /**
+     * Gets the value of the joinColumn property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the joinColumn property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getJoinColumn().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link org.apache.openejb.jee.jpa.JoinColumn }
+     */
+    public List<JoinColumn> getJoinColumn() {
+        if (joinColumn == null) {
+            joinColumn = new ArrayList<JoinColumn>();
+        }
+        return this.joinColumn;
+    }
+
+    /**
+     * Gets the value of the uniqueConstraint property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the uniqueConstraint property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getUniqueConstraint().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link org.apache.openejb.jee.jpa.UniqueConstraint }
+     */
+    public List<UniqueConstraint> getUniqueConstraint() {
+        if (uniqueConstraint == null) {
+            uniqueConstraint = new ArrayList<UniqueConstraint>();
+        }
+        return this.uniqueConstraint;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the catalog property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getCatalog() {
+        return catalog;
+    }
+
+    /**
+     * Sets the value of the catalog property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setCatalog(final String value) {
+        this.catalog = value;
+    }
+
+    /**
+     * Gets the value of the schema property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getSchema() {
+        return schema;
+    }
+
+    /**
+     * Sets the value of the schema property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setSchema(final String value) {
+        this.schema = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/ElementCollection.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/ElementCollection.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/ElementCollection.java
index 79511da..6de7bca 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/ElementCollection.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/ElementCollection.java
@@ -1,577 +1,577 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlType;
-import java.util.ArrayList;
-import java.util.List;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface ElementCollection {
- * Class targetClass() default void.class;
- * FetchType fetch() default LAZY;
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for element-collection complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="element-collection">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;sequence>
- *         &lt;choice>
- *           &lt;element name="order-by" type="{http://java.sun.com/xml/ns/persistence/orm}order-by" minOccurs="0"/>
- *           &lt;element name="order-column" type="{http://java.sun.com/xml/ns/persistence/orm}order-column" minOccurs="0"/>
- *         &lt;/choice>
- *         &lt;choice>
- *           &lt;element name="map-key" type="{http://java.sun.com/xml/ns/persistence/orm}map-key" minOccurs="0"/>
- *           &lt;sequence>
- *             &lt;element name="map-key-class" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-class" minOccurs="0"/>
- *             &lt;choice>
- *               &lt;element name="map-key-temporal" type="{http://java.sun.com/xml/ns/persistence/orm}temporal" minOccurs="0"/>
- *               &lt;element name="map-key-enumerated" type="{http://java.sun.com/xml/ns/persistence/orm}enumerated" minOccurs="0"/>
- *               &lt;element name="map-key-attribute-override" type="{http://java.sun.com/xml/ns/persistence/orm}attribute-override" maxOccurs="unbounded" minOccurs="0"/>
- *             &lt;/choice>
- *             &lt;choice>
- *               &lt;element name="map-key-column" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-column" minOccurs="0"/>
- *               &lt;element name="map-key-join-column" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-join-column" maxOccurs="unbounded" minOccurs="0"/>
- *             &lt;/choice>
- *           &lt;/sequence>
- *         &lt;/choice>
- *         &lt;choice>
- *           &lt;sequence>
- *             &lt;element name="column" type="{http://java.sun.com/xml/ns/persistence/orm}column" minOccurs="0"/>
- *             &lt;choice>
- *               &lt;element name="temporal" type="{http://java.sun.com/xml/ns/persistence/orm}temporal" minOccurs="0"/>
- *               &lt;element name="enumerated" type="{http://java.sun.com/xml/ns/persistence/orm}enumerated" minOccurs="0"/>
- *               &lt;element name="lob" type="{http://java.sun.com/xml/ns/persistence/orm}lob" minOccurs="0"/>
- *             &lt;/choice>
- *           &lt;/sequence>
- *           &lt;sequence>
- *             &lt;element name="attribute-override" type="{http://java.sun.com/xml/ns/persistence/orm}attribute-override" maxOccurs="unbounded" minOccurs="0"/>
- *             &lt;element name="association-override" type="{http://java.sun.com/xml/ns/persistence/orm}association-override" maxOccurs="unbounded" minOccurs="0"/>
- *           &lt;/sequence>
- *         &lt;/choice>
- *         &lt;element name="collection-table" type="{http://java.sun.com/xml/ns/persistence/orm}collection-table" minOccurs="0"/>
- *       &lt;/sequence>
- *       &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="target-class" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="fetch" type="{http://java.sun.com/xml/ns/persistence/orm}fetch-type" />
- *       &lt;attribute name="access" type="{http://java.sun.com/xml/ns/persistence/orm}access-type" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "element-collection", propOrder = {
-    "orderBy",
-    "orderColumn",
-    "mapKey",
-    "mapKeyClass",
-    "mapKeyTemporal",
-    "mapKeyEnumerated",
-    "mapKeyAttributeOverride",
-    "mapKeyColumn",
-    "mapKeyJoinColumn",
-    "column",
-    "temporal",
-    "enumerated",
-    "lob",
-    "attributeOverride",
-    "associationOverride",
-    "collectionTable"
-})
-public class ElementCollection {
-
-    @XmlElement(name = "order-by")
-    protected String orderBy;
-    @XmlElement(name = "order-column")
-    protected OrderColumn orderColumn;
-    @XmlElement(name = "map-key")
-    protected MapKey mapKey;
-    @XmlElement(name = "map-key-class")
-    protected MapKeyClass mapKeyClass;
-    @XmlElement(name = "map-key-temporal")
-    protected TemporalType mapKeyTemporal;
-    @XmlElement(name = "map-key-enumerated")
-    protected EnumType mapKeyEnumerated;
-    @XmlElement(name = "map-key-attribute-override")
-    protected List<AttributeOverride> mapKeyAttributeOverride;
-    @XmlElement(name = "map-key-column")
-    protected MapKeyColumn mapKeyColumn;
-    @XmlElement(name = "map-key-join-column")
-    protected List<MapKeyJoinColumn> mapKeyJoinColumn;
-    protected Column column;
-    protected TemporalType temporal;
-    protected EnumType enumerated;
-    protected Lob lob;
-    @XmlElement(name = "attribute-override")
-    protected List<AttributeOverride> attributeOverride;
-    @XmlElement(name = "association-override")
-    protected List<AssociationOverride> associationOverride;
-    @XmlElement(name = "collection-table")
-    protected CollectionTable collectionTable;
-    @XmlAttribute(required = true)
-    protected String name;
-    @XmlAttribute(name = "target-class")
-    protected String targetClass;
-    @XmlAttribute
-    protected FetchType fetch;
-    @XmlAttribute
-    protected AccessType access;
-
-    /**
-     * Gets the value of the orderBy property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getOrderBy() {
-        return orderBy;
-    }
-
-    /**
-     * Sets the value of the orderBy property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setOrderBy(final String value) {
-        this.orderBy = value;
-    }
-
-    /**
-     * Gets the value of the orderColumn property.
-     *
-     * @return possible object is
-     * {@link OrderColumn }
-     */
-    public OrderColumn getOrderColumn() {
-        return orderColumn;
-    }
-
-    /**
-     * Sets the value of the orderColumn property.
-     *
-     * @param value allowed object is
-     *              {@link OrderColumn }
-     */
-    public void setOrderColumn(final OrderColumn value) {
-        this.orderColumn = value;
-    }
-
-    /**
-     * Gets the value of the mapKey property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.MapKey }
-     */
-    public MapKey getMapKey() {
-        return mapKey;
-    }
-
-    /**
-     * Sets the value of the mapKey property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.MapKey }
-     */
-    public void setMapKey(final MapKey value) {
-        this.mapKey = value;
-    }
-
-    /**
-     * Gets the value of the mapKeyClass property.
-     *
-     * @return possible object is
-     * {@link MapKeyClass }
-     */
-    public MapKeyClass getMapKeyClass() {
-        return mapKeyClass;
-    }
-
-    /**
-     * Sets the value of the mapKeyClass property.
-     *
-     * @param value allowed object is
-     *              {@link MapKeyClass }
-     */
-    public void setMapKeyClass(final MapKeyClass value) {
-        this.mapKeyClass = value;
-    }
-
-    /**
-     * Gets the value of the mapKeyTemporal property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.TemporalType }
-     */
-    public TemporalType getMapKeyTemporal() {
-        return mapKeyTemporal;
-    }
-
-    /**
-     * Sets the value of the mapKeyTemporal property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.TemporalType }
-     */
-    public void setMapKeyTemporal(final TemporalType value) {
-        this.mapKeyTemporal = value;
-    }
-
-    /**
-     * Gets the value of the mapKeyEnumerated property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.EnumType }
-     */
-    public EnumType getMapKeyEnumerated() {
-        return mapKeyEnumerated;
-    }
-
-    /**
-     * Sets the value of the mapKeyEnumerated property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.EnumType }
-     */
-    public void setMapKeyEnumerated(final EnumType value) {
-        this.mapKeyEnumerated = value;
-    }
-
-    /**
-     * Gets the value of the mapKeyAttributeOverride property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the mapKeyAttributeOverride property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getMapKeyAttributeOverride().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link org.apache.openejb.jee.jpa.AttributeOverride }
-     */
-    public List<AttributeOverride> getMapKeyAttributeOverride() {
-        if (mapKeyAttributeOverride == null) {
-            mapKeyAttributeOverride = new ArrayList<AttributeOverride>();
-        }
-        return this.mapKeyAttributeOverride;
-    }
-
-    /**
-     * Gets the value of the mapKeyColumn property.
-     *
-     * @return possible object is
-     * {@link MapKeyColumn }
-     */
-    public MapKeyColumn getMapKeyColumn() {
-        return mapKeyColumn;
-    }
-
-    /**
-     * Sets the value of the mapKeyColumn property.
-     *
-     * @param value allowed object is
-     *              {@link MapKeyColumn }
-     */
-    public void setMapKeyColumn(final MapKeyColumn value) {
-        this.mapKeyColumn = value;
-    }
-
-    /**
-     * Gets the value of the mapKeyJoinColumn property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the mapKeyJoinColumn property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getMapKeyJoinColumn().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link MapKeyJoinColumn }
-     */
-    public List<MapKeyJoinColumn> getMapKeyJoinColumn() {
-        if (mapKeyJoinColumn == null) {
-            mapKeyJoinColumn = new ArrayList<MapKeyJoinColumn>();
-        }
-        return this.mapKeyJoinColumn;
-    }
-
-    /**
-     * Gets the value of the column property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.Column }
-     */
-    public Column getColumn() {
-        return column;
-    }
-
-    /**
-     * Sets the value of the column property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.Column }
-     */
-    public void setColumn(final Column value) {
-        this.column = value;
-    }
-
-    /**
-     * Gets the value of the temporal property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.TemporalType }
-     */
-    public TemporalType getTemporal() {
-        return temporal;
-    }
-
-    /**
-     * Sets the value of the temporal property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.TemporalType }
-     */
-    public void setTemporal(final TemporalType value) {
-        this.temporal = value;
-    }
-
-    /**
-     * Gets the value of the enumerated property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.EnumType }
-     */
-    public EnumType getEnumerated() {
-        return enumerated;
-    }
-
-    /**
-     * Sets the value of the enumerated property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.EnumType }
-     */
-    public void setEnumerated(final EnumType value) {
-        this.enumerated = value;
-    }
-
-    /**
-     * Gets the value of the lob property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.Lob }
-     */
-    public Lob getLob() {
-        return lob;
-    }
-
-    /**
-     * Sets the value of the lob property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.Lob }
-     */
-    public void setLob(final Lob value) {
-        this.lob = value;
-    }
-
-    /**
-     * Gets the value of the attributeOverride property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the attributeOverride property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getAttributeOverride().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link org.apache.openejb.jee.jpa.AttributeOverride }
-     */
-    public List<AttributeOverride> getAttributeOverride() {
-        if (attributeOverride == null) {
-            attributeOverride = new ArrayList<AttributeOverride>();
-        }
-        return this.attributeOverride;
-    }
-
-    /**
-     * Gets the value of the associationOverride property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list,
-     * not a snapshot. Therefore any modification you make to the
-     * returned list will be present inside the JAXB object.
-     * This is why there is not a <CODE>set</CODE> method for the associationOverride property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <pre>
-     *    getAssociationOverride().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link org.apache.openejb.jee.jpa.AssociationOverride }
-     */
-    public List<AssociationOverride> getAssociationOverride() {
-        if (associationOverride == null) {
-            associationOverride = new ArrayList<AssociationOverride>();
-        }
-        return this.associationOverride;
-    }
-
-    /**
-     * Gets the value of the collectionTable property.
-     *
-     * @return possible object is
-     * {@link CollectionTable }
-     */
-    public CollectionTable getCollectionTable() {
-        return collectionTable;
-    }
-
-    /**
-     * Sets the value of the collectionTable property.
-     *
-     * @param value allowed object is
-     *              {@link CollectionTable }
-     */
-    public void setCollectionTable(final CollectionTable value) {
-        this.collectionTable = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the targetClass property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getTargetClass() {
-        return targetClass;
-    }
-
-    /**
-     * Sets the value of the targetClass property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setTargetClass(final String value) {
-        this.targetClass = value;
-    }
-
-    /**
-     * Gets the value of the fetch property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.FetchType }
-     */
-    public FetchType getFetch() {
-        return fetch;
-    }
-
-    /**
-     * Sets the value of the fetch property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.FetchType }
-     */
-    public void setFetch(final FetchType value) {
-        this.fetch = value;
-    }
-
-    /**
-     * Gets the value of the access property.
-     *
-     * @return possible object is
-     * {@link org.apache.openejb.jee.jpa.AccessType }
-     */
-    public AccessType getAccess() {
-        return access;
-    }
-
-    /**
-     * Sets the value of the access property.
-     *
-     * @param value allowed object is
-     *              {@link org.apache.openejb.jee.jpa.AccessType }
-     */
-    public void setAccess(final AccessType value) {
-        this.access = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import java.util.ArrayList;
+import java.util.List;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface ElementCollection {
+ * Class targetClass() default void.class;
+ * FetchType fetch() default LAZY;
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for element-collection complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="element-collection">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;sequence>
+ *         &lt;choice>
+ *           &lt;element name="order-by" type="{http://java.sun.com/xml/ns/persistence/orm}order-by" minOccurs="0"/>
+ *           &lt;element name="order-column" type="{http://java.sun.com/xml/ns/persistence/orm}order-column" minOccurs="0"/>
+ *         &lt;/choice>
+ *         &lt;choice>
+ *           &lt;element name="map-key" type="{http://java.sun.com/xml/ns/persistence/orm}map-key" minOccurs="0"/>
+ *           &lt;sequence>
+ *             &lt;element name="map-key-class" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-class" minOccurs="0"/>
+ *             &lt;choice>
+ *               &lt;element name="map-key-temporal" type="{http://java.sun.com/xml/ns/persistence/orm}temporal" minOccurs="0"/>
+ *               &lt;element name="map-key-enumerated" type="{http://java.sun.com/xml/ns/persistence/orm}enumerated" minOccurs="0"/>
+ *               &lt;element name="map-key-attribute-override" type="{http://java.sun.com/xml/ns/persistence/orm}attribute-override" maxOccurs="unbounded" minOccurs="0"/>
+ *             &lt;/choice>
+ *             &lt;choice>
+ *               &lt;element name="map-key-column" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-column" minOccurs="0"/>
+ *               &lt;element name="map-key-join-column" type="{http://java.sun.com/xml/ns/persistence/orm}map-key-join-column" maxOccurs="unbounded" minOccurs="0"/>
+ *             &lt;/choice>
+ *           &lt;/sequence>
+ *         &lt;/choice>
+ *         &lt;choice>
+ *           &lt;sequence>
+ *             &lt;element name="column" type="{http://java.sun.com/xml/ns/persistence/orm}column" minOccurs="0"/>
+ *             &lt;choice>
+ *               &lt;element name="temporal" type="{http://java.sun.com/xml/ns/persistence/orm}temporal" minOccurs="0"/>
+ *               &lt;element name="enumerated" type="{http://java.sun.com/xml/ns/persistence/orm}enumerated" minOccurs="0"/>
+ *               &lt;element name="lob" type="{http://java.sun.com/xml/ns/persistence/orm}lob" minOccurs="0"/>
+ *             &lt;/choice>
+ *           &lt;/sequence>
+ *           &lt;sequence>
+ *             &lt;element name="attribute-override" type="{http://java.sun.com/xml/ns/persistence/orm}attribute-override" maxOccurs="unbounded" minOccurs="0"/>
+ *             &lt;element name="association-override" type="{http://java.sun.com/xml/ns/persistence/orm}association-override" maxOccurs="unbounded" minOccurs="0"/>
+ *           &lt;/sequence>
+ *         &lt;/choice>
+ *         &lt;element name="collection-table" type="{http://java.sun.com/xml/ns/persistence/orm}collection-table" minOccurs="0"/>
+ *       &lt;/sequence>
+ *       &lt;attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="target-class" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="fetch" type="{http://java.sun.com/xml/ns/persistence/orm}fetch-type" />
+ *       &lt;attribute name="access" type="{http://java.sun.com/xml/ns/persistence/orm}access-type" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "element-collection", propOrder = {
+    "orderBy",
+    "orderColumn",
+    "mapKey",
+    "mapKeyClass",
+    "mapKeyTemporal",
+    "mapKeyEnumerated",
+    "mapKeyAttributeOverride",
+    "mapKeyColumn",
+    "mapKeyJoinColumn",
+    "column",
+    "temporal",
+    "enumerated",
+    "lob",
+    "attributeOverride",
+    "associationOverride",
+    "collectionTable"
+})
+public class ElementCollection {
+
+    @XmlElement(name = "order-by")
+    protected String orderBy;
+    @XmlElement(name = "order-column")
+    protected OrderColumn orderColumn;
+    @XmlElement(name = "map-key")
+    protected MapKey mapKey;
+    @XmlElement(name = "map-key-class")
+    protected MapKeyClass mapKeyClass;
+    @XmlElement(name = "map-key-temporal")
+    protected TemporalType mapKeyTemporal;
+    @XmlElement(name = "map-key-enumerated")
+    protected EnumType mapKeyEnumerated;
+    @XmlElement(name = "map-key-attribute-override")
+    protected List<AttributeOverride> mapKeyAttributeOverride;
+    @XmlElement(name = "map-key-column")
+    protected MapKeyColumn mapKeyColumn;
+    @XmlElement(name = "map-key-join-column")
+    protected List<MapKeyJoinColumn> mapKeyJoinColumn;
+    protected Column column;
+    protected TemporalType temporal;
+    protected EnumType enumerated;
+    protected Lob lob;
+    @XmlElement(name = "attribute-override")
+    protected List<AttributeOverride> attributeOverride;
+    @XmlElement(name = "association-override")
+    protected List<AssociationOverride> associationOverride;
+    @XmlElement(name = "collection-table")
+    protected CollectionTable collectionTable;
+    @XmlAttribute(required = true)
+    protected String name;
+    @XmlAttribute(name = "target-class")
+    protected String targetClass;
+    @XmlAttribute
+    protected FetchType fetch;
+    @XmlAttribute
+    protected AccessType access;
+
+    /**
+     * Gets the value of the orderBy property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getOrderBy() {
+        return orderBy;
+    }
+
+    /**
+     * Sets the value of the orderBy property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setOrderBy(final String value) {
+        this.orderBy = value;
+    }
+
+    /**
+     * Gets the value of the orderColumn property.
+     *
+     * @return possible object is
+     * {@link OrderColumn }
+     */
+    public OrderColumn getOrderColumn() {
+        return orderColumn;
+    }
+
+    /**
+     * Sets the value of the orderColumn property.
+     *
+     * @param value allowed object is
+     *              {@link OrderColumn }
+     */
+    public void setOrderColumn(final OrderColumn value) {
+        this.orderColumn = value;
+    }
+
+    /**
+     * Gets the value of the mapKey property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.MapKey }
+     */
+    public MapKey getMapKey() {
+        return mapKey;
+    }
+
+    /**
+     * Sets the value of the mapKey property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.MapKey }
+     */
+    public void setMapKey(final MapKey value) {
+        this.mapKey = value;
+    }
+
+    /**
+     * Gets the value of the mapKeyClass property.
+     *
+     * @return possible object is
+     * {@link MapKeyClass }
+     */
+    public MapKeyClass getMapKeyClass() {
+        return mapKeyClass;
+    }
+
+    /**
+     * Sets the value of the mapKeyClass property.
+     *
+     * @param value allowed object is
+     *              {@link MapKeyClass }
+     */
+    public void setMapKeyClass(final MapKeyClass value) {
+        this.mapKeyClass = value;
+    }
+
+    /**
+     * Gets the value of the mapKeyTemporal property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.TemporalType }
+     */
+    public TemporalType getMapKeyTemporal() {
+        return mapKeyTemporal;
+    }
+
+    /**
+     * Sets the value of the mapKeyTemporal property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.TemporalType }
+     */
+    public void setMapKeyTemporal(final TemporalType value) {
+        this.mapKeyTemporal = value;
+    }
+
+    /**
+     * Gets the value of the mapKeyEnumerated property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.EnumType }
+     */
+    public EnumType getMapKeyEnumerated() {
+        return mapKeyEnumerated;
+    }
+
+    /**
+     * Sets the value of the mapKeyEnumerated property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.EnumType }
+     */
+    public void setMapKeyEnumerated(final EnumType value) {
+        this.mapKeyEnumerated = value;
+    }
+
+    /**
+     * Gets the value of the mapKeyAttributeOverride property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the mapKeyAttributeOverride property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getMapKeyAttributeOverride().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link org.apache.openejb.jee.jpa.AttributeOverride }
+     */
+    public List<AttributeOverride> getMapKeyAttributeOverride() {
+        if (mapKeyAttributeOverride == null) {
+            mapKeyAttributeOverride = new ArrayList<AttributeOverride>();
+        }
+        return this.mapKeyAttributeOverride;
+    }
+
+    /**
+     * Gets the value of the mapKeyColumn property.
+     *
+     * @return possible object is
+     * {@link MapKeyColumn }
+     */
+    public MapKeyColumn getMapKeyColumn() {
+        return mapKeyColumn;
+    }
+
+    /**
+     * Sets the value of the mapKeyColumn property.
+     *
+     * @param value allowed object is
+     *              {@link MapKeyColumn }
+     */
+    public void setMapKeyColumn(final MapKeyColumn value) {
+        this.mapKeyColumn = value;
+    }
+
+    /**
+     * Gets the value of the mapKeyJoinColumn property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the mapKeyJoinColumn property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getMapKeyJoinColumn().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link MapKeyJoinColumn }
+     */
+    public List<MapKeyJoinColumn> getMapKeyJoinColumn() {
+        if (mapKeyJoinColumn == null) {
+            mapKeyJoinColumn = new ArrayList<MapKeyJoinColumn>();
+        }
+        return this.mapKeyJoinColumn;
+    }
+
+    /**
+     * Gets the value of the column property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.Column }
+     */
+    public Column getColumn() {
+        return column;
+    }
+
+    /**
+     * Sets the value of the column property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.Column }
+     */
+    public void setColumn(final Column value) {
+        this.column = value;
+    }
+
+    /**
+     * Gets the value of the temporal property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.TemporalType }
+     */
+    public TemporalType getTemporal() {
+        return temporal;
+    }
+
+    /**
+     * Sets the value of the temporal property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.TemporalType }
+     */
+    public void setTemporal(final TemporalType value) {
+        this.temporal = value;
+    }
+
+    /**
+     * Gets the value of the enumerated property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.EnumType }
+     */
+    public EnumType getEnumerated() {
+        return enumerated;
+    }
+
+    /**
+     * Sets the value of the enumerated property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.EnumType }
+     */
+    public void setEnumerated(final EnumType value) {
+        this.enumerated = value;
+    }
+
+    /**
+     * Gets the value of the lob property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.Lob }
+     */
+    public Lob getLob() {
+        return lob;
+    }
+
+    /**
+     * Sets the value of the lob property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.Lob }
+     */
+    public void setLob(final Lob value) {
+        this.lob = value;
+    }
+
+    /**
+     * Gets the value of the attributeOverride property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the attributeOverride property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getAttributeOverride().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link org.apache.openejb.jee.jpa.AttributeOverride }
+     */
+    public List<AttributeOverride> getAttributeOverride() {
+        if (attributeOverride == null) {
+            attributeOverride = new ArrayList<AttributeOverride>();
+        }
+        return this.attributeOverride;
+    }
+
+    /**
+     * Gets the value of the associationOverride property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list,
+     * not a snapshot. Therefore any modification you make to the
+     * returned list will be present inside the JAXB object.
+     * This is why there is not a <CODE>set</CODE> method for the associationOverride property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <pre>
+     *    getAssociationOverride().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link org.apache.openejb.jee.jpa.AssociationOverride }
+     */
+    public List<AssociationOverride> getAssociationOverride() {
+        if (associationOverride == null) {
+            associationOverride = new ArrayList<AssociationOverride>();
+        }
+        return this.associationOverride;
+    }
+
+    /**
+     * Gets the value of the collectionTable property.
+     *
+     * @return possible object is
+     * {@link CollectionTable }
+     */
+    public CollectionTable getCollectionTable() {
+        return collectionTable;
+    }
+
+    /**
+     * Sets the value of the collectionTable property.
+     *
+     * @param value allowed object is
+     *              {@link CollectionTable }
+     */
+    public void setCollectionTable(final CollectionTable value) {
+        this.collectionTable = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the targetClass property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getTargetClass() {
+        return targetClass;
+    }
+
+    /**
+     * Sets the value of the targetClass property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setTargetClass(final String value) {
+        this.targetClass = value;
+    }
+
+    /**
+     * Gets the value of the fetch property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.FetchType }
+     */
+    public FetchType getFetch() {
+        return fetch;
+    }
+
+    /**
+     * Sets the value of the fetch property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.FetchType }
+     */
+    public void setFetch(final FetchType value) {
+        this.fetch = value;
+    }
+
+    /**
+     * Gets the value of the access property.
+     *
+     * @return possible object is
+     * {@link org.apache.openejb.jee.jpa.AccessType }
+     */
+    public AccessType getAccess() {
+        return access;
+    }
+
+    /**
+     * Sets the value of the access property.
+     *
+     * @param value allowed object is
+     *              {@link org.apache.openejb.jee.jpa.AccessType }
+     */
+    public void setAccess(final AccessType value) {
+        this.access = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/LockModeType.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/LockModeType.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/LockModeType.java
index 995479e..292089e 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/LockModeType.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/LockModeType.java
@@ -1,65 +1,65 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlType;
-
-
-/**
- * <p>Java class for lock-mode-type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;simpleType name="lock-mode-type">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}token">
- *     &lt;enumeration value="READ"/>
- *     &lt;enumeration value="WRITE"/>
- *     &lt;enumeration value="OPTIMISTIC"/>
- *     &lt;enumeration value="OPTIMISTIC_FORCE_INCREMENT"/>
- *     &lt;enumeration value="PESSIMISTIC_READ"/>
- *     &lt;enumeration value="PESSIMISTIC_WRITE"/>
- *     &lt;enumeration value="PESSIMISTIC_FORCE_INCREMENT"/>
- *     &lt;enumeration value="NONE"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlType(name = "lock-mode-type")
-@XmlEnum
-public enum LockModeType {
-
-    READ,
-    WRITE,
-    OPTIMISTIC,
-    OPTIMISTIC_FORCE_INCREMENT,
-    PESSIMISTIC_READ,
-    PESSIMISTIC_WRITE,
-    PESSIMISTIC_FORCE_INCREMENT,
-    NONE;
-
-    public String value() {
-        return name();
-    }
-
-    public static LockModeType fromValue(final String v) {
-        return valueOf(v);
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for lock-mode-type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="lock-mode-type">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}token">
+ *     &lt;enumeration value="READ"/>
+ *     &lt;enumeration value="WRITE"/>
+ *     &lt;enumeration value="OPTIMISTIC"/>
+ *     &lt;enumeration value="OPTIMISTIC_FORCE_INCREMENT"/>
+ *     &lt;enumeration value="PESSIMISTIC_READ"/>
+ *     &lt;enumeration value="PESSIMISTIC_WRITE"/>
+ *     &lt;enumeration value="PESSIMISTIC_FORCE_INCREMENT"/>
+ *     &lt;enumeration value="NONE"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlType(name = "lock-mode-type")
+@XmlEnum
+public enum LockModeType {
+
+    READ,
+    WRITE,
+    OPTIMISTIC,
+    OPTIMISTIC_FORCE_INCREMENT,
+    PESSIMISTIC_READ,
+    PESSIMISTIC_WRITE,
+    PESSIMISTIC_FORCE_INCREMENT,
+    NONE;
+
+    public String value() {
+        return name();
+    }
+
+    public static LockModeType fromValue(final String v) {
+        return valueOf(v);
+    }
+
+}


[18/18] tomee git commit: EOL

Posted by an...@apache.org.
EOL


Project: http://git-wip-us.apache.org/repos/asf/tomee/repo
Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/48c99a5a
Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/48c99a5a
Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/48c99a5a

Branch: refs/heads/tomee-1.7.x
Commit: 48c99a5a59d04352147d3225e660a8f99e66e708
Parents: c600442
Author: AndyGee <an...@gmx.de>
Authored: Wed Dec 9 17:36:42 2015 +0100
Committer: AndyGee <an...@gmx.de>
Committed: Wed Dec 9 17:36:42 2015 +0100

----------------------------------------------------------------------
 LIBRARIES                                       |  194 +-
 .../embedded/MultipleDeploymentsTest.java       |  164 +-
 .../arquillian/remote/RemoteTomEEContainer.java |  714 ++++----
 .../conf/Catalina/localhost/ROOT.xml            |   82 +-
 .../conf/Catalina/localhost/ROOT.xml            |   82 +-
 .../arquillian/tests/jms/DummyManagedBean.java  |  112 +-
 .../arquillian/tests/jms/JMSInjectionTest.java  |  158 +-
 .../tests/jsf/jpa/DummyManagedBean.java         |   88 +-
 .../tests/jsf/jpa/JPAInjectionTest.java         |  154 +-
 .../arquillian/webapp/TomEEWebappContainer.java |  494 ++---
 assembly/openejb-standalone/README.html         |   42 +-
 .../src/main/assembly/component.xml             |   42 +-
 .../src/main/assembly/dos.xml                   |  250 +--
 .../src/main/assembly/unix.xml                  |  246 +--
 .../src/main/resources/Start.bat                |   66 +-
 .../src/main/resources/Stop.bat                 |   66 +-
 .../main/resources/service.install.as.admin.bat |  300 +--
 .../main/resources/service.remove.as.admin.bat  |   96 +-
 .../classic/EntityManagerFactoryCallable.java   |  202 +--
 .../bval/BeanValidationAppendixInterceptor.java |  410 ++---
 .../apache/openejb/cdi/OpenEJBLifecycle.java    |  838 ++++-----
 .../apache/openejb/cipher/PasswordCipher.java   |  102 +-
 .../openejb/cipher/PlainTextPasswordCipher.java |  108 +-
 .../openejb/cipher/StaticDESPasswordCipher.java |  194 +-
 .../apache/openejb/classloader/FalseFilter.java |   58 +-
 .../openejb/config/DeploymentFilterable.java    |   66 +-
 .../org/apache/openejb/config/RemoteServer.java | 1428 +++++++--------
 .../openejb/config/rules/CheckAnnotations.java  |  190 +-
 .../rules/CheckIncorrectPropertyNames.java      |  168 +-
 .../injection/FallbackPropertyInjector.java     |   48 +-
 .../openejb/persistence/QueryOperation.java     |   48 +-
 .../resource/activemq/ActiveMQFactory.java      |  308 ++--
 .../openejb/resource/jdbc/RoutedDataSource.java |  258 +--
 .../resource/jdbc/cipher/PasswordCipher.java    |   58 +-
 .../jdbc/cipher/PlainTextPasswordCipher.java    |   44 +-
 .../jdbc/cipher/StaticDESPasswordCipher.java    |   46 +-
 .../resource/jdbc/router/AbstractRouter.java    |   84 +-
 .../openejb/resource/jdbc/router/Router.java    |   74 +-
 .../openejb/rest/ThreadLocalContextManager.java |  192 +-
 .../openejb/testng/PropertiesBuilder.java       |   94 +-
 .../apache/openejb/util/CollectionsUtil.java    |   60 +-
 .../org/apache/openejb/util/LogStreamAsync.java |  448 ++---
 .../org/apache/openejb/util/NetworkUtil.java    |  868 ++++-----
 .../org/apache/openejb/util/Slf4jLogStream.java |  218 +--
 .../openejb/util/Slf4jLogStreamFactory.java     |   80 +-
 .../src/main/resources/META-INF/ejb-jar.xml     |   40 +-
 .../src/main/resources/META-INF/openejb-jar.xml |   52 +-
 .../org.apache.openejb.cli/validate.examples    |  102 +-
 .../main/resources/openejb-version.properties   |   42 +-
 .../openejb/config/rules/Messages_hi.properties | 1712 +++++++++---------
 .../PersistenceUnitLinkResolverTest.java        |   88 +-
 .../openejb/activemq/KahaDBSupportTest.java     |   88 +-
 .../openejb/assembler/DeployerEjbTest.java      |  566 +++---
 .../BeanValidationAppendixInterceptorTest.java  |  408 ++---
 .../openejb/config/AnnotationDeployerTest.java  | 1100 +++++------
 .../config/rules/CheckAnnotationTest.java       |  174 +-
 .../config/rules/CheckCdiEnabledTest.java       |   86 +-
 .../config/rules/CheckDependsOnTest.java        |  152 +-
 .../rules/CheckIncorrectPropertyNameTest.java   |   98 +-
 .../config/rules/CheckMissingClassTest.java     |  368 ++--
 .../config/rules/CheckNoBusinessMethodTest.java |  396 ++--
 .../config/rules/CheckNoCreateMethodsTest.java  |  560 +++---
 .../rules/CheckPersistenceContextUsageTest.java |  198 +-
 .../rules/CheckPersistenceUnitUsageTest.java    |  192 +-
 .../config/rules/CheckWrongClassTypeTest.java   |   82 +-
 .../openejb/config/rules/InvokeMethod.java      |  402 ++--
 .../org/apache/openejb/config/rules/Key.java    |   64 +-
 .../org/apache/openejb/config/rules/Keys.java   |   62 +-
 .../rules/MistakenResourceRefUsageTest.java     |  110 +-
 .../openejb/config/rules/ValidationRunner.java  |  176 +-
 .../PermitAllWithDenyAllOnClassTest.java        |  176 +-
 .../org/apache/openejb/jpa/JTAPuAndBmtTest.java |  308 ++--
 .../apache/openejb/junit/PreDestroyTest.java    |  164 +-
 .../openejb/resource/URLAsResourceTest.java     |  142 +-
 .../resource/jdbc/DynamicDataSourceTest.java    |  658 +++----
 .../jdbc/driver/AlternateDriverJarTest.java     |  260 +--
 .../apache/openejb/test/annotated/Green.java    |   66 +-
 .../org/apache/openejb/test/annotated/Red.java  |   64 +-
 .../apache/openejb/test/annotated/Yellow.java   |   80 +-
 .../openejb/util/BeanTypeComparisonTest.java    |   70 +-
 .../openejb/util/CollectionsUtilTest.java       |   68 +-
 .../apache/openejb/util/NetworkUtilTest.java    |  264 +--
 .../resources/META-INF/jpa-test-mappings.xml    |   42 +-
 .../resources/META-INF/org.acme/service-jar.xml |   42 +-
 .../META-INF/org.router/service-jar.xml         |   56 +-
 .../cmp/itest-2.2/itest-2.2-openejb-jar.xml     |   40 +-
 .../itest-2.2/itest-2.2-pojo-openejb-jar.xml    |  528 +++---
 .../itest-2.2/itest-2.2-sun-cmp-mappings.xml    |   40 +-
 .../cmp/itest-2.2/itest-2.2-sun-ejb-jar.xml     |   38 +-
 .../apache/openejb/jee/jpa/CollectionTable.java |  386 ++--
 .../openejb/jee/jpa/ElementCollection.java      | 1154 ++++++------
 .../apache/openejb/jee/jpa/LockModeType.java    |  130 +-
 .../org/apache/openejb/jee/jpa/MapKeyClass.java |  150 +-
 .../apache/openejb/jee/jpa/MapKeyColumn.java    |  582 +++---
 .../openejb/jee/jpa/MapKeyJoinColumn.java       |  486 ++---
 .../org/apache/openejb/jee/jpa/OrderColumn.java |  342 ++--
 .../common/CompatibilityDescriptionGroup.java   |  260 +--
 .../openejb/jee/was/v6/common/Description.java  |  586 +++---
 .../jee/was/v6/common/DescriptionGroup.java     |  680 +++----
 .../openejb/jee/was/v6/common/DisplayName.java  |  600 +++---
 .../openejb/jee/was/v6/common/EJBLocalRef.java  |  198 +-
 .../openejb/jee/was/v6/common/EjbRef.java       |  816 ++++-----
 .../openejb/jee/was/v6/common/EjbRefEnum.java   |  130 +-
 .../openejb/jee/was/v6/common/EnvEntry.java     |  728 ++++----
 .../openejb/jee/was/v6/common/EnvEntryEnum.java |  158 +-
 .../openejb/jee/was/v6/common/IconType.java     |  618 +++----
 .../openejb/jee/was/v6/common/Identity.java     |  638 +++----
 .../jee/was/v6/common/JNDIEnvRefsGroup.java     |  558 +++---
 .../openejb/jee/was/v6/common/Listener.java     |  222 +--
 .../jee/was/v6/common/MessageDestination.java   |  184 +-
 .../was/v6/common/MessageDestinationRef.java    |  786 ++++----
 .../v6/common/MessageDestinationUsageEnum.java  |  136 +-
 .../jee/was/v6/common/ObjectFactory.java        |  950 +++++-----
 .../openejb/jee/was/v6/common/ParamValue.java   |  678 +++----
 .../apache/openejb/jee/was/v6/common/QName.java |  642 +++----
 .../openejb/jee/was/v6/common/ResAuthEnum.java  |  132 +-
 .../jee/was/v6/common/ResSharingScopeEnum.java  |  130 +-
 .../jee/was/v6/common/ResourceEnvRef.java       |  792 ++++----
 .../openejb/jee/was/v6/common/ResourceRef.java  |  834 ++++-----
 .../was/v6/common/RunAsSpecifiedIdentity.java   |  172 +-
 120 files changed, 17662 insertions(+), 17662 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/LIBRARIES
----------------------------------------------------------------------
diff --git a/LIBRARIES b/LIBRARIES
index 331ad82..4e0a839 100644
--- a/LIBRARIES
+++ b/LIBRARIES
@@ -1,98 +1,98 @@
-apache-tomee 1.7.0 webprofile
-
-  D gson-2.1.jar [180.11 ko]
-  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
-  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
-  D xbean-asm4-shaded-3.15.jar [128.36 ko]
-  A FastInfoset-1.2.12.jar [293.86 ko]
-  A el-api.jar [55.43 ko]
-  A istack-commons-runtime-2.16.jar [23.19 ko]
-  A jaxb-core-2.2.7.jar [221.75 ko]
-  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
-  A xbean-asm5-shaded-3.18.jar [144.47 ko]
-
-  change: +0.81 MB
-  total : 29.85 MB
-
-
-apache-tomee 1.7.0 jaxrs
-
-  D gson-2.1.jar [180.11 ko]
-  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
-  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
-  D xbean-asm4-shaded-3.15.jar [128.36 ko]
-  A FastInfoset-1.2.12.jar [293.86 ko]
-  A cxf-rt-management-2.6.14.jar [67.43 ko]
-  A el-api.jar [55.43 ko]
-  A istack-commons-runtime-2.16.jar [23.19 ko]
-  A jaxb-core-2.2.7.jar [221.75 ko]
-  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
-  A xbean-asm5-shaded-3.18.jar [144.47 ko]
-
-  change: +0.88 MB
-  total : 33.14 MB
-
-
-apache-tomee 1.7.0 plus
-
-  D gson-2.1.jar [180.11 ko]
-  D serializer-2.7.1.jar [278.28 ko]
-  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
-  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
-  D xalan-2.7.1.jar [3176.15 ko]
-  D xbean-asm4-shaded-3.15.jar [128.36 ko]
-  D xercesImpl-2.11.0.jar [1367.76 ko]
-  D xml-apis-1.4.01.jar [220.54 ko]
-  A FastInfoset-1.2.12.jar [293.86 ko]
-  A cxf-rt-management-2.6.14.jar [67.43 ko]
-  A el-api.jar [55.43 ko]
-  A istack-commons-runtime-2.16.jar [23.19 ko]
-  A jaxb-core-2.2.7.jar [221.75 ko]
-  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
-  A xbean-asm5-shaded-3.18.jar [144.47 ko]
-
-  change: -3.44 MB
-  total : 41.98 MB
-
-apache-tomee 1.7.0 plume
-
-  D gson-2.1.jar [180.11 ko]
-  D myfaces-api-2.1.13.jar [1190.07 ko]
-  D myfaces-impl-2.1.13.jar [2041.05 ko]
-  D serializer-2.7.1.jar [278.28 ko]
-  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
-  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
-  D tomee-myfaces-1.6.0.2.jar [30.38 ko]
-  D xalan-2.7.1.jar [3176.15 ko]
-  D xbean-asm4-shaded-3.15.jar [128.36 ko]
-  D xercesImpl-2.11.0.jar [1367.76 ko]
-  A FastInfoset-1.2.12.jar [293.86 ko]
-  A commonj.sdo-2.1.1.jar [21.01 ko]
-  A cxf-rt-management-2.6.14.jar [67.43 ko]
-  A eclipselink-2.4.2.jar [8650.47 ko]
-  A el-api.jar [55.43 ko]
-  A istack-commons-runtime-2.16.jar [23.19 ko]
-  A javax.faces-2.1.28.jar [2660.56 ko]
-  A jaxb-core-2.2.7.jar [221.75 ko]
-  A openejb-core-eclipselink-4.7.0.jar [11.52 ko]
-  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
-  A xbean-asm5-shaded-3.18.jar [144.47 ko]
-
-  change: +3.87 MB
-  total : 49.29 MB
-
-openejb-standalone 4.7.0 
-
-  D serializer-2.7.1.jar [278.28 ko]
-  D xalan-2.7.1.jar [3176.15 ko]
-  D xbean-asm4-shaded-3.15.jar [128.36 ko]
-  D xercesImpl-2.11.0.jar [1367.76 ko]
-  A FastInfoset-1.2.12.jar [293.86 ko]
-  A cxf-rt-management-2.6.14.jar [67.43 ko]
-  A istack-commons-runtime-2.16.jar [23.19 ko]
-  A jaxb-core-2.2.7.jar [221.75 ko]
-  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
-  A xbean-asm5-shaded-3.18.jar [144.47 ko]
-
-  change: -2.92 MB
+apache-tomee 1.7.0 webprofile
+
+  D gson-2.1.jar [180.11 ko]
+  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
+  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
+  D xbean-asm4-shaded-3.15.jar [128.36 ko]
+  A FastInfoset-1.2.12.jar [293.86 ko]
+  A el-api.jar [55.43 ko]
+  A istack-commons-runtime-2.16.jar [23.19 ko]
+  A jaxb-core-2.2.7.jar [221.75 ko]
+  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
+  A xbean-asm5-shaded-3.18.jar [144.47 ko]
+
+  change: +0.81 MB
+  total : 29.85 MB
+
+
+apache-tomee 1.7.0 jaxrs
+
+  D gson-2.1.jar [180.11 ko]
+  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
+  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
+  D xbean-asm4-shaded-3.15.jar [128.36 ko]
+  A FastInfoset-1.2.12.jar [293.86 ko]
+  A cxf-rt-management-2.6.14.jar [67.43 ko]
+  A el-api.jar [55.43 ko]
+  A istack-commons-runtime-2.16.jar [23.19 ko]
+  A jaxb-core-2.2.7.jar [221.75 ko]
+  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
+  A xbean-asm5-shaded-3.18.jar [144.47 ko]
+
+  change: +0.88 MB
+  total : 33.14 MB
+
+
+apache-tomee 1.7.0 plus
+
+  D gson-2.1.jar [180.11 ko]
+  D serializer-2.7.1.jar [278.28 ko]
+  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
+  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
+  D xalan-2.7.1.jar [3176.15 ko]
+  D xbean-asm4-shaded-3.15.jar [128.36 ko]
+  D xercesImpl-2.11.0.jar [1367.76 ko]
+  D xml-apis-1.4.01.jar [220.54 ko]
+  A FastInfoset-1.2.12.jar [293.86 ko]
+  A cxf-rt-management-2.6.14.jar [67.43 ko]
+  A el-api.jar [55.43 ko]
+  A istack-commons-runtime-2.16.jar [23.19 ko]
+  A jaxb-core-2.2.7.jar [221.75 ko]
+  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
+  A xbean-asm5-shaded-3.18.jar [144.47 ko]
+
+  change: -3.44 MB
+  total : 41.98 MB
+
+apache-tomee 1.7.0 plume
+
+  D gson-2.1.jar [180.11 ko]
+  D myfaces-api-2.1.13.jar [1190.07 ko]
+  D myfaces-impl-2.1.13.jar [2041.05 ko]
+  D serializer-2.7.1.jar [278.28 ko]
+  D static-tomee-bootstrap-1.6.0.2.jar [132.15 ko]
+  D static-tomee-jquery-1.6.0.2.jar [163.05 ko]
+  D tomee-myfaces-1.6.0.2.jar [30.38 ko]
+  D xalan-2.7.1.jar [3176.15 ko]
+  D xbean-asm4-shaded-3.15.jar [128.36 ko]
+  D xercesImpl-2.11.0.jar [1367.76 ko]
+  A FastInfoset-1.2.12.jar [293.86 ko]
+  A commonj.sdo-2.1.1.jar [21.01 ko]
+  A cxf-rt-management-2.6.14.jar [67.43 ko]
+  A eclipselink-2.4.2.jar [8650.47 ko]
+  A el-api.jar [55.43 ko]
+  A istack-commons-runtime-2.16.jar [23.19 ko]
+  A javax.faces-2.1.28.jar [2660.56 ko]
+  A jaxb-core-2.2.7.jar [221.75 ko]
+  A openejb-core-eclipselink-4.7.0.jar [11.52 ko]
+  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
+  A xbean-asm5-shaded-3.18.jar [144.47 ko]
+
+  change: +3.87 MB
+  total : 49.29 MB
+
+openejb-standalone 4.7.0 
+
+  D serializer-2.7.1.jar [278.28 ko]
+  D xalan-2.7.1.jar [3176.15 ko]
+  D xbean-asm4-shaded-3.15.jar [128.36 ko]
+  D xercesImpl-2.11.0.jar [1367.76 ko]
+  A FastInfoset-1.2.12.jar [293.86 ko]
+  A cxf-rt-management-2.6.14.jar [67.43 ko]
+  A istack-commons-runtime-2.16.jar [23.19 ko]
+  A jaxb-core-2.2.7.jar [221.75 ko]
+  A quartz-openejb-shade-2.2.1.jar [1237.12 ko]
+  A xbean-asm5-shaded-3.18.jar [144.47 ko]
+
+  change: -2.92 MB
   total : 30.12 MB
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-embedded/src/test/java/org/apache/openejb/arquillian/embedded/MultipleDeploymentsTest.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-embedded/src/test/java/org/apache/openejb/arquillian/embedded/MultipleDeploymentsTest.java b/arquillian/arquillian-tomee-embedded/src/test/java/org/apache/openejb/arquillian/embedded/MultipleDeploymentsTest.java
index e6b3a4d..d2329e2 100644
--- a/arquillian/arquillian-tomee-embedded/src/test/java/org/apache/openejb/arquillian/embedded/MultipleDeploymentsTest.java
+++ b/arquillian/arquillian-tomee-embedded/src/test/java/org/apache/openejb/arquillian/embedded/MultipleDeploymentsTest.java
@@ -1,82 +1,82 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.arquillian.embedded;
-
-import org.apache.tomee.catalina.environment.Hosts;
-import org.jboss.arquillian.container.test.api.Deployment;
-import org.jboss.arquillian.container.test.api.OperateOnDeployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.asset.EmptyAsset;
-import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.inject.Inject;
-
-@RunWith(Arquillian.class)
-public class MultipleDeploymentsTest extends Assert {
-
-    public static final String MSG = "HelloWorld";
-
-    @Deployment(name = "orange")
-    public static WebArchive orange() {
-        return ShrinkWrap.create(WebArchive.class, "orange.war")
-            .addClasses(
-                TestMe.class,
-                Hosts.class)
-            .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml");
-    }
-
-    @Deployment(name = "green")
-    public static WebArchive green() {
-        return ShrinkWrap.create(WebArchive.class, "green.war");
-    }
-
-    @Deployment(name = "blue")
-    public static WebArchive blue() {
-        return ShrinkWrap.create(WebArchive.class, "blue.war");
-    }
-
-    @Deployment(name = "yellow")
-    public static WebArchive yellow() {
-        return ShrinkWrap.create(WebArchive.class, "yellow.war");
-    }
-
-    @Test
-    @OperateOnDeployment("orange")
-    public void testOrange(final TestMe testMe) throws Exception {
-        assertNotNull(testMe);
-        assertEquals("Unexpected message", MSG, testMe.getMessage());
-    }
-
-    @Test
-    @OperateOnDeployment("green")
-    public void testMap() throws Exception {
-        // no-op
-    }
-
-    public static class TestMe {
-        public TestMe() {
-        }
-
-        public String getMessage() {
-            return MSG;
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.arquillian.embedded;
+
+import org.apache.tomee.catalina.environment.Hosts;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.container.test.api.OperateOnDeployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.asset.EmptyAsset;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.inject.Inject;
+
+@RunWith(Arquillian.class)
+public class MultipleDeploymentsTest extends Assert {
+
+    public static final String MSG = "HelloWorld";
+
+    @Deployment(name = "orange")
+    public static WebArchive orange() {
+        return ShrinkWrap.create(WebArchive.class, "orange.war")
+            .addClasses(
+                TestMe.class,
+                Hosts.class)
+            .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml");
+    }
+
+    @Deployment(name = "green")
+    public static WebArchive green() {
+        return ShrinkWrap.create(WebArchive.class, "green.war");
+    }
+
+    @Deployment(name = "blue")
+    public static WebArchive blue() {
+        return ShrinkWrap.create(WebArchive.class, "blue.war");
+    }
+
+    @Deployment(name = "yellow")
+    public static WebArchive yellow() {
+        return ShrinkWrap.create(WebArchive.class, "yellow.war");
+    }
+
+    @Test
+    @OperateOnDeployment("orange")
+    public void testOrange(final TestMe testMe) throws Exception {
+        assertNotNull(testMe);
+        assertEquals("Unexpected message", MSG, testMe.getMessage());
+    }
+
+    @Test
+    @OperateOnDeployment("green")
+    public void testMap() throws Exception {
+        // no-op
+    }
+
+    public static class TestMe {
+        public TestMe() {
+        }
+
+        public String getMessage() {
+            return MSG;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-remote/src/main/java/org/apache/tomee/arquillian/remote/RemoteTomEEContainer.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-remote/src/main/java/org/apache/tomee/arquillian/remote/RemoteTomEEContainer.java b/arquillian/arquillian-tomee-remote/src/main/java/org/apache/tomee/arquillian/remote/RemoteTomEEContainer.java
index aab4eff..37cfb02 100644
--- a/arquillian/arquillian-tomee-remote/src/main/java/org/apache/tomee/arquillian/remote/RemoteTomEEContainer.java
+++ b/arquillian/arquillian-tomee-remote/src/main/java/org/apache/tomee/arquillian/remote/RemoteTomEEContainer.java
@@ -1,357 +1,357 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.tomee.arquillian.remote;
-
-import org.apache.openejb.arquillian.common.ArquillianFilterRunner;
-import org.apache.openejb.arquillian.common.ArquillianUtil;
-import org.apache.openejb.arquillian.common.Files;
-import org.apache.openejb.arquillian.common.IO;
-import org.apache.openejb.arquillian.common.Setup;
-import org.apache.openejb.arquillian.common.TomEEContainer;
-import org.apache.openejb.assembler.Deployer;
-import org.apache.openejb.assembler.DeployerEjb;
-import org.apache.openejb.config.RemoteServer;
-import org.apache.openejb.util.NetworkUtil;
-import org.jboss.arquillian.container.spi.client.container.LifecycleException;
-import org.jboss.arquillian.protocol.servlet.ServletMethodExecutor;
-import org.jboss.shrinkwrap.api.Archive;
-
-import javax.naming.NamingException;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-import java.util.TreeMap;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-public class RemoteTomEEContainer extends TomEEContainer<RemoteTomEEConfiguration> {
-    private static final Logger logger = Logger.getLogger(RemoteTomEEContainer.class.getName());
-
-    private static final String ARQUILLIAN_FILTER = "-Dorg.apache.openejb.servlet.filters=" + ArquillianFilterRunner.class.getName() + "=" + ServletMethodExecutor.ARQUILLIAN_SERVLET_MAPPING;
-
-    private RemoteServer container;
-    private boolean shutdown;
-    private File tomeeHome;
-    private Collection<Archive<?>> containerArchives;
-    private final Properties deployerProperties = new Properties();
-
-    @Override
-    public void setup(final RemoteTomEEConfiguration configuration) {
-        super.setup(configuration);
-
-        if (configuration.getDeployerProperties() != null) {
-            try {
-                final InputStream bytes = IO.read(configuration.getDeployerProperties().getBytes());
-                IO.readProperties(bytes, deployerProperties);
-            } catch (final IOException e) {
-                logger.log(Level.SEVERE, "Can't parse <property name=\"properties\"> value '" + configuration.getProperties() + "'", e);
-            }
-        }
-    }
-
-    @Override
-    public void start() throws LifecycleException {
-        // see if TomEE is already running by checking the http port
-        final int httpPort = configuration.getHttpPort();
-
-        if (Setup.isRunning(configuration.getHost(), httpPort)) {
-
-            String host = "local";
-
-            if (!NetworkUtil.isLocalAddress(configuration.getHost())) {
-                //Supply at least this property so that the archive is transmitted on deploy
-                if (null == deployerProperties.getProperty(DeployerEjb.OPENEJB_USE_BINARIES)) {
-                    deployerProperties.setProperty(DeployerEjb.OPENEJB_USE_BINARIES, "true");
-                }
-                host = "remote";
-            }
-
-            logger.info(String.format("TomEE found running on %s port %s", host, httpPort));
-
-            return;
-        }
-
-        shutdown = true;
-
-        final String shutdownPort = System.getProperty(RemoteServer.SERVER_SHUTDOWN_PORT);
-        final String shutdownHost = System.getProperty(RemoteServer.SERVER_SHUTDOWN_HOST);
-        final String shutdownCommand = System.getProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND);
-        final String debug = System.getProperty(RemoteServer.OPENEJB_SERVER_DEBUG);
-        final String debugPort = System.getProperty(RemoteServer.SERVER_DEBUG_PORT);
-
-        try {
-
-            configure();
-
-            final int stopPort = configuration.getStopPort();
-            System.setProperty(RemoteServer.SERVER_SHUTDOWN_PORT, Integer.toString(stopPort));
-            System.setProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND, configuration.getStopCommand());
-            System.setProperty(RemoteServer.SERVER_SHUTDOWN_HOST, configuration.getStopHost());
-
-            if (configuration.isDebug()) {
-                System.setProperty(RemoteServer.OPENEJB_SERVER_DEBUG, "true");
-                System.setProperty(RemoteServer.SERVER_DEBUG_PORT, Integer.toString(configuration.getDebugPort()));
-            }
-
-            container = new RemoteServer();
-            container.setPortStartup(httpPort);
-            container.start(args(), "start", true);
-            container.killOnExit();
-
-            if (configuration.getProperties() != null) {
-                final Properties props = new Properties();
-                IO.readProperties(IO.read(configuration.getProperties().getBytes()), props);
-
-                containerArchives = ArquillianUtil.toDeploy(props);
-                for (final Archive<?> archive : containerArchives) {
-                    deploy(archive);
-                }
-            }
-        } catch (final Exception e) {
-            container.destroy();
-            logger.log(Level.SEVERE, "Unable to start remote container", e);
-            throw new LifecycleException("Unable to start remote container:" + e.getMessage(), e);
-        } finally {
-            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_PORT, shutdownPort);
-            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_HOST, shutdownHost);
-            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND, shutdownCommand);
-            resetSystemProperty(RemoteServer.OPENEJB_SERVER_DEBUG, debug);
-            resetSystemProperty(RemoteServer.SERVER_DEBUG_PORT, debugPort);
-        }
-    }
-
-    @Override
-    protected Properties getDeployerProperties() {
-        if (deployerProperties.isEmpty()) {
-            return null;
-        }
-        return deployerProperties;
-    }
-
-    private List<String> args() {
-        String opts = configuration.getCatalina_opts();
-        if (opts != null) {
-            opts = opts.trim();
-        }
-        if (opts == null || opts.isEmpty()) {
-            return Arrays.asList("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=false", ARQUILLIAN_FILTER);
-        }
-
-        final List<String> splitOnSpace = new ArrayList<String>();
-
-        final Iterator<String> it = new ArgsIterator(opts);
-        while (it.hasNext()) {
-            splitOnSpace.add(it.next());
-        }
-
-        if (!splitOnSpace.contains("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true")) {
-            splitOnSpace.add("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=false");
-        }
-        splitOnSpace.add(ARQUILLIAN_FILTER);
-        return splitOnSpace;
-    }
-
-    private static void resetSystemProperty(final String key, final String value) {
-        if (value == null) {
-            System.getProperties().remove(key);
-        } else {
-            System.setProperty(key, value);
-        }
-    }
-
-    private void configure() throws LifecycleException, IOException {
-        final File workingDirectory = new File(configuration.getDir()).getAbsoluteFile();
-
-        if (configuration.getCleanOnStartUp()) {
-            Files.delete(workingDirectory);
-        }
-
-        if (workingDirectory.exists()) {
-
-            Files.assertDir(workingDirectory);
-
-        } else {
-
-            Files.mkdir(workingDirectory);
-            Files.deleteOnExit(workingDirectory);
-        }
-
-        Files.readable(workingDirectory);
-        Files.writable(workingDirectory);
-
-        tomeeHome = Setup.findHome(workingDirectory);
-
-        if (tomeeHome == null) {
-            tomeeHome = Setup.downloadAndUnpack(workingDirectory, configuration.getArtifactName());
-
-            logger.log(Level.INFO, "Downloaded container to: " + tomeeHome);
-        }
-
-        Files.assertDir(tomeeHome);
-        Files.readable(tomeeHome);
-        Files.writable(tomeeHome);
-
-        Setup.synchronizeFolder(tomeeHome, configuration.getConf(), "conf");
-        Setup.synchronizeFolder(tomeeHome, configuration.getBin(), "bin");
-        Setup.synchronizeFolder(tomeeHome, configuration.getLib(), "lib");
-        Setup.addTomEELibraries(tomeeHome, configuration.getAdditionalLibs());
-
-        Setup.configureServerXml(tomeeHome, configuration);
-
-        Setup.configureSystemProperties(tomeeHome, configuration);
-
-        final String opts = configuration.getCatalina_opts();
-
-        Setup.exportProperties(tomeeHome, configuration, opts == null || (!opts.contains("-Xm") && !opts.matches(".*-XX:[^=]*Size=.*")));
-        Setup.installArquillianBeanDiscoverer(tomeeHome);
-
-        if (configuration.isRemoveUnusedWebapps()) {
-            Setup.removeUselessWebapps(tomeeHome);
-        }
-
-        if (configuration.isSimpleLog() && noLoggingConfigProvided()) {
-            final File loggingProperties = Files.path(tomeeHome, "conf", "logging.properties");
-
-            final Properties logging = new Properties();
-            logging.put("handlers", "java.util.logging.ConsoleHandler");
-            logging.put(".handlers", "java.util.logging.ConsoleHandler");
-            logging.put("java.util.logging.ConsoleHandler.level", "INFO");
-            logging.put("java.util.logging.ConsoleHandler.formatter", "org.apache.tomee.jul.formatter.SimpleTomEEFormatter");
-
-            IO.writeProperties(loggingProperties, logging);
-        }
-
-        if (logger.isLoggable(Level.FINE)) {
-            final Map<Object, Object> map = new TreeMap<Object, Object>(System.getProperties());
-            for (final Map.Entry<Object, Object> entry : map.entrySet()) {
-                logger.log(Level.FINE, String.format("%s = %s\n", entry.getKey(), entry.getValue()));
-            }
-        }
-    }
-
-    private boolean noLoggingConfigProvided() {
-        if (configuration.getConf() == null) {
-            return true;
-        }
-
-        final File conf = new File(configuration.getConf());
-
-        return !(conf.exists()
-                && (new File(conf, "logging.properties").exists()
-                || new File(conf, "log4j.properties").exists()
-                || new File(conf, "log4j.xml").exists()));
-    }
-
-    @Override
-    public void stop() throws LifecycleException {
-        ArquillianUtil.undeploy(this, containerArchives);
-
-        // only stop the container if we started it
-        if (shutdown) {
-            Setup.removeArquillianBeanDiscoverer(tomeeHome);
-            container.destroy();
-        }
-    }
-
-    @Override
-    public Class<RemoteTomEEConfiguration> getConfigurationClass() {
-        return RemoteTomEEConfiguration.class;
-    }
-
-    @Override
-    protected Deployer deployer() throws NamingException {
-        try {
-            return super.deployer();
-        } catch (final RuntimeException ne) {
-            // some debug lines
-            if (Boolean.getBoolean("openejb.arquillian.debug")) {
-                container.kill3UNIX();
-                LOGGER.info("Can't connect to deployer through: " + providerUrl());
-                try {
-                    LOGGER.info("Here is the server.xml:\n" + IO.slurp(new File(Setup.findHome(new File(configuration.getDir()).getAbsoluteFile()), "conf/server.xml")));
-                } catch (final IOException ignored) {
-                    // no-op
-                }
-            }
-            throw ne;
-        }
-    }
-
-    private static class ArgsIterator implements Iterator<String> {
-        private final String string;
-        private int currentIndex;
-
-        public ArgsIterator(final String opts) {
-            string = opts;
-            currentIndex = 0;
-        }
-
-        @Override
-        public boolean hasNext() {
-            return string != null && currentIndex < string.length();
-        }
-
-        @Override
-        public String next() {
-            skipWhiteCharacters();
-
-            if (done()) {
-                throw new UnsupportedOperationException("No more element");
-            }
-
-            final char endChar;
-            if (string.charAt(currentIndex) == '"') {
-                currentIndex++;
-                endChar = '"';
-            } else {
-                endChar = ' ';
-            }
-
-            final int start = currentIndex;
-            int end = string.indexOf(endChar, currentIndex + 1);
-            if (end <= 0) {
-                end = string.length();
-            }
-
-            currentIndex = end + 1;
-
-            return string.substring(start, end);
-        }
-
-        private void skipWhiteCharacters() {
-            while (!done() && (string.charAt(currentIndex) == ' ' || string.charAt(currentIndex) == '\t')) {
-                currentIndex++;
-            }
-        }
-
-        private boolean done() {
-            return currentIndex >= string.length();
-        }
-
-        @Override
-        public void remove() {
-            throw new UnsupportedOperationException();
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.tomee.arquillian.remote;
+
+import org.apache.openejb.arquillian.common.ArquillianFilterRunner;
+import org.apache.openejb.arquillian.common.ArquillianUtil;
+import org.apache.openejb.arquillian.common.Files;
+import org.apache.openejb.arquillian.common.IO;
+import org.apache.openejb.arquillian.common.Setup;
+import org.apache.openejb.arquillian.common.TomEEContainer;
+import org.apache.openejb.assembler.Deployer;
+import org.apache.openejb.assembler.DeployerEjb;
+import org.apache.openejb.config.RemoteServer;
+import org.apache.openejb.util.NetworkUtil;
+import org.jboss.arquillian.container.spi.client.container.LifecycleException;
+import org.jboss.arquillian.protocol.servlet.ServletMethodExecutor;
+import org.jboss.shrinkwrap.api.Archive;
+
+import javax.naming.NamingException;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.TreeMap;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+public class RemoteTomEEContainer extends TomEEContainer<RemoteTomEEConfiguration> {
+    private static final Logger logger = Logger.getLogger(RemoteTomEEContainer.class.getName());
+
+    private static final String ARQUILLIAN_FILTER = "-Dorg.apache.openejb.servlet.filters=" + ArquillianFilterRunner.class.getName() + "=" + ServletMethodExecutor.ARQUILLIAN_SERVLET_MAPPING;
+
+    private RemoteServer container;
+    private boolean shutdown;
+    private File tomeeHome;
+    private Collection<Archive<?>> containerArchives;
+    private final Properties deployerProperties = new Properties();
+
+    @Override
+    public void setup(final RemoteTomEEConfiguration configuration) {
+        super.setup(configuration);
+
+        if (configuration.getDeployerProperties() != null) {
+            try {
+                final InputStream bytes = IO.read(configuration.getDeployerProperties().getBytes());
+                IO.readProperties(bytes, deployerProperties);
+            } catch (final IOException e) {
+                logger.log(Level.SEVERE, "Can't parse <property name=\"properties\"> value '" + configuration.getProperties() + "'", e);
+            }
+        }
+    }
+
+    @Override
+    public void start() throws LifecycleException {
+        // see if TomEE is already running by checking the http port
+        final int httpPort = configuration.getHttpPort();
+
+        if (Setup.isRunning(configuration.getHost(), httpPort)) {
+
+            String host = "local";
+
+            if (!NetworkUtil.isLocalAddress(configuration.getHost())) {
+                //Supply at least this property so that the archive is transmitted on deploy
+                if (null == deployerProperties.getProperty(DeployerEjb.OPENEJB_USE_BINARIES)) {
+                    deployerProperties.setProperty(DeployerEjb.OPENEJB_USE_BINARIES, "true");
+                }
+                host = "remote";
+            }
+
+            logger.info(String.format("TomEE found running on %s port %s", host, httpPort));
+
+            return;
+        }
+
+        shutdown = true;
+
+        final String shutdownPort = System.getProperty(RemoteServer.SERVER_SHUTDOWN_PORT);
+        final String shutdownHost = System.getProperty(RemoteServer.SERVER_SHUTDOWN_HOST);
+        final String shutdownCommand = System.getProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND);
+        final String debug = System.getProperty(RemoteServer.OPENEJB_SERVER_DEBUG);
+        final String debugPort = System.getProperty(RemoteServer.SERVER_DEBUG_PORT);
+
+        try {
+
+            configure();
+
+            final int stopPort = configuration.getStopPort();
+            System.setProperty(RemoteServer.SERVER_SHUTDOWN_PORT, Integer.toString(stopPort));
+            System.setProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND, configuration.getStopCommand());
+            System.setProperty(RemoteServer.SERVER_SHUTDOWN_HOST, configuration.getStopHost());
+
+            if (configuration.isDebug()) {
+                System.setProperty(RemoteServer.OPENEJB_SERVER_DEBUG, "true");
+                System.setProperty(RemoteServer.SERVER_DEBUG_PORT, Integer.toString(configuration.getDebugPort()));
+            }
+
+            container = new RemoteServer();
+            container.setPortStartup(httpPort);
+            container.start(args(), "start", true);
+            container.killOnExit();
+
+            if (configuration.getProperties() != null) {
+                final Properties props = new Properties();
+                IO.readProperties(IO.read(configuration.getProperties().getBytes()), props);
+
+                containerArchives = ArquillianUtil.toDeploy(props);
+                for (final Archive<?> archive : containerArchives) {
+                    deploy(archive);
+                }
+            }
+        } catch (final Exception e) {
+            container.destroy();
+            logger.log(Level.SEVERE, "Unable to start remote container", e);
+            throw new LifecycleException("Unable to start remote container:" + e.getMessage(), e);
+        } finally {
+            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_PORT, shutdownPort);
+            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_HOST, shutdownHost);
+            resetSystemProperty(RemoteServer.SERVER_SHUTDOWN_COMMAND, shutdownCommand);
+            resetSystemProperty(RemoteServer.OPENEJB_SERVER_DEBUG, debug);
+            resetSystemProperty(RemoteServer.SERVER_DEBUG_PORT, debugPort);
+        }
+    }
+
+    @Override
+    protected Properties getDeployerProperties() {
+        if (deployerProperties.isEmpty()) {
+            return null;
+        }
+        return deployerProperties;
+    }
+
+    private List<String> args() {
+        String opts = configuration.getCatalina_opts();
+        if (opts != null) {
+            opts = opts.trim();
+        }
+        if (opts == null || opts.isEmpty()) {
+            return Arrays.asList("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=false", ARQUILLIAN_FILTER);
+        }
+
+        final List<String> splitOnSpace = new ArrayList<String>();
+
+        final Iterator<String> it = new ArgsIterator(opts);
+        while (it.hasNext()) {
+            splitOnSpace.add(it.next());
+        }
+
+        if (!splitOnSpace.contains("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=true")) {
+            splitOnSpace.add("-Dorg.apache.catalina.STRICT_SERVLET_COMPLIANCE=false");
+        }
+        splitOnSpace.add(ARQUILLIAN_FILTER);
+        return splitOnSpace;
+    }
+
+    private static void resetSystemProperty(final String key, final String value) {
+        if (value == null) {
+            System.getProperties().remove(key);
+        } else {
+            System.setProperty(key, value);
+        }
+    }
+
+    private void configure() throws LifecycleException, IOException {
+        final File workingDirectory = new File(configuration.getDir()).getAbsoluteFile();
+
+        if (configuration.getCleanOnStartUp()) {
+            Files.delete(workingDirectory);
+        }
+
+        if (workingDirectory.exists()) {
+
+            Files.assertDir(workingDirectory);
+
+        } else {
+
+            Files.mkdir(workingDirectory);
+            Files.deleteOnExit(workingDirectory);
+        }
+
+        Files.readable(workingDirectory);
+        Files.writable(workingDirectory);
+
+        tomeeHome = Setup.findHome(workingDirectory);
+
+        if (tomeeHome == null) {
+            tomeeHome = Setup.downloadAndUnpack(workingDirectory, configuration.getArtifactName());
+
+            logger.log(Level.INFO, "Downloaded container to: " + tomeeHome);
+        }
+
+        Files.assertDir(tomeeHome);
+        Files.readable(tomeeHome);
+        Files.writable(tomeeHome);
+
+        Setup.synchronizeFolder(tomeeHome, configuration.getConf(), "conf");
+        Setup.synchronizeFolder(tomeeHome, configuration.getBin(), "bin");
+        Setup.synchronizeFolder(tomeeHome, configuration.getLib(), "lib");
+        Setup.addTomEELibraries(tomeeHome, configuration.getAdditionalLibs());
+
+        Setup.configureServerXml(tomeeHome, configuration);
+
+        Setup.configureSystemProperties(tomeeHome, configuration);
+
+        final String opts = configuration.getCatalina_opts();
+
+        Setup.exportProperties(tomeeHome, configuration, opts == null || (!opts.contains("-Xm") && !opts.matches(".*-XX:[^=]*Size=.*")));
+        Setup.installArquillianBeanDiscoverer(tomeeHome);
+
+        if (configuration.isRemoveUnusedWebapps()) {
+            Setup.removeUselessWebapps(tomeeHome);
+        }
+
+        if (configuration.isSimpleLog() && noLoggingConfigProvided()) {
+            final File loggingProperties = Files.path(tomeeHome, "conf", "logging.properties");
+
+            final Properties logging = new Properties();
+            logging.put("handlers", "java.util.logging.ConsoleHandler");
+            logging.put(".handlers", "java.util.logging.ConsoleHandler");
+            logging.put("java.util.logging.ConsoleHandler.level", "INFO");
+            logging.put("java.util.logging.ConsoleHandler.formatter", "org.apache.tomee.jul.formatter.SimpleTomEEFormatter");
+
+            IO.writeProperties(loggingProperties, logging);
+        }
+
+        if (logger.isLoggable(Level.FINE)) {
+            final Map<Object, Object> map = new TreeMap<Object, Object>(System.getProperties());
+            for (final Map.Entry<Object, Object> entry : map.entrySet()) {
+                logger.log(Level.FINE, String.format("%s = %s\n", entry.getKey(), entry.getValue()));
+            }
+        }
+    }
+
+    private boolean noLoggingConfigProvided() {
+        if (configuration.getConf() == null) {
+            return true;
+        }
+
+        final File conf = new File(configuration.getConf());
+
+        return !(conf.exists()
+                && (new File(conf, "logging.properties").exists()
+                || new File(conf, "log4j.properties").exists()
+                || new File(conf, "log4j.xml").exists()));
+    }
+
+    @Override
+    public void stop() throws LifecycleException {
+        ArquillianUtil.undeploy(this, containerArchives);
+
+        // only stop the container if we started it
+        if (shutdown) {
+            Setup.removeArquillianBeanDiscoverer(tomeeHome);
+            container.destroy();
+        }
+    }
+
+    @Override
+    public Class<RemoteTomEEConfiguration> getConfigurationClass() {
+        return RemoteTomEEConfiguration.class;
+    }
+
+    @Override
+    protected Deployer deployer() throws NamingException {
+        try {
+            return super.deployer();
+        } catch (final RuntimeException ne) {
+            // some debug lines
+            if (Boolean.getBoolean("openejb.arquillian.debug")) {
+                container.kill3UNIX();
+                LOGGER.info("Can't connect to deployer through: " + providerUrl());
+                try {
+                    LOGGER.info("Here is the server.xml:\n" + IO.slurp(new File(Setup.findHome(new File(configuration.getDir()).getAbsoluteFile()), "conf/server.xml")));
+                } catch (final IOException ignored) {
+                    // no-op
+                }
+            }
+            throw ne;
+        }
+    }
+
+    private static class ArgsIterator implements Iterator<String> {
+        private final String string;
+        private int currentIndex;
+
+        public ArgsIterator(final String opts) {
+            string = opts;
+            currentIndex = 0;
+        }
+
+        @Override
+        public boolean hasNext() {
+            return string != null && currentIndex < string.length();
+        }
+
+        @Override
+        public String next() {
+            skipWhiteCharacters();
+
+            if (done()) {
+                throw new UnsupportedOperationException("No more element");
+            }
+
+            final char endChar;
+            if (string.charAt(currentIndex) == '"') {
+                currentIndex++;
+                endChar = '"';
+            } else {
+                endChar = ' ';
+            }
+
+            final int start = currentIndex;
+            int end = string.indexOf(endChar, currentIndex + 1);
+            if (end <= 0) {
+                end = string.length();
+            }
+
+            currentIndex = end + 1;
+
+            return string.substring(start, end);
+        }
+
+        private void skipWhiteCharacters() {
+            while (!done() && (string.charAt(currentIndex) == ' ' || string.charAt(currentIndex) == '\t')) {
+                currentIndex++;
+            }
+        }
+
+        private boolean done() {
+            return currentIndex >= string.length();
+        }
+
+        @Override
+        public void remove() {
+            throw new UnsupportedOperationException();
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-embedded/conf/Catalina/localhost/ROOT.xml
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-embedded/conf/Catalina/localhost/ROOT.xml b/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-embedded/conf/Catalina/localhost/ROOT.xml
index 69d4c2b..bfd7fc8 100644
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-embedded/conf/Catalina/localhost/ROOT.xml
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-embedded/conf/Catalina/localhost/ROOT.xml
@@ -1,42 +1,42 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-<Context path="" crossContext="true">
-
-	<!-- JAAS -->
-
-	<!--<Realm
-		className="org.apache.catalina.realm.JAASRealm"
-		appName="PortalRealm"
-		userClassNames="com.liferay.portal.kernel.security.jaas.PortalPrincipal"
-		roleClassNames="com.liferay.portal.kernel.security.jaas.PortalRole"
-	/>-->
-
-	<!--
-	Uncomment the following to disable persistent sessions across reboots.
-	-->
-
-	<!--<Manager pathname="" />-->
-
-	<!--
-	Uncomment the following to not use sessions. See the property
-	"session.disabled" in portal.properties.
-	-->
-
-	<!--<Manager className="com.liferay.support.tomcat.session.SessionLessManagerBase" />-->
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+<Context path="" crossContext="true">
+
+	<!-- JAAS -->
+
+	<!--<Realm
+		className="org.apache.catalina.realm.JAASRealm"
+		appName="PortalRealm"
+		userClassNames="com.liferay.portal.kernel.security.jaas.PortalPrincipal"
+		roleClassNames="com.liferay.portal.kernel.security.jaas.PortalRole"
+	/>-->
+
+	<!--
+	Uncomment the following to disable persistent sessions across reboots.
+	-->
+
+	<!--<Manager pathname="" />-->
+
+	<!--
+	Uncomment the following to not use sessions. See the property
+	"session.disabled" in portal.properties.
+	-->
+
+	<!--<Manager className="com.liferay.support.tomcat.session.SessionLessManagerBase" />-->
 </Context>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-remote/conf/Catalina/localhost/ROOT.xml
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-remote/conf/Catalina/localhost/ROOT.xml b/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-remote/conf/Catalina/localhost/ROOT.xml
index 69d4c2b..bfd7fc8 100644
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-remote/conf/Catalina/localhost/ROOT.xml
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-config-tests/src/test/resources/tomee-remote/conf/Catalina/localhost/ROOT.xml
@@ -1,42 +1,42 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one or more
-    contributor license agreements.  See the NOTICE file distributed with
-    this work for additional information regarding copyright ownership.
-    The ASF licenses this file to You under the Apache License, Version 2.0
-    (the "License"); you may not use this file except in compliance with
-    the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
--->
-<Context path="" crossContext="true">
-
-	<!-- JAAS -->
-
-	<!--<Realm
-		className="org.apache.catalina.realm.JAASRealm"
-		appName="PortalRealm"
-		userClassNames="com.liferay.portal.kernel.security.jaas.PortalPrincipal"
-		roleClassNames="com.liferay.portal.kernel.security.jaas.PortalRole"
-	/>-->
-
-	<!--
-	Uncomment the following to disable persistent sessions across reboots.
-	-->
-
-	<!--<Manager pathname="" />-->
-
-	<!--
-	Uncomment the following to not use sessions. See the property
-	"session.disabled" in portal.properties.
-	-->
-
-	<!--<Manager className="com.liferay.support.tomcat.session.SessionLessManagerBase" />-->
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+<Context path="" crossContext="true">
+
+	<!-- JAAS -->
+
+	<!--<Realm
+		className="org.apache.catalina.realm.JAASRealm"
+		appName="PortalRealm"
+		userClassNames="com.liferay.portal.kernel.security.jaas.PortalPrincipal"
+		roleClassNames="com.liferay.portal.kernel.security.jaas.PortalRole"
+	/>-->
+
+	<!--
+	Uncomment the following to disable persistent sessions across reboots.
+	-->
+
+	<!--<Manager pathname="" />-->
+
+	<!--
+	Uncomment the following to not use sessions. See the property
+	"session.disabled" in portal.properties.
+	-->
+
+	<!--<Manager className="com.liferay.support.tomcat.session.SessionLessManagerBase" />-->
 </Context>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/DummyManagedBean.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/DummyManagedBean.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/DummyManagedBean.java
index b9d5b5a..7030ae9 100755
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/DummyManagedBean.java
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/DummyManagedBean.java
@@ -1,56 +1,56 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.arquillian.tests.jms;
-
-import javax.annotation.Resource;
-import javax.faces.bean.ManagedBean;
-import javax.jms.ConnectionFactory;
-import javax.jms.Queue;
-import javax.jms.Topic;
-
-@ManagedBean
-public class DummyManagedBean {
-    @Resource
-    private Queue queue;
-
-    @Resource
-    private Topic topic;
-
-    @Resource
-    private ConnectionFactory connectionFactory;
-
-    public String getFoo() {
-        if (queue != null) {
-            return "queueInjected";
-        }
-        return "queueNotInjected";
-    }
-
-    public String getBoo() {
-        if (topic != null) {
-            return "topicInjected";
-        }
-        return "topicNotInjected";
-    }
-
-    public String getBaz() {
-        if (connectionFactory != null) {
-            return "connectionFactoryInjected";
-        }
-        return "connectionFactoryNotInjected";
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.arquillian.tests.jms;
+
+import javax.annotation.Resource;
+import javax.faces.bean.ManagedBean;
+import javax.jms.ConnectionFactory;
+import javax.jms.Queue;
+import javax.jms.Topic;
+
+@ManagedBean
+public class DummyManagedBean {
+    @Resource
+    private Queue queue;
+
+    @Resource
+    private Topic topic;
+
+    @Resource
+    private ConnectionFactory connectionFactory;
+
+    public String getFoo() {
+        if (queue != null) {
+            return "queueInjected";
+        }
+        return "queueNotInjected";
+    }
+
+    public String getBoo() {
+        if (topic != null) {
+            return "topicInjected";
+        }
+        return "topicNotInjected";
+    }
+
+    public String getBaz() {
+        if (connectionFactory != null) {
+            return "connectionFactoryInjected";
+        }
+        return "connectionFactoryNotInjected";
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/JMSInjectionTest.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/JMSInjectionTest.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/JMSInjectionTest.java
index 30d8426..4d7ca40 100755
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/JMSInjectionTest.java
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-jms-tests/src/test/java/org/apache/openejb/arquillian/tests/jms/JMSInjectionTest.java
@@ -1,79 +1,79 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.arquillian.tests.jms;
-
-import org.apache.openejb.loader.IO;
-import org.jboss.arquillian.container.test.api.Deployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.arquillian.test.api.ArquillianResource;
-import org.jboss.shrinkwrap.api.ShrinkWrap;
-import org.jboss.shrinkwrap.api.asset.ClassLoaderAsset;
-import org.jboss.shrinkwrap.api.asset.StringAsset;
-import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.jboss.shrinkwrap.descriptor.api.Descriptors;
-import org.jboss.shrinkwrap.descriptor.api.webapp30.WebAppDescriptor;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.faces.webapp.FacesServlet;
-import java.io.IOException;
-import java.net.URL;
-
-import static org.junit.Assert.assertTrue;
-
-@RunWith(Arquillian.class)
-public class JMSInjectionTest {
-
-    @ArquillianResource
-    private URL url;
-
-    @Deployment(testable = false)
-    public static WebArchive getArchive() {
-
-        return ShrinkWrap.create(WebArchive.class, "jsf-jms-test.war")
-                .addClasses(DummyManagedBean.class)
-                .addAsWebResource(new ClassLoaderAsset(
-                        JMSInjectionTest.class.getPackage().getName().replace('.', '/').concat("/").concat("dummy.xhtml")), "dummy.xhtml")
-                .setWebXML(new StringAsset(Descriptors.create(WebAppDescriptor.class)
-                        .version("3.0")
-                        .createServlet()
-                            .servletName("jsf")
-                            .servletClass(FacesServlet.class.getName())
-                            .loadOnStartup(1)
-                        .up()
-                        .createServletMapping()
-                            .servletName("jsf")
-                            .urlPattern("*.xhtml") // not the default
-                        .up()
-                        .exportAsString()));
-    }
-
-    @Test
-    public void testJMSInjection() throws Exception {
-        validateTest("queueInjected");
-        validateTest("topicInjected");
-        validateTest("connectionFactoryInjected");
-    }
-
-    private void validateTest(final String expectedOutput) throws IOException {
-        final String output = IO.slurp(new URL(url.toExternalForm() + "dummy.xhtml"));
-        assertTrue("Output should contain: " + expectedOutput + "; and not " + output, output.contains(expectedOutput));
-    }
-
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.arquillian.tests.jms;
+
+import org.apache.openejb.loader.IO;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.arquillian.test.api.ArquillianResource;
+import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.asset.ClassLoaderAsset;
+import org.jboss.shrinkwrap.api.asset.StringAsset;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.jboss.shrinkwrap.descriptor.api.Descriptors;
+import org.jboss.shrinkwrap.descriptor.api.webapp30.WebAppDescriptor;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.faces.webapp.FacesServlet;
+import java.io.IOException;
+import java.net.URL;
+
+import static org.junit.Assert.assertTrue;
+
+@RunWith(Arquillian.class)
+public class JMSInjectionTest {
+
+    @ArquillianResource
+    private URL url;
+
+    @Deployment(testable = false)
+    public static WebArchive getArchive() {
+
+        return ShrinkWrap.create(WebArchive.class, "jsf-jms-test.war")
+                .addClasses(DummyManagedBean.class)
+                .addAsWebResource(new ClassLoaderAsset(
+                        JMSInjectionTest.class.getPackage().getName().replace('.', '/').concat("/").concat("dummy.xhtml")), "dummy.xhtml")
+                .setWebXML(new StringAsset(Descriptors.create(WebAppDescriptor.class)
+                        .version("3.0")
+                        .createServlet()
+                            .servletName("jsf")
+                            .servletClass(FacesServlet.class.getName())
+                            .loadOnStartup(1)
+                        .up()
+                        .createServletMapping()
+                            .servletName("jsf")
+                            .urlPattern("*.xhtml") // not the default
+                        .up()
+                        .exportAsString()));
+    }
+
+    @Test
+    public void testJMSInjection() throws Exception {
+        validateTest("queueInjected");
+        validateTest("topicInjected");
+        validateTest("connectionFactoryInjected");
+    }
+
+    private void validateTest(final String expectedOutput) throws IOException {
+        final String output = IO.slurp(new URL(url.toExternalForm() + "dummy.xhtml"));
+        assertTrue("Output should contain: " + expectedOutput + "; and not " + output, output.contains(expectedOutput));
+    }
+
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/DummyManagedBean.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/DummyManagedBean.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/DummyManagedBean.java
index ca23c05..edce25f 100644
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/DummyManagedBean.java
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/DummyManagedBean.java
@@ -1,44 +1,44 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.arquillian.tests.jsf.jpa;
-
-import javax.faces.bean.ManagedBean;
-import javax.persistence.EntityManager;
-import javax.persistence.EntityManagerFactory;
-import javax.persistence.PersistenceContext;
-import javax.persistence.PersistenceUnit;
-
-@ManagedBean
-public class DummyManagedBean {
-    @PersistenceUnit(unitName ="test-pu")
-    EntityManagerFactory emf;
-
-    @PersistenceContext(unitName ="test-pu")
-    EntityManager em;
-
-    public String getFoo()
-    {
-        if(emf!=null){return "emfInjected";}
-        return "emfNotInjected";
-    }
-
-    public String getBoo()
-    {
-        if(em!=null){return "emInjected";}
-        return "emNotInjected";
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.arquillian.tests.jsf.jpa;
+
+import javax.faces.bean.ManagedBean;
+import javax.persistence.EntityManager;
+import javax.persistence.EntityManagerFactory;
+import javax.persistence.PersistenceContext;
+import javax.persistence.PersistenceUnit;
+
+@ManagedBean
+public class DummyManagedBean {
+    @PersistenceUnit(unitName ="test-pu")
+    EntityManagerFactory emf;
+
+    @PersistenceContext(unitName ="test-pu")
+    EntityManager em;
+
+    public String getFoo()
+    {
+        if(emf!=null){return "emfInjected";}
+        return "emfNotInjected";
+    }
+
+    public String getBoo()
+    {
+        if(em!=null){return "emInjected";}
+        return "emNotInjected";
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/JPAInjectionTest.java
----------------------------------------------------------------------
diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/JPAInjectionTest.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/JPAInjectionTest.java
index 179b03a..187ff49 100644
--- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/JPAInjectionTest.java
+++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/jsf/jpa/JPAInjectionTest.java
@@ -1,77 +1,77 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.arquillian.tests.jsf.jpa;
-
-import org.apache.openejb.arquillian.tests.jsf.JSFs;
-import org.apache.openejb.loader.IO;
-import org.jboss.arquillian.container.test.api.Deployment;
-import org.jboss.arquillian.junit.Arquillian;
-import org.jboss.arquillian.test.api.ArquillianResource;
-import org.jboss.shrinkwrap.api.asset.Asset;
-import org.jboss.shrinkwrap.api.asset.ClassLoaderAsset;
-import org.jboss.shrinkwrap.api.asset.StringAsset;
-import org.jboss.shrinkwrap.api.spec.WebArchive;
-import org.jboss.shrinkwrap.descriptor.api.Descriptors;
-import org.jboss.shrinkwrap.descriptor.api.persistence20.PersistenceDescriptor;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import java.io.IOException;
-import java.net.URL;
-
-import static org.junit.Assert.assertTrue;
-
-@RunWith(Arquillian.class)
-public class JPAInjectionTest extends JSFs {
-
-    @ArquillianResource
-    private URL url;
-
-    @Deployment(testable = false)
-    public static WebArchive getArchive() {
-        PersistenceDescriptor persistenceDescriptor = Descriptors.create(PersistenceDescriptor.class)
-                .createPersistenceUnit()
-                    .name("test-pu")
-                    .transactionType("JTA")
-                    .clazz(PersistenceDescriptor.class.getName())
-                    .jtaDataSource("test-ds")
-                .up();
-
-
-        Asset persistenceAsset = new StringAsset(persistenceDescriptor.exportAsString());
-        return base("jsf-jpa-test.war").addAsWebInfResource(persistenceAsset, "persistence.xml")
-                .addClasses(DummyManagedBean.class)
-                .addAsWebResource(new ClassLoaderAsset(
-                        JPAInjectionTest.class.getPackage().getName().replace('.', '/').concat("/").concat("dummy.xhtml")), "dummy.xhtml");
-
-
-    }
-
-    @Test
-    public void testJPAInjection() throws Exception {
-        validateTest("emfInjected");
-        validateTest("emInjected");
-    }
-
-    private void validateTest(final String expectedOutput) throws IOException {
-        final String output = IO.slurp(new URL(url.toExternalForm() + "dummy.xhtml"));
-        assertTrue("Output should contain: " + expectedOutput + "; and not " + output, output.contains(expectedOutput));
-    }
-
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.arquillian.tests.jsf.jpa;
+
+import org.apache.openejb.arquillian.tests.jsf.JSFs;
+import org.apache.openejb.loader.IO;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.arquillian.test.api.ArquillianResource;
+import org.jboss.shrinkwrap.api.asset.Asset;
+import org.jboss.shrinkwrap.api.asset.ClassLoaderAsset;
+import org.jboss.shrinkwrap.api.asset.StringAsset;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.jboss.shrinkwrap.descriptor.api.Descriptors;
+import org.jboss.shrinkwrap.descriptor.api.persistence20.PersistenceDescriptor;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import java.io.IOException;
+import java.net.URL;
+
+import static org.junit.Assert.assertTrue;
+
+@RunWith(Arquillian.class)
+public class JPAInjectionTest extends JSFs {
+
+    @ArquillianResource
+    private URL url;
+
+    @Deployment(testable = false)
+    public static WebArchive getArchive() {
+        PersistenceDescriptor persistenceDescriptor = Descriptors.create(PersistenceDescriptor.class)
+                .createPersistenceUnit()
+                    .name("test-pu")
+                    .transactionType("JTA")
+                    .clazz(PersistenceDescriptor.class.getName())
+                    .jtaDataSource("test-ds")
+                .up();
+
+
+        Asset persistenceAsset = new StringAsset(persistenceDescriptor.exportAsString());
+        return base("jsf-jpa-test.war").addAsWebInfResource(persistenceAsset, "persistence.xml")
+                .addClasses(DummyManagedBean.class)
+                .addAsWebResource(new ClassLoaderAsset(
+                        JPAInjectionTest.class.getPackage().getName().replace('.', '/').concat("/").concat("dummy.xhtml")), "dummy.xhtml");
+
+
+    }
+
+    @Test
+    public void testJPAInjection() throws Exception {
+        validateTest("emfInjected");
+        validateTest("emInjected");
+    }
+
+    private void validateTest(final String expectedOutput) throws IOException {
+        final String output = IO.slurp(new URL(url.toExternalForm() + "dummy.xhtml"));
+        assertTrue("Output should contain: " + expectedOutput + "; and not " + output, output.contains(expectedOutput));
+    }
+
+
+}


[11/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/PersistenceUnitLinkResolverTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/PersistenceUnitLinkResolverTest.java b/container/openejb-core/src/test/java/org/apache/openejb/PersistenceUnitLinkResolverTest.java
index 57ecf5f..4f6b5a2 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/PersistenceUnitLinkResolverTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/PersistenceUnitLinkResolverTest.java
@@ -1,44 +1,44 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb;
-
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.PersistenceUnitLinkResolver;
-import org.apache.openejb.jee.Application;
-import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
-import org.apache.openejb.loader.Files;
-import org.junit.Test;
-
-import java.io.File;
-import java.net.URI;
-
-import static org.junit.Assert.assertNull;
-
-public class PersistenceUnitLinkResolverTest {
-    @Test
-    public void resolve() {
-        final AppModule appModule = new AppModule(Thread.currentThread().getContextClassLoader(), "target/classes/foo", new Application(), false);
-
-        Files.mkdir(new File("target/classes/foo/bar"));
-
-        final PersistenceUnitLinkResolver resolver = new PersistenceUnitLinkResolver(appModule);
-        resolver.add(URI.create("file:/fake/1"), "foo", new PersistenceUnit());
-        resolver.add(URI.create("file:/fake/2"), "foo", new PersistenceUnit());
-
-        assertNull(resolver.resolveLink("foo", URI.create("bar"))); // can't resolve but doesn't fail
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb;
+
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.PersistenceUnitLinkResolver;
+import org.apache.openejb.jee.Application;
+import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
+import org.apache.openejb.loader.Files;
+import org.junit.Test;
+
+import java.io.File;
+import java.net.URI;
+
+import static org.junit.Assert.assertNull;
+
+public class PersistenceUnitLinkResolverTest {
+    @Test
+    public void resolve() {
+        final AppModule appModule = new AppModule(Thread.currentThread().getContextClassLoader(), "target/classes/foo", new Application(), false);
+
+        Files.mkdir(new File("target/classes/foo/bar"));
+
+        final PersistenceUnitLinkResolver resolver = new PersistenceUnitLinkResolver(appModule);
+        resolver.add(URI.create("file:/fake/1"), "foo", new PersistenceUnit());
+        resolver.add(URI.create("file:/fake/2"), "foo", new PersistenceUnit());
+
+        assertNull(resolver.resolveLink("foo", URI.create("bar"))); // can't resolve but doesn't fail
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java b/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java
index 5bc6b58..5664afb 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java
@@ -1,44 +1,44 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.activemq;
-
-import org.apache.activemq.broker.BrokerFactory;
-import org.apache.activemq.broker.BrokerService;
-import org.apache.activemq.store.kahadb.KahaDBPersistenceAdapter;
-import org.apache.openejb.util.NetworkUtil;
-import org.junit.Test;
-
-import java.io.File;
-import java.net.URI;
-
-import static org.hamcrest.CoreMatchers.instanceOf;
-import static org.hamcrest.MatcherAssert.assertThat;
-import static org.junit.Assert.assertEquals;
-
-public class KahaDBSupportTest {
-    @Test
-    public void create() throws Exception {
-        final BrokerService broker = BrokerFactory.createBroker(new URI("openejb:broker:(tcp://localhost:" + NetworkUtil.getNextAvailablePort() + ")?usekahadb=true&kahadb.directory=target/kahatest"));
-        try {
-            assertThat(broker.getPersistenceAdapter(), instanceOf(KahaDBPersistenceAdapter.class));
-            final KahaDBPersistenceAdapter adapter = KahaDBPersistenceAdapter.class.cast(broker.getPersistenceAdapter());
-            assertEquals(new File("target/kahatest"), adapter.getDirectory());
-        } finally {
-            broker.stop();
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.activemq;
+
+import org.apache.activemq.broker.BrokerFactory;
+import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.store.kahadb.KahaDBPersistenceAdapter;
+import org.apache.openejb.util.NetworkUtil;
+import org.junit.Test;
+
+import java.io.File;
+import java.net.URI;
+
+import static org.hamcrest.CoreMatchers.instanceOf;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.junit.Assert.assertEquals;
+
+public class KahaDBSupportTest {
+    @Test
+    public void create() throws Exception {
+        final BrokerService broker = BrokerFactory.createBroker(new URI("openejb:broker:(tcp://localhost:" + NetworkUtil.getNextAvailablePort() + ")?usekahadb=true&kahadb.directory=target/kahatest"));
+        try {
+            assertThat(broker.getPersistenceAdapter(), instanceOf(KahaDBPersistenceAdapter.class));
+            final KahaDBPersistenceAdapter adapter = KahaDBPersistenceAdapter.class.cast(broker.getPersistenceAdapter());
+            assertEquals(new File("target/kahatest"), adapter.getDirectory());
+        } finally {
+            broker.stop();
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/assembler/DeployerEjbTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/assembler/DeployerEjbTest.java b/container/openejb-core/src/test/java/org/apache/openejb/assembler/DeployerEjbTest.java
index 6078958..65f8493 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/assembler/DeployerEjbTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/assembler/DeployerEjbTest.java
@@ -1,284 +1,284 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
- 
-package org.apache.openejb.assembler;
-
-import org.apache.openejb.OpenEJB;
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.assembler.classic.AppInfo;
-import org.apache.openejb.jee.WebApp;
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.loader.FileUtils;
-import org.apache.openejb.loader.Files;
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.testing.AppResource;
-import org.apache.openejb.testing.Classes;
-import org.apache.openejb.testing.Module;
-import org.apache.openejb.util.WebArchives;
-import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Properties;
-import java.util.concurrent.atomic.AtomicReference;
-
-@RunWith(ApplicationComposer.class)
-public class DeployerEjbTest {
-
-    private static final AtomicReference<String> property = new AtomicReference<String>(null);
-    private static final AtomicReference<File> warArchive = new AtomicReference<File>(null);
-    private static final String OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS = "openejb.deployer.save-deployments";
-
-    @BeforeClass
-    public static void beforeClass() throws Exception {
-
-        final FileUtils base = SystemInstance.get().getBase();
-        final File conf = base.getDirectory("conf", false);
-        Files.delete(conf);
-
-        final File apps = base.getDirectory("apps", true);
-        Files.delete(apps);
-
-        base.getDirectory("apps", true);
-        base.getDirectory("conf", true);
-
-        property.set(System.getProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS));
-        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.TRUE.toString());
-        warArchive.set(WebArchives.warArchive(TestClass.class));
-    }
-
-    @AfterClass
-    public static void afterClass() {
-
-        final String s = property.get();
-        if (null != s) {
-            System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, "true");
-        } else {
-            System.clearProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS);
-        }
-
-        final File file = warArchive.get();
-        if (file != null && file.exists()) {
-            if (!file.delete()) {
-                file.deleteOnExit();
-            }
-        }
-
-
-        final FileUtils base = SystemInstance.get().getBase();
-        if (null != base) {
-            try {
-                Files.delete(base.getDirectory("apps", false));
-            } catch (final Exception e) {
-                //Ignore
-            }
-            try {
-                Files.delete(base.getDirectory("conf", false));
-            } catch (final Exception e) {
-                //Ignore
-            }
-        }
-
-    }
-
-    @Module
-    @Classes(value = {DeployerEjb.class})
-    public WebApp war() {
-        return new WebApp().contextRoot("/initial");
-    }
-
-    @AppResource
-    private Context context;
-
-    @Before
-    public void before() throws Exception {
-        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
-        if (deployments.exists()) {
-            Files.delete(deployments);
-        }
-        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.TRUE.toString());
-    }
-
-    @After
-    public void after() throws Exception {
-        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
-        OpenEJB.destroy();
-    }
-
-    private Deployer getDeployer() throws NamingException {
-        return (Deployer) context.lookup("openejb/DeployerRemote");
-    }
-
-    @Test
-    public void testGetUniqueFile() throws Exception {
-
-        final String uniqueFile = getDeployer().getUniqueFile();
-        Assert.assertTrue(new File(uniqueFile).exists());
-    }
-
-    @Test
-    public void testGetDeployedApps() throws Exception {
-        getAppInfos();
-    }
-
-    private Collection<AppInfo> getAppInfos() throws Exception {
-        final Deployer deployer = getDeployer();
-        Collection<AppInfo> deployedApps = deployer.getDeployedApps();
-
-        if (null == deployedApps) {
-            deployedApps = new ArrayList<AppInfo>();
-        }
-
-        if (deployedApps.size() < 1) {
-            getAppInfo();
-            deployedApps.addAll(deployer.getDeployedApps());
-        }
-
-        Assert.assertTrue("Found no deployed apps", deployedApps.size() > 0);
-        return deployedApps;
-    }
-
-    @Test
-    public void testDeployWarSave() throws Exception {
-
-        final Collection<AppInfo> deployedApps = getDeployer().getDeployedApps();
-        Assert.assertTrue("Found more than one app", deployedApps.size() < 2);
-
-        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
-        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
-
-        getAppInfo();
-
-        Assert.assertTrue("Failed to find: " + deployments.getAbsolutePath(), deployments.exists());
-    }
-
-    private AppInfo getAppInfo() throws IOException, NamingException, OpenEJBException {
-        return getAppInfo(null);
-    }
-
-    private AppInfo getAppInfo(final Properties p) throws IOException, NamingException, OpenEJBException {
-
-        final Deployer deployer = getDeployer();
-
-        final File war = warArchive.get();
-        if (!war.exists()) {
-            Assert.fail("War file does not exist: " + war.getAbsolutePath());
-        }
-
-        return (null != p ? deployer.deploy(war.getAbsolutePath(), p) : deployer.deploy(war.getAbsolutePath()));
-    }
-
-    @Test
-    public void testDeployWarNoSave() throws Exception {
-        final Collection<AppInfo> deployedApps = getDeployer().getDeployedApps();
-        Assert.assertTrue("Found more than one app", deployedApps.size() < 2);
-
-        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
-        if (deployments.exists()) {
-            Files.delete(deployments);
-        }
-
-        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
-
-        final Properties p = new Properties();
-        p.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
-        getAppInfo(p);
-
-        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
-    }
-
-    @Test
-    public void testDeployProperties() throws Exception {
-        final Properties p = new Properties();
-        final String path = warArchive.get().getAbsolutePath();
-
-        p.setProperty(Deployer.FILENAME, path);
-        p.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
-
-        final Deployer deployer = getDeployer();
-        final AppInfo appInfo = deployer.deploy(p);
-        Assert.assertTrue("Paths do not match: " + path + " - " + appInfo.path, path.equals(appInfo.path));
-    }
-
-    @Test
-    public void testUndeploy() throws Exception {
-        final AppInfo appInfo = getDeployedApp();
-
-        Assert.assertNotNull("Failed to deploy app", appInfo);
-
-        final Deployer deployer = getDeployer();
-        deployer.undeploy(appInfo.path);
-
-        final Collection<AppInfo> appInfos = getAppInfos();
-        Assert.assertTrue("Failed to undeploy app", appInfos.size() < 2);
-    }
-
-    private AppInfo getDeployedApp() throws Exception {
-        final Collection<AppInfo> appInfos = getAppInfos();
-
-        AppInfo appInfo = null;
-        final File file = warArchive.get();
-
-        if (appInfos.size() < 2) {
-            appInfo = getAppInfo();
-        } else {
-
-            final String name = file.getName().toLowerCase();
-
-            for (final AppInfo info : appInfos) {
-                if (name.contains(info.appId.toLowerCase())) {
-                    appInfo = info;
-                }
-            }
-        }
-        return appInfo;
-    }
-
-    @Test
-    public void testReload() throws Exception {
-
-        final AppInfo appInfo = getDeployedApp();
-
-        final Deployer deployer = getDeployer();
-        deployer.reload(appInfo.path);
-
-        final Collection<AppInfo> deployedApps = deployer.getDeployedApps();
-        boolean found = false;
-        for (final AppInfo app : deployedApps) {
-            if (app.path.equals(appInfo.path)) {
-                found = true;
-            }
-        }
-
-        Assert.assertTrue("Failed to find app after redeploy", found);
-    }
-
-    public static class TestClass {
-        public TestClass() {
-        }
-    }
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+ 
+package org.apache.openejb.assembler;
+
+import org.apache.openejb.OpenEJB;
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.assembler.classic.AppInfo;
+import org.apache.openejb.jee.WebApp;
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.loader.FileUtils;
+import org.apache.openejb.loader.Files;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.testing.AppResource;
+import org.apache.openejb.testing.Classes;
+import org.apache.openejb.testing.Module;
+import org.apache.openejb.util.WebArchives;
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import java.io.File;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Properties;
+import java.util.concurrent.atomic.AtomicReference;
+
+@RunWith(ApplicationComposer.class)
+public class DeployerEjbTest {
+
+    private static final AtomicReference<String> property = new AtomicReference<String>(null);
+    private static final AtomicReference<File> warArchive = new AtomicReference<File>(null);
+    private static final String OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS = "openejb.deployer.save-deployments";
+
+    @BeforeClass
+    public static void beforeClass() throws Exception {
+
+        final FileUtils base = SystemInstance.get().getBase();
+        final File conf = base.getDirectory("conf", false);
+        Files.delete(conf);
+
+        final File apps = base.getDirectory("apps", true);
+        Files.delete(apps);
+
+        base.getDirectory("apps", true);
+        base.getDirectory("conf", true);
+
+        property.set(System.getProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS));
+        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.TRUE.toString());
+        warArchive.set(WebArchives.warArchive(TestClass.class));
+    }
+
+    @AfterClass
+    public static void afterClass() {
+
+        final String s = property.get();
+        if (null != s) {
+            System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, "true");
+        } else {
+            System.clearProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS);
+        }
+
+        final File file = warArchive.get();
+        if (file != null && file.exists()) {
+            if (!file.delete()) {
+                file.deleteOnExit();
+            }
+        }
+
+
+        final FileUtils base = SystemInstance.get().getBase();
+        if (null != base) {
+            try {
+                Files.delete(base.getDirectory("apps", false));
+            } catch (final Exception e) {
+                //Ignore
+            }
+            try {
+                Files.delete(base.getDirectory("conf", false));
+            } catch (final Exception e) {
+                //Ignore
+            }
+        }
+
+    }
+
+    @Module
+    @Classes(value = {DeployerEjb.class})
+    public WebApp war() {
+        return new WebApp().contextRoot("/initial");
+    }
+
+    @AppResource
+    private Context context;
+
+    @Before
+    public void before() throws Exception {
+        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
+        if (deployments.exists()) {
+            Files.delete(deployments);
+        }
+        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.TRUE.toString());
+    }
+
+    @After
+    public void after() throws Exception {
+        System.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
+        OpenEJB.destroy();
+    }
+
+    private Deployer getDeployer() throws NamingException {
+        return (Deployer) context.lookup("openejb/DeployerRemote");
+    }
+
+    @Test
+    public void testGetUniqueFile() throws Exception {
+
+        final String uniqueFile = getDeployer().getUniqueFile();
+        Assert.assertTrue(new File(uniqueFile).exists());
+    }
+
+    @Test
+    public void testGetDeployedApps() throws Exception {
+        getAppInfos();
+    }
+
+    private Collection<AppInfo> getAppInfos() throws Exception {
+        final Deployer deployer = getDeployer();
+        Collection<AppInfo> deployedApps = deployer.getDeployedApps();
+
+        if (null == deployedApps) {
+            deployedApps = new ArrayList<AppInfo>();
+        }
+
+        if (deployedApps.size() < 1) {
+            getAppInfo();
+            deployedApps.addAll(deployer.getDeployedApps());
+        }
+
+        Assert.assertTrue("Found no deployed apps", deployedApps.size() > 0);
+        return deployedApps;
+    }
+
+    @Test
+    public void testDeployWarSave() throws Exception {
+
+        final Collection<AppInfo> deployedApps = getDeployer().getDeployedApps();
+        Assert.assertTrue("Found more than one app", deployedApps.size() < 2);
+
+        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
+        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
+
+        getAppInfo();
+
+        Assert.assertTrue("Failed to find: " + deployments.getAbsolutePath(), deployments.exists());
+    }
+
+    private AppInfo getAppInfo() throws IOException, NamingException, OpenEJBException {
+        return getAppInfo(null);
+    }
+
+    private AppInfo getAppInfo(final Properties p) throws IOException, NamingException, OpenEJBException {
+
+        final Deployer deployer = getDeployer();
+
+        final File war = warArchive.get();
+        if (!war.exists()) {
+            Assert.fail("War file does not exist: " + war.getAbsolutePath());
+        }
+
+        return (null != p ? deployer.deploy(war.getAbsolutePath(), p) : deployer.deploy(war.getAbsolutePath()));
+    }
+
+    @Test
+    public void testDeployWarNoSave() throws Exception {
+        final Collection<AppInfo> deployedApps = getDeployer().getDeployedApps();
+        Assert.assertTrue("Found more than one app", deployedApps.size() < 2);
+
+        final File deployments = new File(SystemInstance.get().getBase().getDirectory("conf", false), "deployments.xml");
+        if (deployments.exists()) {
+            Files.delete(deployments);
+        }
+
+        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
+
+        final Properties p = new Properties();
+        p.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
+        getAppInfo(p);
+
+        Assert.assertFalse("Found existing: " + deployments.getAbsolutePath(), deployments.exists());
+    }
+
+    @Test
+    public void testDeployProperties() throws Exception {
+        final Properties p = new Properties();
+        final String path = warArchive.get().getAbsolutePath();
+
+        p.setProperty(Deployer.FILENAME, path);
+        p.setProperty(OPENEJB_DEPLOYER_SAVE_DEPLOYMENTS, Boolean.FALSE.toString());
+
+        final Deployer deployer = getDeployer();
+        final AppInfo appInfo = deployer.deploy(p);
+        Assert.assertTrue("Paths do not match: " + path + " - " + appInfo.path, path.equals(appInfo.path));
+    }
+
+    @Test
+    public void testUndeploy() throws Exception {
+        final AppInfo appInfo = getDeployedApp();
+
+        Assert.assertNotNull("Failed to deploy app", appInfo);
+
+        final Deployer deployer = getDeployer();
+        deployer.undeploy(appInfo.path);
+
+        final Collection<AppInfo> appInfos = getAppInfos();
+        Assert.assertTrue("Failed to undeploy app", appInfos.size() < 2);
+    }
+
+    private AppInfo getDeployedApp() throws Exception {
+        final Collection<AppInfo> appInfos = getAppInfos();
+
+        AppInfo appInfo = null;
+        final File file = warArchive.get();
+
+        if (appInfos.size() < 2) {
+            appInfo = getAppInfo();
+        } else {
+
+            final String name = file.getName().toLowerCase();
+
+            for (final AppInfo info : appInfos) {
+                if (name.contains(info.appId.toLowerCase())) {
+                    appInfo = info;
+                }
+            }
+        }
+        return appInfo;
+    }
+
+    @Test
+    public void testReload() throws Exception {
+
+        final AppInfo appInfo = getDeployedApp();
+
+        final Deployer deployer = getDeployer();
+        deployer.reload(appInfo.path);
+
+        final Collection<AppInfo> deployedApps = deployer.getDeployedApps();
+        boolean found = false;
+        for (final AppInfo app : deployedApps) {
+            if (app.path.equals(appInfo.path)) {
+                found = true;
+            }
+        }
+
+        Assert.assertTrue("Failed to find app after redeploy", found);
+    }
+
+    public static class TestClass {
+        public TestClass() {
+        }
+    }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/bval/BeanValidationAppendixInterceptorTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/bval/BeanValidationAppendixInterceptorTest.java b/container/openejb-core/src/test/java/org/apache/openejb/bval/BeanValidationAppendixInterceptorTest.java
index daea0d6..b918f0a 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/bval/BeanValidationAppendixInterceptorTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/bval/BeanValidationAppendixInterceptorTest.java
@@ -1,204 +1,204 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.bval;
-
-import org.apache.openejb.BeanContext;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.Empty;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.testing.Configuration;
-import org.apache.openejb.testing.Module;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.ejb.EJB;
-import javax.ejb.Local;
-import javax.ejb.LocalBean;
-import javax.ejb.Remote;
-import javax.ejb.Stateless;
-import javax.validation.ConstraintViolationException;
-import javax.validation.constraints.Min;
-import javax.validation.constraints.NotNull;
-import java.io.Serializable;
-import java.util.Properties;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-@RunWith(ApplicationComposer.class)
-public class BeanValidationAppendixInterceptorTest {
-    @Local
-    public static interface Manager {
-        String drive(Person person, @Min(18) int age);
-
-        Person create(@NotNull String name);
-    }
-
-    @Remote
-    public static interface ManagerRemote {
-        String drive(Person person, @Min(16) int age);
-
-        Person create(String name);
-    }
-
-    public static class Person implements Serializable {
-        public String name;
-
-        public String getName() {
-            return name;
-        }
-
-        public void setName(final String name) {
-            this.name = name;
-        }
-    }
-
-    @Stateless
-    public static class ManagerBean implements Manager {
-        public String drive(final Person person, final int age) {
-            return "vroom";
-        }
-
-        public Person create(final String name) {
-            final Person person = new Person();
-            person.setName(name);
-            return person;
-        }
-    }
-
-    @Stateless
-    public static class ManagerBean2 implements Manager, ManagerRemote {
-        public String drive(final Person person, final int age) {
-            return "vroom";
-        }
-
-        public Person create(final String name) {
-            final Person person = new Person();
-            person.setName(name);
-            return person;
-        }
-    }
-
-    @Stateless
-    @LocalBean
-    public static class ManagerLocalBean {
-        public void foo(@NotNull final String bar) {
-            // no-op
-        }
-    }
-
-    @Test
-    public void valid() {
-        final Person p = mgr.create("foo");
-        mgr.drive(p, 18);
-    }
-
-    @Test
-    public void notValid() {
-        Person p = null;
-        try {
-            p = mgr.create(null);
-            fail();
-        } catch (final Exception e) {
-            assertTrue(e.getCause() instanceof ConstraintViolationException);
-            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
-            assertEquals(1, cvs.getConstraintViolations().size());
-        }
-        try {
-            mgr.drive(p, 17);
-            fail();
-        } catch (final Exception e) {
-            assertTrue(e.getCause() instanceof ConstraintViolationException);
-            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
-            assertEquals(1, cvs.getConstraintViolations().size());
-        }
-    }
-
-    @Test
-    public void validRemote() {
-        final Person p = mgrRemote.create(null);
-        mgrRemote.drive(p, 26);
-        mgrRemote.drive(p, 17);
-    }
-
-    @Test
-    public void notValidRemote() {
-        final Person p = mgrRemote.create("bar");
-        try {
-            mgrRemote.drive(p, 15);
-            fail();
-        } catch (final Exception e) {
-            assertTrue(e.getCause() instanceof ConstraintViolationException);
-            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
-            assertEquals(1, cvs.getConstraintViolations().size());
-        }
-    }
-
-    @Test
-    public void localBean() {
-        mgrLB.foo("ok");
-        try {
-            mgrLB.foo(null);
-            fail();
-        } catch (final Exception e) {
-            assertTrue(e.getCause() instanceof ConstraintViolationException);
-            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
-            assertEquals(1, cvs.getConstraintViolations().size());
-        }
-    }
-
-    @EJB
-    private Manager mgr;
-    @EJB
-    private ManagerRemote mgrRemote;
-    @EJB
-    private ManagerLocalBean mgrLB;
-
-    @Configuration
-    public Properties config() {
-        final Properties p = new Properties();
-        p.put(BeanContext.USER_INTERCEPTOR_KEY, BeanValidationAppendixInterceptor.class.getName());
-        return p;
-    }
-
-    @Module
-    public EjbJar app() throws Exception {
-        final EjbJar ejbJar = new EjbJar("bval-interceptor");
-
-        final StatelessBean bean1 = new StatelessBean(ManagerBean.class);
-        bean1.addBusinessLocal(Manager.class);
-        bean1.setLocalBean(new Empty());
-
-        final StatelessBean bean3 = new StatelessBean(ManagerBean2.class);
-        bean3.addBusinessRemote(ManagerRemote.class);
-        bean3.addBusinessLocal(Manager.class);
-        bean3.setLocalBean(new Empty());
-
-        final StatelessBean bean2 = new StatelessBean(ManagerLocalBean.class);
-        bean2.setLocalBean(new Empty());
-
-        ejbJar.addEnterpriseBean(bean1);
-        ejbJar.addEnterpriseBean(bean2);
-        ejbJar.addEnterpriseBean(bean3);
-
-        return ejbJar;
-    }
-
-}
-
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.bval;
+
+import org.apache.openejb.BeanContext;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.Empty;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.testing.Configuration;
+import org.apache.openejb.testing.Module;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.ejb.EJB;
+import javax.ejb.Local;
+import javax.ejb.LocalBean;
+import javax.ejb.Remote;
+import javax.ejb.Stateless;
+import javax.validation.ConstraintViolationException;
+import javax.validation.constraints.Min;
+import javax.validation.constraints.NotNull;
+import java.io.Serializable;
+import java.util.Properties;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+@RunWith(ApplicationComposer.class)
+public class BeanValidationAppendixInterceptorTest {
+    @Local
+    public static interface Manager {
+        String drive(Person person, @Min(18) int age);
+
+        Person create(@NotNull String name);
+    }
+
+    @Remote
+    public static interface ManagerRemote {
+        String drive(Person person, @Min(16) int age);
+
+        Person create(String name);
+    }
+
+    public static class Person implements Serializable {
+        public String name;
+
+        public String getName() {
+            return name;
+        }
+
+        public void setName(final String name) {
+            this.name = name;
+        }
+    }
+
+    @Stateless
+    public static class ManagerBean implements Manager {
+        public String drive(final Person person, final int age) {
+            return "vroom";
+        }
+
+        public Person create(final String name) {
+            final Person person = new Person();
+            person.setName(name);
+            return person;
+        }
+    }
+
+    @Stateless
+    public static class ManagerBean2 implements Manager, ManagerRemote {
+        public String drive(final Person person, final int age) {
+            return "vroom";
+        }
+
+        public Person create(final String name) {
+            final Person person = new Person();
+            person.setName(name);
+            return person;
+        }
+    }
+
+    @Stateless
+    @LocalBean
+    public static class ManagerLocalBean {
+        public void foo(@NotNull final String bar) {
+            // no-op
+        }
+    }
+
+    @Test
+    public void valid() {
+        final Person p = mgr.create("foo");
+        mgr.drive(p, 18);
+    }
+
+    @Test
+    public void notValid() {
+        Person p = null;
+        try {
+            p = mgr.create(null);
+            fail();
+        } catch (final Exception e) {
+            assertTrue(e.getCause() instanceof ConstraintViolationException);
+            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
+            assertEquals(1, cvs.getConstraintViolations().size());
+        }
+        try {
+            mgr.drive(p, 17);
+            fail();
+        } catch (final Exception e) {
+            assertTrue(e.getCause() instanceof ConstraintViolationException);
+            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
+            assertEquals(1, cvs.getConstraintViolations().size());
+        }
+    }
+
+    @Test
+    public void validRemote() {
+        final Person p = mgrRemote.create(null);
+        mgrRemote.drive(p, 26);
+        mgrRemote.drive(p, 17);
+    }
+
+    @Test
+    public void notValidRemote() {
+        final Person p = mgrRemote.create("bar");
+        try {
+            mgrRemote.drive(p, 15);
+            fail();
+        } catch (final Exception e) {
+            assertTrue(e.getCause() instanceof ConstraintViolationException);
+            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
+            assertEquals(1, cvs.getConstraintViolations().size());
+        }
+    }
+
+    @Test
+    public void localBean() {
+        mgrLB.foo("ok");
+        try {
+            mgrLB.foo(null);
+            fail();
+        } catch (final Exception e) {
+            assertTrue(e.getCause() instanceof ConstraintViolationException);
+            final ConstraintViolationException cvs = (ConstraintViolationException) e.getCause();
+            assertEquals(1, cvs.getConstraintViolations().size());
+        }
+    }
+
+    @EJB
+    private Manager mgr;
+    @EJB
+    private ManagerRemote mgrRemote;
+    @EJB
+    private ManagerLocalBean mgrLB;
+
+    @Configuration
+    public Properties config() {
+        final Properties p = new Properties();
+        p.put(BeanContext.USER_INTERCEPTOR_KEY, BeanValidationAppendixInterceptor.class.getName());
+        return p;
+    }
+
+    @Module
+    public EjbJar app() throws Exception {
+        final EjbJar ejbJar = new EjbJar("bval-interceptor");
+
+        final StatelessBean bean1 = new StatelessBean(ManagerBean.class);
+        bean1.addBusinessLocal(Manager.class);
+        bean1.setLocalBean(new Empty());
+
+        final StatelessBean bean3 = new StatelessBean(ManagerBean2.class);
+        bean3.addBusinessRemote(ManagerRemote.class);
+        bean3.addBusinessLocal(Manager.class);
+        bean3.setLocalBean(new Empty());
+
+        final StatelessBean bean2 = new StatelessBean(ManagerLocalBean.class);
+        bean2.setLocalBean(new Empty());
+
+        ejbJar.addEnterpriseBean(bean1);
+        ejbJar.addEnterpriseBean(bean2);
+        ejbJar.addEnterpriseBean(bean3);
+
+        return ejbJar;
+    }
+
+}
+

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/AnnotationDeployerTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/AnnotationDeployerTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/AnnotationDeployerTest.java
index 9626ad9..3b0a075 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/AnnotationDeployerTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/AnnotationDeployerTest.java
@@ -1,550 +1,550 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.config;
-
-import org.apache.openejb.OpenEJB;
-import org.apache.openejb.assembler.classic.AppInfo;
-import org.apache.openejb.assembler.classic.Assembler;
-import org.apache.openejb.assembler.classic.ClientInfo;
-import org.apache.openejb.jee.AssemblyDescriptor;
-import org.apache.openejb.jee.ConfigProperty;
-import org.apache.openejb.jee.Connector;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.EnterpriseBean;
-import org.apache.openejb.jee.SessionBean;
-import org.apache.openejb.jee.TransactionSupportType;
-import org.apache.openejb.jee.WebApp;
-import org.apache.xbean.finder.Annotated;
-import org.apache.xbean.finder.AnnotationFinder;
-import org.apache.xbean.finder.ClassFinder;
-import org.apache.xbean.finder.archive.ClassesArchive;
-import org.junit.AfterClass;
-import org.junit.Assert;
-import org.junit.Test;
-
-import javax.annotation.Resource;
-import javax.ejb.ApplicationException;
-import javax.ejb.Local;
-import javax.ejb.LocalBean;
-import javax.ejb.Stateless;
-import javax.naming.NamingException;
-import javax.naming.Reference;
-import javax.resource.Referenceable;
-import javax.resource.ResourceException;
-import javax.resource.cci.MessageListener;
-import javax.resource.cci.Record;
-import javax.resource.spi.Activation;
-import javax.resource.spi.ActivationSpec;
-import javax.resource.spi.AdministeredObject;
-import javax.resource.spi.AuthenticationMechanism;
-import javax.resource.spi.AuthenticationMechanism.CredentialInterface;
-import javax.resource.spi.BootstrapContext;
-import javax.resource.spi.ConnectionDefinition;
-import javax.resource.spi.ConnectionManager;
-import javax.resource.spi.ConnectionRequestInfo;
-import javax.resource.spi.InvalidPropertyException;
-import javax.resource.spi.ManagedConnection;
-import javax.resource.spi.ManagedConnectionFactory;
-import javax.resource.spi.ResourceAdapter;
-import javax.resource.spi.ResourceAdapterInternalException;
-import javax.resource.spi.SecurityPermission;
-import javax.resource.spi.TransactionSupport.TransactionSupportLevel;
-import javax.resource.spi.endpoint.MessageEndpointFactory;
-import javax.resource.spi.work.WorkContext;
-import javax.security.auth.Subject;
-import javax.transaction.xa.XAResource;
-import javax.ws.rs.ApplicationPath;
-import javax.ws.rs.Path;
-import javax.ws.rs.core.Application;
-import java.io.PrintWriter;
-import java.io.Serializable;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import static org.hamcrest.CoreMatchers.is;
-import static org.hamcrest.CoreMatchers.notNullValue;
-import static org.hamcrest.CoreMatchers.nullValue;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertThat;
-import static org.junit.Assert.assertTrue;
-
-/**
- * @version $Rev$ $Date$
- */
-public class AnnotationDeployerTest {
-
-    @AfterClass
-    public static void afterClass() throws Exception {
-        OpenEJB.destroy();
-    }
-
-    @Test
-    /**
-     *  For http://issues.apache.org/jira/browse/OPENEJB-980
-     */
-    public void applicationExceptionInheritanceTest() throws Exception {
-        EjbModule ejbModule = testModule();
-        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
-        ejbModule = discvrAnnBeans.deploy(ejbModule);
-
-        final AssemblyDescriptor assemblyDescriptor = ejbModule.getEjbJar().getAssemblyDescriptor();
-        org.apache.openejb.jee.ApplicationException appEx =
-            assemblyDescriptor.getApplicationException(BusinessException.class);
-        assertThat(appEx, notNullValue());
-        assertThat(appEx.getExceptionClass(), is(BusinessException.class.getName()));
-        assertThat(appEx.isRollback(), is(true));
-
-        //inheritance is now handled at runtime, only explicitly mentioned exceptions are in the assembly descriptor
-        appEx = assemblyDescriptor.getApplicationException(ValueRequiredException.class);
-        assertThat(appEx, nullValue());
-    }
-
-    private EjbModule testModule() {
-        final EjbJar ejbJar = new EjbJar("test-classes");
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        ejbModule.setFinder(new ClassFinder(AnnotationDeployerTest.class,
-            BusinessException.class,
-            Exception.class,
-            GenericInterface.class,
-            InterceptedSLSBean.class,
-            MyMainClass.class,
-            TestLocalBean.class,
-            ValueRequiredException.class
-        ));
-        return ejbModule;
-    }
-
-
-    @Test
-    public void testSortClasses() throws Exception {
-        final AnnotationFinder finder = new AnnotationFinder(new ClassesArchive(Emerald.class)).link();
-
-        final List<Annotated<Class<?>>> classes = finder.findMetaAnnotatedClasses(Resource.class);
-        assertTrue(classes.size() >= 3);
-
-        final List<Annotated<Class<?>>> sorted = AnnotationDeployer.sortClasses(classes);
-
-        assertTrue(sorted.size() >= 3);
-
-        assertEquals(Emerald.class, sorted.get(0).get());
-        assertEquals(Green.class, sorted.get(1).get());
-        assertEquals(Color.class, sorted.get(2).get());
-    }
-
-    @Test
-    public void testSortMethods() throws Exception {
-        final AnnotationFinder finder = new AnnotationFinder(new ClassesArchive(Emerald.class)).link();
-
-        final List<Annotated<Method>> classes = finder.findMetaAnnotatedMethods(Resource.class);
-        assertTrue(classes.size() >= 3);
-
-        final List<Annotated<Method>> sorted = AnnotationDeployer.sortMethods(classes);
-
-        assertTrue(sorted.size() >= 3);
-
-        assertEquals(Emerald.class, sorted.get(0).get().getDeclaringClass());
-        assertEquals(Green.class, sorted.get(1).get().getDeclaringClass());
-        assertEquals(Color.class, sorted.get(2).get().getDeclaringClass());
-    }
-
-    @Test
-    /**
-     *  For https://issues.apache.org/jira/browse/OPENEJB-1063
-     */
-    public void badMainClassFormatTest() throws Exception {
-        final ConfigurationFactory config = new ConfigurationFactory();
-        final Assembler assembler = new Assembler();
-
-        final AppModule app = new AppModule(this.getClass().getClassLoader(), "test-app");
-
-        final ClientModule clientModule = new ClientModule(null, app.getClassLoader(), app.getJarLocation(), null, null);
-
-        // change "." --> "/" to check that main class is changed by the AnnotationDeployer
-        final String mainClass = MyMainClass.class.getName().replaceAll("\\.", "/");
-        clientModule.setMainClass(mainClass);
-
-        app.getClientModules().add(clientModule);
-
-        final AppInfo appInfo = config.configureApplication(app);
-
-        assembler.createApplication(appInfo);
-
-        final ClientInfo clientInfo = appInfo.clients.get(0);
-        Assert.assertNotNull(clientInfo);
-        Assert.assertEquals(MyMainClass.class.getName(), clientInfo.mainClass);
-    }
-
-    /**
-     * For https://issues.apache.org/jira/browse/OPENEJB-1128
-     */
-    @Test
-    public void interceptingGenericBusinessMethodCalls() throws Exception {
-        EjbModule ejbModule = testModule();
-        final EjbJar ejbJar = ejbModule.getEjbJar();
-
-        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
-        ejbModule = discvrAnnBeans.deploy(ejbModule);
-
-        final EnterpriseBean bean = ejbJar.getEnterpriseBean("InterceptedSLSBean");
-        assert bean != null;
-    }
-
-    /**
-     * For https://issues.apache.org/jira/browse/OPENEJB-1188
-     *
-     * @throws Exception
-     */
-    @Test
-    public void testLocalBean() throws Exception {
-        final EjbModule ejbModule = testModule();
-        final EjbJar ejbJar = ejbModule.getEjbJar();
-
-        AppModule appModule = new AppModule(Thread.currentThread().getContextClassLoader(), "myapp");
-        appModule.getEjbModules().add(ejbModule);
-
-        final AnnotationDeployer annotationDeployer = new AnnotationDeployer();
-        appModule = annotationDeployer.deploy(appModule);
-
-        EnterpriseBean bean = ejbJar.getEnterpriseBean("TestLocalBean");
-        assert bean != null;
-        assert (((SessionBean) bean).getLocalBean() != null);
-
-        bean = ejbJar.getEnterpriseBean("InterceptedSLSBean");
-        assert bean != null;
-        assert (((SessionBean) bean).getLocalBean() == null);
-    }
-
-    @Test
-    public void testResourceAdapter() throws Exception {
-        final ConnectorModule connectorModule = testConnectorModule();
-        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
-        discvrAnnBeans.deploy(connectorModule);
-
-        final Connector connector = connectorModule.getConnector();
-        Assert.assertEquals("displayName", connector.getDisplayName());
-        Assert.assertEquals("description", connector.getDescription());
-        Assert.assertEquals("eisType", connector.getEisType());
-        Assert.assertEquals("vendorName", connector.getVendorName());
-        Assert.assertEquals("version", connector.getResourceAdapterVersion());
-        Assert.assertEquals("smallIcon", connector.getIcon().getSmallIcon());
-        Assert.assertEquals("largeIcon", connector.getIcon().getLargeIcon());
-        Assert.assertEquals("licenseDescription", connector.getLicense().getDescription());
-        Assert.assertEquals(true, connector.getLicense().isLicenseRequired());
-
-        final List<org.apache.openejb.jee.SecurityPermission> securityPermission = connector.getResourceAdapter().getSecurityPermission();
-        Assert.assertEquals("description", securityPermission.get(0).getDescription());
-        Assert.assertEquals("permissionSpec", securityPermission.get(0).getSecurityPermissionSpec());
-
-        final List<String> requiredWorkContext = connector.getRequiredWorkContext();
-        Assert.assertEquals(TestWorkContext.class.getName(), requiredWorkContext.get(0));
-
-        final List<org.apache.openejb.jee.AuthenticationMechanism> authenticationMechanism = connector.getResourceAdapter().getOutboundResourceAdapter().getAuthenticationMechanism();
-        Assert.assertEquals("authMechanism", authenticationMechanism.get(0).getAuthenticationMechanismType());
-        Assert.assertEquals(CredentialInterface.GenericCredential.toString(), authenticationMechanism.get(0).getCredentialInterface());
-        Assert.assertEquals("description", authenticationMechanism.get(0).getDescription());
-
-        Assert.assertEquals(TransactionSupportType.NO_TRANSACTION, connector.getResourceAdapter().getOutboundResourceAdapter().getTransactionSupport());
-        Assert.assertEquals(true, connector.getResourceAdapter().getOutboundResourceAdapter().isReauthenticationSupport());
-
-        Assert.assertEquals(Connection.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionInterface());
-        Assert.assertEquals(ConnectionImpl.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionImplClass());
-        Assert.assertEquals(ConnectionFactory.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionFactoryInterface());
-        Assert.assertEquals(ConnectionFactoryImpl.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionFactoryImplClass());
-
-        Assert.assertEquals(TestActivation.class.getName(), connector.getResourceAdapter().getInboundResourceAdapter().getMessageAdapter().getMessageListener().get(0).getActivationSpec().getActivationSpecClass());
-        Assert.assertEquals(TestMessageListener.class.getName(), connector.getResourceAdapter().getInboundResourceAdapter().getMessageAdapter().getMessageListener().get(0).getMessageListenerType());
-
-        Assert.assertEquals(TestAdminObject.class.getName(), connector.getResourceAdapter().getAdminObject().get(0).getAdminObjectClass());
-        Assert.assertEquals(TestAdminObjectInterface.class.getName(), connector.getResourceAdapter().getAdminObject().get(0).getAdminObjectInterface());
-    }
-
-    private ConnectorModule testConnectorModule() {
-        final Connector connector = new Connector();
-        final ConnectorModule connectorModule = new ConnectorModule(connector);
-        connectorModule.setFinder(new ClassFinder(TestConnector.class, TestManagedConnectionFactory.class, TestActivation.class, TestAdminObject.class));
-        return connectorModule;
-    }
-
-    @Test
-    public void testConfigProperties() throws Exception {
-        final ClassFinder finder = new ClassFinder(TestAdminObject.class);
-
-        final List<ConfigProperty> configProperty = new ArrayList<ConfigProperty>();
-
-        final Object object = new Object() {
-            public List<ConfigProperty> getConfigProperty() {
-                return configProperty;
-            }
-        };
-
-        new AnnotationDeployer.DiscoverAnnotatedBeans().process(null, TestAdminObject.class.getName(), object);
-        Assert.assertEquals(2, configProperty.size());
-        Assert.assertEquals("myNumber", configProperty.get(0).getConfigPropertyName());
-        Assert.assertEquals("java.lang.Integer", configProperty.get(0).getConfigPropertyType());
-        Assert.assertEquals("myProperty", configProperty.get(1).getConfigPropertyName());
-        Assert.assertEquals("java.lang.String", configProperty.get(1).getConfigPropertyType());
-        Assert.assertEquals("This is a test", configProperty.get(1).getConfigPropertyValue());
-    }
-
-    @ApplicationException(rollback = true)
-    public abstract class BusinessException extends Exception {
-    }
-
-    public class ValueRequiredException extends BusinessException {
-    }
-
-    public static final class MyMainClass {
-        public static void main(final String[] args) {
-        }
-    }
-
-    public static interface GenericInterface<T> {
-        T genericMethod(T t);
-    }
-
-    @Stateless
-    @Local(GenericInterface.class)
-    public static class InterceptedSLSBean implements GenericInterface<String> {
-        public String genericMethod(final String s) {
-            return s;
-        }
-    }
-
-    @Stateless
-    @LocalBean
-    public static class TestLocalBean {
-        public String echo(final String input) {
-            return input;
-        }
-    }
-
-    @Resource
-    public static class Color {
-        @Resource
-        public void color() {
-        }
-    }
-
-    @Resource
-    public static class Green extends Color {
-        @Resource
-        public void green() {
-        }
-    }
-
-    @Resource
-    public static class Emerald extends Green {
-        @Resource
-        public void emerald() {
-        }
-    }
-
-    @javax.resource.spi.Connector(description = "description",
-        displayName = "displayName", smallIcon = "smallIcon",
-        largeIcon = "largeIcon", vendorName = "vendorName",
-        eisType = "eisType",
-        version = "version",
-        licenseDescription = {"licenseDescription"},
-        licenseRequired = true,
-        authMechanisms = {@AuthenticationMechanism(authMechanism = "authMechanism",
-            credentialInterface = CredentialInterface.GenericCredential, description = {"description"})},
-        reauthenticationSupport = true,
-        securityPermissions = {@SecurityPermission(permissionSpec = "permissionSpec", description = "description")},
-        transactionSupport = TransactionSupportLevel.NoTransaction,
-        requiredWorkContexts = {TestWorkContext.class}
-    )
-    public static class TestConnector implements ResourceAdapter {
-
-        public void endpointActivation(final MessageEndpointFactory mef, final ActivationSpec spec) throws ResourceException {
-        }
-
-        public void endpointDeactivation(final MessageEndpointFactory mef, final ActivationSpec spec) {
-        }
-
-        public XAResource[] getXAResources(final ActivationSpec[] specs) throws ResourceException {
-            return null;
-        }
-
-        public void start(final BootstrapContext ctx) throws ResourceAdapterInternalException {
-        }
-
-        public void stop() {
-        }
-    }
-
-    @ConnectionDefinition(connection = Connection.class, connectionFactory = ConnectionFactory.class, connectionImpl = ConnectionImpl.class, connectionFactoryImpl = ConnectionFactoryImpl.class)
-    public static class TestManagedConnectionFactory implements ManagedConnectionFactory {
-
-        public Object createConnectionFactory() throws ResourceException {
-            return null;
-        }
-
-        public Object createConnectionFactory(final ConnectionManager connectionManager) throws ResourceException {
-            return null;
-        }
-
-        public ManagedConnection createManagedConnection(final Subject subject, final ConnectionRequestInfo connectionRequestInfo) throws ResourceException {
-            return null;
-        }
-
-        public PrintWriter getLogWriter() throws ResourceException {
-            return null;
-        }
-
-        public ManagedConnection matchManagedConnections(final Set managedConnections, final Subject subject, final ConnectionRequestInfo connectionRequestInfo) throws ResourceException {
-            return null;
-        }
-
-        public void setLogWriter(final PrintWriter writer) throws ResourceException {
-        }
-
-    }
-
-    public static class TestWorkContext implements WorkContext {
-        public String getDescription() {
-            return "Description";
-        }
-
-        public String getName() {
-            return "Name";
-        }
-    }
-
-    public static interface Connection {
-    }
-
-    public static class ConnectionImpl implements Connection {
-    }
-
-    public static interface ConnectionFactory extends Serializable, Referenceable {
-    }
-
-    public static class ConnectionFactoryImpl implements ConnectionFactory {
-
-        public void setReference(final Reference reference) {
-        }
-
-        public Reference getReference() throws NamingException {
-            return null;
-        }
-    }
-
-    @Activation(messageListeners = {TestMessageListener.class})
-    public static class TestActivation implements ActivationSpec, Serializable {
-
-        public ResourceAdapter getResourceAdapter() {
-            return null;
-        }
-
-        public void setResourceAdapter(final ResourceAdapter arg0) throws ResourceException {
-        }
-
-        public void validate() throws InvalidPropertyException {
-        }
-    }
-
-    public static class TestMessageListener implements MessageListener {
-        public Record onMessage(final Record arg0) throws ResourceException {
-            return null;
-        }
-    }
-
-    public static interface TestAdminObjectInterface {
-    }
-
-    public static interface SomeOtherInterface {
-    }
-
-    @AdministeredObject(adminObjectInterfaces = {TestAdminObjectInterface.class})
-    public static class TestAdminObject implements TestAdminObjectInterface, SomeOtherInterface {
-        private String myProperty = "This is a test";
-
-        @javax.resource.spi.ConfigProperty(ignore = true)
-        private int myNumber;
-
-        public String getMyProperty() {
-            return myProperty;
-        }
-
-        public void setMyProperty(final String myProperty) {
-            this.myProperty = myProperty;
-        }
-
-        public int getMyNumber() {
-            return myNumber;
-        }
-
-        public void setMyNumber(final int myNumber) {
-            this.myNumber = myNumber;
-        }
-    }
-
-    @Test
-    public void findRestClasses() throws Exception {
-        final WebApp webApp = new WebApp();
-        webApp.setContextRoot("/");
-        webApp.setId("web");
-        webApp.setVersion("2.5");
-        WebModule webModule = new WebModule(webApp, webApp.getContextRoot(), Thread.currentThread().getContextClassLoader(), "myapp", webApp.getId());
-        webModule.setFinder(new AnnotationFinder(new ClassesArchive(RESTClass.class, RESTMethod.class, RESTApp.class)).link());
-
-        final AnnotationDeployer annotationDeployer = new AnnotationDeployer();
-        webModule = annotationDeployer.deploy(webModule);
-
-        final Set<String> classes = webModule.getRestClasses();
-        final Set<String> applications = webModule.getRestApplications();
-
-        assertEquals(1, classes.size());
-        assertTrue(classes.contains(RESTClass.class.getName()));
-        // assertTrue(classes.contains(RESTMethod.class.getName()));
-
-        assertEquals(1, applications.size());
-        assertEquals(RESTApp.class.getName(), applications.iterator().next());
-    }
-
-    @Path("/")
-    public static class RESTClass {
-
-    }
-
-    public static class RESTMethod extends RESTClass {
-        @Path("/method")
-        public void noop() {
-            // no-op
-        }
-    }
-
-    @ApplicationPath("/")
-    public static class RESTApp extends Application {
-        public java.util.Set<java.lang.Class<?>> getClasses() {
-            return new HashSet<Class<?>>() {{
-                add(RESTClass.class);
-                add(RESTMethod.class);
-            }};
-        }
-
-        public java.util.Set<java.lang.Object> getSingletons() {
-            return new HashSet<Object>() {{
-                add(new RESTMethod());
-                add(new RESTMethod());
-            }};
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.config;
+
+import org.apache.openejb.OpenEJB;
+import org.apache.openejb.assembler.classic.AppInfo;
+import org.apache.openejb.assembler.classic.Assembler;
+import org.apache.openejb.assembler.classic.ClientInfo;
+import org.apache.openejb.jee.AssemblyDescriptor;
+import org.apache.openejb.jee.ConfigProperty;
+import org.apache.openejb.jee.Connector;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.EnterpriseBean;
+import org.apache.openejb.jee.SessionBean;
+import org.apache.openejb.jee.TransactionSupportType;
+import org.apache.openejb.jee.WebApp;
+import org.apache.xbean.finder.Annotated;
+import org.apache.xbean.finder.AnnotationFinder;
+import org.apache.xbean.finder.ClassFinder;
+import org.apache.xbean.finder.archive.ClassesArchive;
+import org.junit.AfterClass;
+import org.junit.Assert;
+import org.junit.Test;
+
+import javax.annotation.Resource;
+import javax.ejb.ApplicationException;
+import javax.ejb.Local;
+import javax.ejb.LocalBean;
+import javax.ejb.Stateless;
+import javax.naming.NamingException;
+import javax.naming.Reference;
+import javax.resource.Referenceable;
+import javax.resource.ResourceException;
+import javax.resource.cci.MessageListener;
+import javax.resource.cci.Record;
+import javax.resource.spi.Activation;
+import javax.resource.spi.ActivationSpec;
+import javax.resource.spi.AdministeredObject;
+import javax.resource.spi.AuthenticationMechanism;
+import javax.resource.spi.AuthenticationMechanism.CredentialInterface;
+import javax.resource.spi.BootstrapContext;
+import javax.resource.spi.ConnectionDefinition;
+import javax.resource.spi.ConnectionManager;
+import javax.resource.spi.ConnectionRequestInfo;
+import javax.resource.spi.InvalidPropertyException;
+import javax.resource.spi.ManagedConnection;
+import javax.resource.spi.ManagedConnectionFactory;
+import javax.resource.spi.ResourceAdapter;
+import javax.resource.spi.ResourceAdapterInternalException;
+import javax.resource.spi.SecurityPermission;
+import javax.resource.spi.TransactionSupport.TransactionSupportLevel;
+import javax.resource.spi.endpoint.MessageEndpointFactory;
+import javax.resource.spi.work.WorkContext;
+import javax.security.auth.Subject;
+import javax.transaction.xa.XAResource;
+import javax.ws.rs.ApplicationPath;
+import javax.ws.rs.Path;
+import javax.ws.rs.core.Application;
+import java.io.PrintWriter;
+import java.io.Serializable;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.CoreMatchers.notNullValue;
+import static org.hamcrest.CoreMatchers.nullValue;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertThat;
+import static org.junit.Assert.assertTrue;
+
+/**
+ * @version $Rev$ $Date$
+ */
+public class AnnotationDeployerTest {
+
+    @AfterClass
+    public static void afterClass() throws Exception {
+        OpenEJB.destroy();
+    }
+
+    @Test
+    /**
+     *  For http://issues.apache.org/jira/browse/OPENEJB-980
+     */
+    public void applicationExceptionInheritanceTest() throws Exception {
+        EjbModule ejbModule = testModule();
+        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
+        ejbModule = discvrAnnBeans.deploy(ejbModule);
+
+        final AssemblyDescriptor assemblyDescriptor = ejbModule.getEjbJar().getAssemblyDescriptor();
+        org.apache.openejb.jee.ApplicationException appEx =
+            assemblyDescriptor.getApplicationException(BusinessException.class);
+        assertThat(appEx, notNullValue());
+        assertThat(appEx.getExceptionClass(), is(BusinessException.class.getName()));
+        assertThat(appEx.isRollback(), is(true));
+
+        //inheritance is now handled at runtime, only explicitly mentioned exceptions are in the assembly descriptor
+        appEx = assemblyDescriptor.getApplicationException(ValueRequiredException.class);
+        assertThat(appEx, nullValue());
+    }
+
+    private EjbModule testModule() {
+        final EjbJar ejbJar = new EjbJar("test-classes");
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        ejbModule.setFinder(new ClassFinder(AnnotationDeployerTest.class,
+            BusinessException.class,
+            Exception.class,
+            GenericInterface.class,
+            InterceptedSLSBean.class,
+            MyMainClass.class,
+            TestLocalBean.class,
+            ValueRequiredException.class
+        ));
+        return ejbModule;
+    }
+
+
+    @Test
+    public void testSortClasses() throws Exception {
+        final AnnotationFinder finder = new AnnotationFinder(new ClassesArchive(Emerald.class)).link();
+
+        final List<Annotated<Class<?>>> classes = finder.findMetaAnnotatedClasses(Resource.class);
+        assertTrue(classes.size() >= 3);
+
+        final List<Annotated<Class<?>>> sorted = AnnotationDeployer.sortClasses(classes);
+
+        assertTrue(sorted.size() >= 3);
+
+        assertEquals(Emerald.class, sorted.get(0).get());
+        assertEquals(Green.class, sorted.get(1).get());
+        assertEquals(Color.class, sorted.get(2).get());
+    }
+
+    @Test
+    public void testSortMethods() throws Exception {
+        final AnnotationFinder finder = new AnnotationFinder(new ClassesArchive(Emerald.class)).link();
+
+        final List<Annotated<Method>> classes = finder.findMetaAnnotatedMethods(Resource.class);
+        assertTrue(classes.size() >= 3);
+
+        final List<Annotated<Method>> sorted = AnnotationDeployer.sortMethods(classes);
+
+        assertTrue(sorted.size() >= 3);
+
+        assertEquals(Emerald.class, sorted.get(0).get().getDeclaringClass());
+        assertEquals(Green.class, sorted.get(1).get().getDeclaringClass());
+        assertEquals(Color.class, sorted.get(2).get().getDeclaringClass());
+    }
+
+    @Test
+    /**
+     *  For https://issues.apache.org/jira/browse/OPENEJB-1063
+     */
+    public void badMainClassFormatTest() throws Exception {
+        final ConfigurationFactory config = new ConfigurationFactory();
+        final Assembler assembler = new Assembler();
+
+        final AppModule app = new AppModule(this.getClass().getClassLoader(), "test-app");
+
+        final ClientModule clientModule = new ClientModule(null, app.getClassLoader(), app.getJarLocation(), null, null);
+
+        // change "." --> "/" to check that main class is changed by the AnnotationDeployer
+        final String mainClass = MyMainClass.class.getName().replaceAll("\\.", "/");
+        clientModule.setMainClass(mainClass);
+
+        app.getClientModules().add(clientModule);
+
+        final AppInfo appInfo = config.configureApplication(app);
+
+        assembler.createApplication(appInfo);
+
+        final ClientInfo clientInfo = appInfo.clients.get(0);
+        Assert.assertNotNull(clientInfo);
+        Assert.assertEquals(MyMainClass.class.getName(), clientInfo.mainClass);
+    }
+
+    /**
+     * For https://issues.apache.org/jira/browse/OPENEJB-1128
+     */
+    @Test
+    public void interceptingGenericBusinessMethodCalls() throws Exception {
+        EjbModule ejbModule = testModule();
+        final EjbJar ejbJar = ejbModule.getEjbJar();
+
+        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
+        ejbModule = discvrAnnBeans.deploy(ejbModule);
+
+        final EnterpriseBean bean = ejbJar.getEnterpriseBean("InterceptedSLSBean");
+        assert bean != null;
+    }
+
+    /**
+     * For https://issues.apache.org/jira/browse/OPENEJB-1188
+     *
+     * @throws Exception
+     */
+    @Test
+    public void testLocalBean() throws Exception {
+        final EjbModule ejbModule = testModule();
+        final EjbJar ejbJar = ejbModule.getEjbJar();
+
+        AppModule appModule = new AppModule(Thread.currentThread().getContextClassLoader(), "myapp");
+        appModule.getEjbModules().add(ejbModule);
+
+        final AnnotationDeployer annotationDeployer = new AnnotationDeployer();
+        appModule = annotationDeployer.deploy(appModule);
+
+        EnterpriseBean bean = ejbJar.getEnterpriseBean("TestLocalBean");
+        assert bean != null;
+        assert (((SessionBean) bean).getLocalBean() != null);
+
+        bean = ejbJar.getEnterpriseBean("InterceptedSLSBean");
+        assert bean != null;
+        assert (((SessionBean) bean).getLocalBean() == null);
+    }
+
+    @Test
+    public void testResourceAdapter() throws Exception {
+        final ConnectorModule connectorModule = testConnectorModule();
+        final AnnotationDeployer.DiscoverAnnotatedBeans discvrAnnBeans = new AnnotationDeployer.DiscoverAnnotatedBeans();
+        discvrAnnBeans.deploy(connectorModule);
+
+        final Connector connector = connectorModule.getConnector();
+        Assert.assertEquals("displayName", connector.getDisplayName());
+        Assert.assertEquals("description", connector.getDescription());
+        Assert.assertEquals("eisType", connector.getEisType());
+        Assert.assertEquals("vendorName", connector.getVendorName());
+        Assert.assertEquals("version", connector.getResourceAdapterVersion());
+        Assert.assertEquals("smallIcon", connector.getIcon().getSmallIcon());
+        Assert.assertEquals("largeIcon", connector.getIcon().getLargeIcon());
+        Assert.assertEquals("licenseDescription", connector.getLicense().getDescription());
+        Assert.assertEquals(true, connector.getLicense().isLicenseRequired());
+
+        final List<org.apache.openejb.jee.SecurityPermission> securityPermission = connector.getResourceAdapter().getSecurityPermission();
+        Assert.assertEquals("description", securityPermission.get(0).getDescription());
+        Assert.assertEquals("permissionSpec", securityPermission.get(0).getSecurityPermissionSpec());
+
+        final List<String> requiredWorkContext = connector.getRequiredWorkContext();
+        Assert.assertEquals(TestWorkContext.class.getName(), requiredWorkContext.get(0));
+
+        final List<org.apache.openejb.jee.AuthenticationMechanism> authenticationMechanism = connector.getResourceAdapter().getOutboundResourceAdapter().getAuthenticationMechanism();
+        Assert.assertEquals("authMechanism", authenticationMechanism.get(0).getAuthenticationMechanismType());
+        Assert.assertEquals(CredentialInterface.GenericCredential.toString(), authenticationMechanism.get(0).getCredentialInterface());
+        Assert.assertEquals("description", authenticationMechanism.get(0).getDescription());
+
+        Assert.assertEquals(TransactionSupportType.NO_TRANSACTION, connector.getResourceAdapter().getOutboundResourceAdapter().getTransactionSupport());
+        Assert.assertEquals(true, connector.getResourceAdapter().getOutboundResourceAdapter().isReauthenticationSupport());
+
+        Assert.assertEquals(Connection.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionInterface());
+        Assert.assertEquals(ConnectionImpl.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionImplClass());
+        Assert.assertEquals(ConnectionFactory.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionFactoryInterface());
+        Assert.assertEquals(ConnectionFactoryImpl.class.getName(), connector.getResourceAdapter().getOutboundResourceAdapter().getConnectionDefinition().get(0).getConnectionFactoryImplClass());
+
+        Assert.assertEquals(TestActivation.class.getName(), connector.getResourceAdapter().getInboundResourceAdapter().getMessageAdapter().getMessageListener().get(0).getActivationSpec().getActivationSpecClass());
+        Assert.assertEquals(TestMessageListener.class.getName(), connector.getResourceAdapter().getInboundResourceAdapter().getMessageAdapter().getMessageListener().get(0).getMessageListenerType());
+
+        Assert.assertEquals(TestAdminObject.class.getName(), connector.getResourceAdapter().getAdminObject().get(0).getAdminObjectClass());
+        Assert.assertEquals(TestAdminObjectInterface.class.getName(), connector.getResourceAdapter().getAdminObject().get(0).getAdminObjectInterface());
+    }
+
+    private ConnectorModule testConnectorModule() {
+        final Connector connector = new Connector();
+        final ConnectorModule connectorModule = new ConnectorModule(connector);
+        connectorModule.setFinder(new ClassFinder(TestConnector.class, TestManagedConnectionFactory.class, TestActivation.class, TestAdminObject.class));
+        return connectorModule;
+    }
+
+    @Test
+    public void testConfigProperties() throws Exception {
+        final ClassFinder finder = new ClassFinder(TestAdminObject.class);
+
+        final List<ConfigProperty> configProperty = new ArrayList<ConfigProperty>();
+
+        final Object object = new Object() {
+            public List<ConfigProperty> getConfigProperty() {
+                return configProperty;
+            }
+        };
+
+        new AnnotationDeployer.DiscoverAnnotatedBeans().process(null, TestAdminObject.class.getName(), object);
+        Assert.assertEquals(2, configProperty.size());
+        Assert.assertEquals("myNumber", configProperty.get(0).getConfigPropertyName());
+        Assert.assertEquals("java.lang.Integer", configProperty.get(0).getConfigPropertyType());
+        Assert.assertEquals("myProperty", configProperty.get(1).getConfigPropertyName());
+        Assert.assertEquals("java.lang.String", configProperty.get(1).getConfigPropertyType());
+        Assert.assertEquals("This is a test", configProperty.get(1).getConfigPropertyValue());
+    }
+
+    @ApplicationException(rollback = true)
+    public abstract class BusinessException extends Exception {
+    }
+
+    public class ValueRequiredException extends BusinessException {
+    }
+
+    public static final class MyMainClass {
+        public static void main(final String[] args) {
+        }
+    }
+
+    public static interface GenericInterface<T> {
+        T genericMethod(T t);
+    }
+
+    @Stateless
+    @Local(GenericInterface.class)
+    public static class InterceptedSLSBean implements GenericInterface<String> {
+        public String genericMethod(final String s) {
+            return s;
+        }
+    }
+
+    @Stateless
+    @LocalBean
+    public static class TestLocalBean {
+        public String echo(final String input) {
+            return input;
+        }
+    }
+
+    @Resource
+    public static class Color {
+        @Resource
+        public void color() {
+        }
+    }
+
+    @Resource
+    public static class Green extends Color {
+        @Resource
+        public void green() {
+        }
+    }
+
+    @Resource
+    public static class Emerald extends Green {
+        @Resource
+        public void emerald() {
+        }
+    }
+
+    @javax.resource.spi.Connector(description = "description",
+        displayName = "displayName", smallIcon = "smallIcon",
+        largeIcon = "largeIcon", vendorName = "vendorName",
+        eisType = "eisType",
+        version = "version",
+        licenseDescription = {"licenseDescription"},
+        licenseRequired = true,
+        authMechanisms = {@AuthenticationMechanism(authMechanism = "authMechanism",
+            credentialInterface = CredentialInterface.GenericCredential, description = {"description"})},
+        reauthenticationSupport = true,
+        securityPermissions = {@SecurityPermission(permissionSpec = "permissionSpec", description = "description")},
+        transactionSupport = TransactionSupportLevel.NoTransaction,
+        requiredWorkContexts = {TestWorkContext.class}
+    )
+    public static class TestConnector implements ResourceAdapter {
+
+        public void endpointActivation(final MessageEndpointFactory mef, final ActivationSpec spec) throws ResourceException {
+        }
+
+        public void endpointDeactivation(final MessageEndpointFactory mef, final ActivationSpec spec) {
+        }
+
+        public XAResource[] getXAResources(final ActivationSpec[] specs) throws ResourceException {
+            return null;
+        }
+
+        public void start(final BootstrapContext ctx) throws ResourceAdapterInternalException {
+        }
+
+        public void stop() {
+        }
+    }
+
+    @ConnectionDefinition(connection = Connection.class, connectionFactory = ConnectionFactory.class, connectionImpl = ConnectionImpl.class, connectionFactoryImpl = ConnectionFactoryImpl.class)
+    public static class TestManagedConnectionFactory implements ManagedConnectionFactory {
+
+        public Object createConnectionFactory() throws ResourceException {
+            return null;
+        }
+
+        public Object createConnectionFactory(final ConnectionManager connectionManager) throws ResourceException {
+            return null;
+        }
+
+        public ManagedConnection createManagedConnection(final Subject subject, final ConnectionRequestInfo connectionRequestInfo) throws ResourceException {
+            return null;
+        }
+
+        public PrintWriter getLogWriter() throws ResourceException {
+            return null;
+        }
+
+        public ManagedConnection matchManagedConnections(final Set managedConnections, final Subject subject, final ConnectionRequestInfo connectionRequestInfo) throws ResourceException {
+            return null;
+        }
+
+        public void setLogWriter(final PrintWriter writer) throws ResourceException {
+        }
+
+    }
+
+    public static class TestWorkContext implements WorkContext {
+        public String getDescription() {
+            return "Description";
+        }
+
+        public String getName() {
+            return "Name";
+        }
+    }
+
+    public static interface Connection {
+    }
+
+    public static class ConnectionImpl implements Connection {
+    }
+
+    public static interface ConnectionFactory extends Serializable, Referenceable {
+    }
+
+    public static class ConnectionFactoryImpl implements ConnectionFactory {
+
+        public void setReference(final Reference reference) {
+        }
+
+        public Reference getReference() throws NamingException {
+            return null;
+        }
+    }
+
+    @Activation(messageListeners = {TestMessageListener.class})
+    public static class TestActivation implements ActivationSpec, Serializable {
+
+        public ResourceAdapter getResourceAdapter() {
+            return null;
+        }
+
+        public void setResourceAdapter(final ResourceAdapter arg0) throws ResourceException {
+        }
+
+        public void validate() throws InvalidPropertyException {
+        }
+    }
+
+    public static class TestMessageListener implements MessageListener {
+        public Record onMessage(final Record arg0) throws ResourceException {
+            return null;
+        }
+    }
+
+    public static interface TestAdminObjectInterface {
+    }
+
+    public static interface SomeOtherInterface {
+    }
+
+    @AdministeredObject(adminObjectInterfaces = {TestAdminObjectInterface.class})
+    public static class TestAdminObject implements TestAdminObjectInterface, SomeOtherInterface {
+        private String myProperty = "This is a test";
+
+        @javax.resource.spi.ConfigProperty(ignore = true)
+        private int myNumber;
+
+        public String getMyProperty() {
+            return myProperty;
+        }
+
+        public void setMyProperty(final String myProperty) {
+            this.myProperty = myProperty;
+        }
+
+        public int getMyNumber() {
+            return myNumber;
+        }
+
+        public void setMyNumber(final int myNumber) {
+            this.myNumber = myNumber;
+        }
+    }
+
+    @Test
+    public void findRestClasses() throws Exception {
+        final WebApp webApp = new WebApp();
+        webApp.setContextRoot("/");
+        webApp.setId("web");
+        webApp.setVersion("2.5");
+        WebModule webModule = new WebModule(webApp, webApp.getContextRoot(), Thread.currentThread().getContextClassLoader(), "myapp", webApp.getId());
+        webModule.setFinder(new AnnotationFinder(new ClassesArchive(RESTClass.class, RESTMethod.class, RESTApp.class)).link());
+
+        final AnnotationDeployer annotationDeployer = new AnnotationDeployer();
+        webModule = annotationDeployer.deploy(webModule);
+
+        final Set<String> classes = webModule.getRestClasses();
+        final Set<String> applications = webModule.getRestApplications();
+
+        assertEquals(1, classes.size());
+        assertTrue(classes.contains(RESTClass.class.getName()));
+        // assertTrue(classes.contains(RESTMethod.class.getName()));
+
+        assertEquals(1, applications.size());
+        assertEquals(RESTApp.class.getName(), applications.iterator().next());
+    }
+
+    @Path("/")
+    public static class RESTClass {
+
+    }
+
+    public static class RESTMethod extends RESTClass {
+        @Path("/method")
+        public void noop() {
+            // no-op
+        }
+    }
+
+    @ApplicationPath("/")
+    public static class RESTApp extends Application {
+        public java.util.Set<java.lang.Class<?>> getClasses() {
+            return new HashSet<Class<?>>() {{
+                add(RESTClass.class);
+                add(RESTMethod.class);
+            }};
+        }
+
+        public java.util.Set<java.lang.Object> getSingletons() {
+            return new HashSet<Object>() {{
+                add(new RESTMethod());
+                add(new RESTMethod());
+            }};
+        }
+    }
+}


[05/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DescriptionGroup.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DescriptionGroup.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DescriptionGroup.java
index ab80eb7..0030801 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DescriptionGroup.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DescriptionGroup.java
@@ -1,340 +1,340 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 This group keeps the usage of the contained description
- * related elements consistent across J2EE deployment descriptors.
- * <p/>
- * <p/>
- * <p/>
- * Java class for DescriptionGroup complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="DescriptionGroup">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="icons" type="{common.xmi}IconType"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="displayNames" type="{common.xmi}DisplayName"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "DescriptionGroup", propOrder = {"icons", "displayNames",
-    "descriptions", "extensions"})
-public class DescriptionGroup {
-
-    protected List<IconType> icons;
-    protected List<DisplayName> displayNames;
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the icons property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the icons property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getIcons().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list {@link IconType }
-     */
-    public List<IconType> getIcons() {
-        if (icons == null) {
-            icons = new ArrayList<IconType>();
-        }
-        return this.icons;
-    }
-
-    /**
-     * Gets the value of the displayNames property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the displayNames property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDisplayNames().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link DisplayName }
-     */
-    public List<DisplayName> getDisplayNames() {
-        if (displayNames == null) {
-            displayNames = new ArrayList<DisplayName>();
-        }
-        return this.displayNames;
-    }
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 This group keeps the usage of the contained description
+ * related elements consistent across J2EE deployment descriptors.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for DescriptionGroup complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="DescriptionGroup">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="icons" type="{common.xmi}IconType"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="displayNames" type="{common.xmi}DisplayName"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "DescriptionGroup", propOrder = {"icons", "displayNames",
+    "descriptions", "extensions"})
+public class DescriptionGroup {
+
+    protected List<IconType> icons;
+    protected List<DisplayName> displayNames;
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the icons property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the icons property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getIcons().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list {@link IconType }
+     */
+    public List<IconType> getIcons() {
+        if (icons == null) {
+            icons = new ArrayList<IconType>();
+        }
+        return this.icons;
+    }
+
+    /**
+     * Gets the value of the displayNames property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the displayNames property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDisplayNames().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link DisplayName }
+     */
+    public List<DisplayName> getDisplayNames() {
+        if (displayNames == null) {
+            displayNames = new ArrayList<DisplayName>();
+        }
+        return this.displayNames;
+    }
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DisplayName.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DisplayName.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DisplayName.java
index e09224f..4f1c114 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DisplayName.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/DisplayName.java
@@ -1,300 +1,300 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 The display-name type contains a short name that is intended
- * to be displayed by tools. It is used by display-name elements. The
- * display name need not be unique.
- * <p/>
- * Example:
- * <p/>
- * ...
- * <p/>
- * <pre>
- * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;display-name xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xml:lang="en"&gt;
- *
- * 					Employee Self Service
- *
- * 				&lt;/display-name&gt;
- * </pre>
- * <p/>
- * <p/>
- * The value of the xml:lang attribute is "en" (English) by default.
- * <p/>
- * <p/>
- * <p/>
- * Java class for DisplayName complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="DisplayName">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "DisplayName", propOrder = {"extensions"})
-public class DisplayName {
-
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String lang;
-    @XmlAttribute
-    protected String value;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the lang property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLang() {
-        return lang;
-    }
-
-    /**
-     * Sets the value of the lang property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLang(final String value) {
-        this.lang = value;
-    }
-
-    /**
-     * Gets the value of the value property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getValue() {
-        return value;
-    }
-
-    /**
-     * Sets the value of the value property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setValue(final String value) {
-        this.value = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 The display-name type contains a short name that is intended
+ * to be displayed by tools. It is used by display-name elements. The
+ * display name need not be unique.
+ * <p/>
+ * Example:
+ * <p/>
+ * ...
+ * <p/>
+ * <pre>
+ * &lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;display-name xmlns:com.ibm.etools.j2ee.common="common.xmi" xmlns:com.ibm.etools.webservice.wsclient="webservice_client.xmi" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:org.eclipse.jem.java="java.xmi" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xml:lang="en"&gt;
+ *
+ * 					Employee Self Service
+ *
+ * 				&lt;/display-name&gt;
+ * </pre>
+ * <p/>
+ * <p/>
+ * The value of the xml:lang attribute is "en" (English) by default.
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for DisplayName complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="DisplayName">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "DisplayName", propOrder = {"extensions"})
+public class DisplayName {
+
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String lang;
+    @XmlAttribute
+    protected String value;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the lang property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLang() {
+        return lang;
+    }
+
+    /**
+     * Sets the value of the lang property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLang(final String value) {
+        this.lang = value;
+    }
+
+    /**
+     * Gets the value of the value property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getValue() {
+        return value;
+    }
+
+    /**
+     * Sets the value of the value property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setValue(final String value) {
+        this.value = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EJBLocalRef.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EJBLocalRef.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EJBLocalRef.java
index 59546fc..b5a6c4f 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EJBLocalRef.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EJBLocalRef.java
@@ -1,99 +1,99 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-/**
- * @since J2EE1.3 The ejb-local-refType is used by ejb-local-ref elements for
- * the declaration of a reference to an enterprise bean's local home. The
- * declaration consists of:
- * <p/>
- * - an optional description - the EJB reference name used in the code of
- * the Deployment Component that's referencing the enterprise bean - the
- * expected type of the referenced enterprise bean - the expected local
- * home and local interfaces of the referenced enterprise bean - optional
- * ejb-link information, used to specify the referenced enterprise bean
- * <p/>
- * <p/>
- * <p/>
- * Java class for EJBLocalRef complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="EJBLocalRef">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}EjbRef">
- *       &lt;attribute name="local" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="localHome" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "EJBLocalRef")
-public class EJBLocalRef extends EjbRef {
-
-    @XmlAttribute
-    protected String local;
-    @XmlAttribute
-    protected String localHome;
-
-    /**
-     * Gets the value of the local property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLocal() {
-        return local;
-    }
-
-    /**
-     * Sets the value of the local property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLocal(final String value) {
-        this.local = value;
-    }
-
-    /**
-     * Gets the value of the localHome property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLocalHome() {
-        return localHome;
-    }
-
-    /**
-     * Sets the value of the localHome property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLocalHome(final String value) {
-        this.localHome = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * @since J2EE1.3 The ejb-local-refType is used by ejb-local-ref elements for
+ * the declaration of a reference to an enterprise bean's local home. The
+ * declaration consists of:
+ * <p/>
+ * - an optional description - the EJB reference name used in the code of
+ * the Deployment Component that's referencing the enterprise bean - the
+ * expected type of the referenced enterprise bean - the expected local
+ * home and local interfaces of the referenced enterprise bean - optional
+ * ejb-link information, used to specify the referenced enterprise bean
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for EJBLocalRef complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="EJBLocalRef">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}EjbRef">
+ *       &lt;attribute name="local" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="localHome" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "EJBLocalRef")
+public class EJBLocalRef extends EjbRef {
+
+    @XmlAttribute
+    protected String local;
+    @XmlAttribute
+    protected String localHome;
+
+    /**
+     * Gets the value of the local property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLocal() {
+        return local;
+    }
+
+    /**
+     * Sets the value of the local property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLocal(final String value) {
+        this.local = value;
+    }
+
+    /**
+     * Gets the value of the localHome property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLocalHome() {
+        return localHome;
+    }
+
+    /**
+     * Sets the value of the localHome property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLocalHome(final String value) {
+        this.localHome = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRef.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRef.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRef.java
index 61065f4..0a7f818 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRef.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRef.java
@@ -1,408 +1,408 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The ejb-refType is used by ejb-ref elements for the declaration of a
- * reference to an enterprise bean's home. The declaration consists of:
- * <p/>
- * - an optional description - the EJB reference name used in the code of the
- * Deployment Component that's referencing the enterprise bean - the expected
- * type of the referenced enterprise bean - the expected home and remote
- * interfaces of the referenced enterprise bean - optional ejb-link information,
- * used to specify the referenced enterprise bean
- * <p/>
- * <p/>
- * <p/>
- * Java class for EjbRef complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="EjbRef">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element name="descriptions" type="{common.xmi}Description"/>
- *         &lt;/choice>
- *         &lt;choice maxOccurs="unbounded" minOccurs="0">
- *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *         &lt;/choice>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="home" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="remote" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="type" type="{common.xmi}EjbRefType" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "EjbRef", propOrder = {"descriptions", "extensions"})
-public class EjbRef {
-
-    protected List<Description> descriptions;
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String home;
-    @XmlAttribute
-    protected String link;
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected String remote;
-    @XmlAttribute(name = "type")
-    protected EjbRefEnum ejbRefType;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the descriptions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the descriptions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getDescriptions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Description }
-     */
-    public List<Description> getDescriptions() {
-        if (descriptions == null) {
-            descriptions = new ArrayList<Description>();
-        }
-        return this.descriptions;
-    }
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the home property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHome() {
-        return home;
-    }
-
-    /**
-     * Sets the value of the home property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHome(final String value) {
-        this.home = value;
-    }
-
-    /**
-     * Gets the value of the link property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLink() {
-        return link;
-    }
-
-    /**
-     * Sets the value of the link property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLink(final String value) {
-        this.link = value;
-    }
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the remote property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getRemote() {
-        return remote;
-    }
-
-    /**
-     * Sets the value of the remote property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setRemote(final String value) {
-        this.remote = value;
-    }
-
-    /**
-     * Gets the value of the ejbRefType property.
-     *
-     * @return possible object is {@link EjbRefEnum }
-     */
-    public EjbRefEnum getEjbRefType() {
-        return ejbRefType;
-    }
-
-    /**
-     * Sets the value of the ejbRefType property.
-     *
-     * @param value allowed object is {@link EjbRefEnum }
-     */
-    public void setEjbRefType(final EjbRefEnum value) {
-        this.ejbRefType = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * The ejb-refType is used by ejb-ref elements for the declaration of a
+ * reference to an enterprise bean's home. The declaration consists of:
+ * <p/>
+ * - an optional description - the EJB reference name used in the code of the
+ * Deployment Component that's referencing the enterprise bean - the expected
+ * type of the referenced enterprise bean - the expected home and remote
+ * interfaces of the referenced enterprise bean - optional ejb-link information,
+ * used to specify the referenced enterprise bean
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for EjbRef complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="EjbRef">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element name="descriptions" type="{common.xmi}Description"/>
+ *         &lt;/choice>
+ *         &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *           &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *         &lt;/choice>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="home" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="link" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="remote" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="type" type="{common.xmi}EjbRefType" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "EjbRef", propOrder = {"descriptions", "extensions"})
+public class EjbRef {
+
+    protected List<Description> descriptions;
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String home;
+    @XmlAttribute
+    protected String link;
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected String remote;
+    @XmlAttribute(name = "type")
+    protected EjbRefEnum ejbRefType;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the descriptions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the descriptions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getDescriptions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Description }
+     */
+    public List<Description> getDescriptions() {
+        if (descriptions == null) {
+            descriptions = new ArrayList<Description>();
+        }
+        return this.descriptions;
+    }
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the home property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHome() {
+        return home;
+    }
+
+    /**
+     * Sets the value of the home property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHome(final String value) {
+        this.home = value;
+    }
+
+    /**
+     * Gets the value of the link property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLink() {
+        return link;
+    }
+
+    /**
+     * Sets the value of the link property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLink(final String value) {
+        this.link = value;
+    }
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the remote property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getRemote() {
+        return remote;
+    }
+
+    /**
+     * Sets the value of the remote property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setRemote(final String value) {
+        this.remote = value;
+    }
+
+    /**
+     * Gets the value of the ejbRefType property.
+     *
+     * @return possible object is {@link EjbRefEnum }
+     */
+    public EjbRefEnum getEjbRefType() {
+        return ejbRefType;
+    }
+
+    /**
+     * Sets the value of the ejbRefType property.
+     *
+     * @param value allowed object is {@link EjbRefEnum }
+     */
+    public void setEjbRefType(final EjbRefEnum value) {
+        this.ejbRefType = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRefEnum.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRefEnum.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRefEnum.java
index 0afa577..b62fb86 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRefEnum.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/EjbRefEnum.java
@@ -1,65 +1,65 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlEnumValue;
-
-/**
- * <p/>
- * Java class for EjbRefType.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <p/>
- * <pre>
- * &lt;simpleType name="EjbRefType">
- *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
- *     &lt;enumeration value="Session"/>
- *     &lt;enumeration value="Entity"/>
- *   &lt;/restriction>
- * &lt;/simpleType>
- * </pre>
- */
-@XmlEnum
-public enum EjbRefEnum {
-
-    @XmlEnumValue("Session")
-    SESSION("Session"), @XmlEnumValue("Entity")
-    ENTITY("Entity");
-    private final String value;
-
-    EjbRefEnum(final String v) {
-        value = v;
-    }
-
-    public String value() {
-        return value;
-    }
-
-    public static EjbRefEnum fromValue(final String v) {
-        for (final EjbRefEnum c : EjbRefEnum.values()) {
-            if (c.value.equals(v)) {
-                return c;
-            }
-        }
-        throw new IllegalArgumentException(v.toString());
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+
+/**
+ * <p/>
+ * Java class for EjbRefType.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <p/>
+ * <pre>
+ * &lt;simpleType name="EjbRefType">
+ *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}NCName">
+ *     &lt;enumeration value="Session"/>
+ *     &lt;enumeration value="Entity"/>
+ *   &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ */
+@XmlEnum
+public enum EjbRefEnum {
+
+    @XmlEnumValue("Session")
+    SESSION("Session"), @XmlEnumValue("Entity")
+    ENTITY("Entity");
+    private final String value;
+
+    EjbRefEnum(final String v) {
+        value = v;
+    }
+
+    public String value() {
+        return value;
+    }
+
+    public static EjbRefEnum fromValue(final String v) {
+        for (final EjbRefEnum c : EjbRefEnum.values()) {
+            if (c.value.equals(v)) {
+                return c;
+            }
+        }
+        throw new IllegalArgumentException(v.toString());
+    }
+
+}


[09/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceUnitUsageTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceUnitUsageTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceUnitUsageTest.java
index b0c8142..df4e669 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceUnitUsageTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckPersistenceUnitUsageTest.java
@@ -1,96 +1,96 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.config.PersistenceModule;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
-import org.junit.runner.RunWith;
-
-import javax.persistence.EntityManager;
-import javax.persistence.EntityManagerFactory;
-
-@RunWith(ValidationRunner.class)
-public class CheckPersistenceUnitUsageTest {
-    @Keys({@Key(value = "persistenceUnitRef.noPersistenceUnits", count = 3), @Key("persistenceUnitAnnotation.onClassWithNoName"),
-        @Key("persistenceUnitAnnotation.onEntityManager"), @Key("persistenceUnitAnnotation.onNonEntityManagerFactory")})
-    public EjbJar wrongUsage() throws OpenEJBException {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
-        return ejbJar;
-    }
-
-    @Keys({@Key(value = "persistenceUnitRef.noMatches"), @Key(value = "persistenceUnitRef.noUnitName")})
-    public AppModule noUnitName() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessOne.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
-        appModule.getEjbModules().add(ejbModule);
-        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
-        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit1");
-        final PersistenceUnit pu2 = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu, pu1, pu2);
-        final PersistenceModule pm = new PersistenceModule("foo", p);
-        appModule.addPersistenceModule(pm);
-        return appModule;
-    }
-
-    @Keys({@Key(value = "persistenceUnitRef.vagueMatches")})
-    public AppModule vagueMatches() {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessTwo.class));
-        final EjbModule ejbModule = new EjbModule(ejbJar);
-        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
-        appModule.getEjbModules().add(ejbModule);
-        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu);
-        final PersistenceModule pm = new PersistenceModule("foo", p);
-        appModule.getPersistenceModules().add(pm);
-        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit");
-        final org.apache.openejb.jee.jpa.unit.Persistence p1 = new org.apache.openejb.jee.jpa.unit.Persistence(pu1);
-        final PersistenceModule pm1 = new PersistenceModule("foo1", p1);
-        appModule.addPersistenceModule(pm1);
-        return appModule;
-    }
-
-    @javax.persistence.PersistenceUnit
-    private static class FooStateless {
-        @javax.persistence.PersistenceUnit
-        EntityManagerFactory emf;
-        @javax.persistence.PersistenceUnit
-        EntityManager em;
-        @javax.persistence.PersistenceUnit
-        String nonEntityManagerFactory;
-    }
-
-    private static class FooStatelessOne {
-        @javax.persistence.PersistenceUnit(unitName = "wrongName")
-        EntityManagerFactory emf;
-        @javax.persistence.PersistenceUnit
-        EntityManagerFactory emf1;
-    }
-
-    private static class FooStatelessTwo {
-        @javax.persistence.PersistenceUnit(unitName = "fooUnit")
-        EntityManagerFactory emf;
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.config.PersistenceModule;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
+import org.junit.runner.RunWith;
+
+import javax.persistence.EntityManager;
+import javax.persistence.EntityManagerFactory;
+
+@RunWith(ValidationRunner.class)
+public class CheckPersistenceUnitUsageTest {
+    @Keys({@Key(value = "persistenceUnitRef.noPersistenceUnits", count = 3), @Key("persistenceUnitAnnotation.onClassWithNoName"),
+        @Key("persistenceUnitAnnotation.onEntityManager"), @Key("persistenceUnitAnnotation.onNonEntityManagerFactory")})
+    public EjbJar wrongUsage() throws OpenEJBException {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
+        return ejbJar;
+    }
+
+    @Keys({@Key(value = "persistenceUnitRef.noMatches"), @Key(value = "persistenceUnitRef.noUnitName")})
+    public AppModule noUnitName() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessOne.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
+        appModule.getEjbModules().add(ejbModule);
+        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
+        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit1");
+        final PersistenceUnit pu2 = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu, pu1, pu2);
+        final PersistenceModule pm = new PersistenceModule("foo", p);
+        appModule.addPersistenceModule(pm);
+        return appModule;
+    }
+
+    @Keys({@Key(value = "persistenceUnitRef.vagueMatches")})
+    public AppModule vagueMatches() {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStatelessTwo.class));
+        final EjbModule ejbModule = new EjbModule(ejbJar);
+        final AppModule appModule = new AppModule(ejbModule.getClassLoader(), ejbModule.getJarLocation());
+        appModule.getEjbModules().add(ejbModule);
+        final PersistenceUnit pu = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p = new org.apache.openejb.jee.jpa.unit.Persistence(pu);
+        final PersistenceModule pm = new PersistenceModule("foo", p);
+        appModule.getPersistenceModules().add(pm);
+        final PersistenceUnit pu1 = new PersistenceUnit("fooUnit");
+        final org.apache.openejb.jee.jpa.unit.Persistence p1 = new org.apache.openejb.jee.jpa.unit.Persistence(pu1);
+        final PersistenceModule pm1 = new PersistenceModule("foo1", p1);
+        appModule.addPersistenceModule(pm1);
+        return appModule;
+    }
+
+    @javax.persistence.PersistenceUnit
+    private static class FooStateless {
+        @javax.persistence.PersistenceUnit
+        EntityManagerFactory emf;
+        @javax.persistence.PersistenceUnit
+        EntityManager em;
+        @javax.persistence.PersistenceUnit
+        String nonEntityManagerFactory;
+    }
+
+    private static class FooStatelessOne {
+        @javax.persistence.PersistenceUnit(unitName = "wrongName")
+        EntityManagerFactory emf;
+        @javax.persistence.PersistenceUnit
+        EntityManagerFactory emf1;
+    }
+
+    private static class FooStatelessTwo {
+        @javax.persistence.PersistenceUnit(unitName = "fooUnit")
+        EntityManagerFactory emf;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckWrongClassTypeTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckWrongClassTypeTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckWrongClassTypeTest.java
index 96fb35c..4bdb585 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckWrongClassTypeTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/CheckWrongClassTypeTest.java
@@ -1,41 +1,41 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.EntityBean;
-import org.apache.openejb.jee.PersistenceType;
-import org.junit.runner.RunWith;
-
-@RunWith(ValidationRunner.class)
-public class CheckWrongClassTypeTest {
-    @Keys({@Key("wrong.class.type"), @Key("noInterfaceDeclared.entity")})
-    public EjbJar wrongClassType() throws OpenEJBException {
-        System.setProperty("openejb.validation.output.level", "VERBOSE");
-        final EjbJar ejbJar = new EjbJar();
-        final EntityBean entityBean = new EntityBean();
-        entityBean.setEjbClass(FooEntity.class);
-        entityBean.setEjbName("fooEntity");
-        entityBean.setPersistenceType(PersistenceType.BEAN);
-        ejbJar.addEnterpriseBean(entityBean);
-        return ejbJar;
-    }
-
-    private static class FooEntity {
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.EntityBean;
+import org.apache.openejb.jee.PersistenceType;
+import org.junit.runner.RunWith;
+
+@RunWith(ValidationRunner.class)
+public class CheckWrongClassTypeTest {
+    @Keys({@Key("wrong.class.type"), @Key("noInterfaceDeclared.entity")})
+    public EjbJar wrongClassType() throws OpenEJBException {
+        System.setProperty("openejb.validation.output.level", "VERBOSE");
+        final EjbJar ejbJar = new EjbJar();
+        final EntityBean entityBean = new EntityBean();
+        entityBean.setEjbClass(FooEntity.class);
+        entityBean.setEjbName("fooEntity");
+        entityBean.setPersistenceType(PersistenceType.BEAN);
+        ejbJar.addEnterpriseBean(entityBean);
+        return ejbJar;
+    }
+
+    private static class FooEntity {
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/InvokeMethod.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/InvokeMethod.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/InvokeMethod.java
index ca7a751..7ef0dbd 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/InvokeMethod.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/InvokeMethod.java
@@ -1,201 +1,201 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.assembler.classic.Assembler;
-import org.apache.openejb.assembler.classic.SecurityServiceInfo;
-import org.apache.openejb.assembler.classic.TransactionServiceInfo;
-import org.apache.openejb.config.AppModule;
-import org.apache.openejb.config.ConfigurationFactory;
-import org.apache.openejb.config.EjbModule;
-import org.apache.openejb.config.OutputGeneratedDescriptors;
-import org.apache.openejb.config.ValidationContext;
-import org.apache.openejb.config.ValidationFailedException;
-import org.apache.openejb.config.ValidationFailure;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.loader.SystemInstance;
-import org.apache.openejb.util.Join;
-import org.junit.runners.model.FrameworkMethod;
-import org.junit.runners.model.Statement;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Map.Entry;
-import java.util.ResourceBundle;
-import java.util.Set;
-
-import static org.apache.openejb.config.rules.ValidationAssertions.assertErrors;
-import static org.apache.openejb.config.rules.ValidationAssertions.assertFailures;
-import static org.apache.openejb.config.rules.ValidationAssertions.assertWarnings;
-import static org.junit.Assert.fail;
-
-/**
- * This Statement is the one which runs the test.
- */
-public class InvokeMethod extends Statement {
-    private ConfigurationFactory config;
-    private Assembler assembler;
-    // The test method
-    private final FrameworkMethod testMethod;
-    // The TestCase instance
-    private final Object target;
-    // These are all the keys defined in org.apache.openejb.config.rules.Messages.properties
-    private static final Set<String> allKeys;
-
-    static {
-        final ResourceBundle bundle = ResourceBundle.getBundle("org.apache.openejb.config.rules.Messages");
-        allKeys = bundle.keySet();
-    }
-
-    public InvokeMethod(final FrameworkMethod testMethod, final Object target) {
-        this.testMethod = testMethod;
-        this.target = target;
-    }
-
-    @Override
-    public void evaluate() throws Throwable {
-        final Map<Integer, List<String>> expectedKeys = validateKeys();
-        setUp();
-        final Object obj = testMethod.invokeExplosively(target);
-
-        final String outputDescriptors = SystemInstance.get().getProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, "false");
-        try {
-            SystemInstance.get().setProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, "false");
-
-            ValidationContext vc = null;
-            if (obj instanceof EjbJar) {
-                final EjbJar ejbJar = (EjbJar) obj;
-                final EjbModule ejbModule = new EjbModule(ejbJar);
-                vc = ejbModule.getValidation();
-                assembler.createApplication(config.configureApplication(ejbModule));
-            } else if (obj instanceof EjbModule) {
-                final EjbModule ejbModule = (EjbModule) obj;
-                vc = ejbModule.getValidation();
-                assembler.createApplication(config.configureApplication(ejbModule));
-            } else if (obj instanceof AppModule) {
-                final AppModule appModule = (AppModule) obj;
-                vc = appModule.getValidation();
-                assembler.createApplication(config.configureApplication(appModule));
-            }
-            if (!isEmpty(expectedKeys)) {
-                if (vc != null && expectedKeys.get(KeyType.FAILURE).isEmpty() && expectedKeys.get(KeyType.ERROR).isEmpty()) {
-                    if (!expectedKeys.get(KeyType.WARNING).isEmpty()) {
-                        assertWarnings(expectedKeys.get(KeyType.WARNING), new ValidationFailedException("", vc));
-                    }
-                } else {
-                    fail("A ValidationFailedException should have been thrown");
-                }
-            }
-        } catch (final ValidationFailedException vfe) {
-            if (!isEmpty(expectedKeys)) {
-                if (!expectedKeys.get(KeyType.FAILURE).isEmpty()) {
-                    assertFailures(expectedKeys.get(KeyType.FAILURE), vfe);
-                }
-                if (!expectedKeys.get(KeyType.WARNING).isEmpty()) {
-                    assertWarnings(expectedKeys.get(KeyType.WARNING), vfe);
-                }
-                if (!expectedKeys.get(KeyType.ERROR).isEmpty()) {
-                    assertErrors(expectedKeys.get(KeyType.ERROR), vfe);
-                }
-            } else {
-                for (final ValidationFailure failure : vfe.getFailures()) {
-                    System.out.println("failure = " + failure.getMessageKey());
-                }
-                fail("There should be no validation failures");
-            }
-        } finally {
-            SystemInstance.get().setProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, outputDescriptors);
-        }
-
-        tearDown();
-    }
-
-    private void setUp() throws Exception {
-        config = new ConfigurationFactory();
-        assembler = new Assembler();
-        assembler.createTransactionManager(config.configureService(TransactionServiceInfo.class));
-        assembler.createSecurityService(config.configureService(SecurityServiceInfo.class));
-    }
-
-    private void tearDown() {
-    }
-
-    /**
-     * Tests to see if the keys specified in the @Keys annotation are also available in the org.apache.openejb.config.rules.Messages.properties file. If there are any invalid keys,
-     * then it throws an exception and causes the test to error out. If all the keys are valid, then it returns those keys. This list of keys can then be compared with all the Keys
-     * in org.apache.openejb.config.rules.Messages.properties and one can then find out the "test coverage" of the keys i.e. this tool can be used to find keys for which tests have
-     * not yet been written
-     *
-     * @return
-     * @throws Exception
-     */
-    private Map<Integer, List<String>> validateKeys() throws Exception {
-        final Keys annotation = testMethod.getAnnotation(Keys.class);
-        final Key[] keys = annotation.value();
-        final ArrayList<String> wrongKeys = new ArrayList<String>();
-        for (final Key key : keys) {
-            if (allKeys.contains("1." + key.value())) {
-                continue;
-            } else {
-                wrongKeys.add(key.value());
-            }
-        }
-        if (wrongKeys.isEmpty()) {
-            final Map<Integer, List<String>> validKeys = new HashMap<Integer, List<String>>();
-            final ArrayList<String> failureKeys = new ArrayList<String>();
-            final ArrayList<String> warningKeys = new ArrayList<String>();
-            final ArrayList<String> errorKeys = new ArrayList<String>();
-            for (final Key key : keys) {
-                for (int i = 0; i < key.count(); i++) {
-                    switch (key.type()) {
-                        case KeyType.FAILURE:
-                            failureKeys.add(key.value());
-                            break;
-                        case KeyType.WARNING:
-                            warningKeys.add(key.value());
-                            break;
-                        case KeyType.ERROR:
-                            errorKeys.add(key.value());
-                            break;
-                    }
-                }
-            }
-            validKeys.put(KeyType.FAILURE, failureKeys);
-            validKeys.put(KeyType.WARNING, warningKeys);
-            validKeys.put(KeyType.ERROR, errorKeys);
-            return validKeys;
-        } else {
-            final String commaDelimitedKeys = Join.join(",", wrongKeys);
-            throw new Exception("The following keys listed in the @Keys annotation on the method " + testMethod.getName() + "() of " + testMethod.getMethod().getDeclaringClass()
-                + " are invalid : " + commaDelimitedKeys
-                + " . Only keys listed in org.apache.openejb.config.rules.Messages.properties are allowed to be used in this annotation. ");
-        }
-    }
-
-    private boolean isEmpty(final Map<Integer, List<String>> expectedKeys) {
-        boolean empty = true;
-        final Set<Entry<Integer, List<String>>> entrySet = expectedKeys.entrySet();
-        for (final Entry<Integer, List<String>> entry : entrySet) {
-            empty = entry.getValue().size() == 0;
-            if (!empty)
-                return empty;
-        }
-        return empty;
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.assembler.classic.Assembler;
+import org.apache.openejb.assembler.classic.SecurityServiceInfo;
+import org.apache.openejb.assembler.classic.TransactionServiceInfo;
+import org.apache.openejb.config.AppModule;
+import org.apache.openejb.config.ConfigurationFactory;
+import org.apache.openejb.config.EjbModule;
+import org.apache.openejb.config.OutputGeneratedDescriptors;
+import org.apache.openejb.config.ValidationContext;
+import org.apache.openejb.config.ValidationFailedException;
+import org.apache.openejb.config.ValidationFailure;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.loader.SystemInstance;
+import org.apache.openejb.util.Join;
+import org.junit.runners.model.FrameworkMethod;
+import org.junit.runners.model.Statement;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+import java.util.ResourceBundle;
+import java.util.Set;
+
+import static org.apache.openejb.config.rules.ValidationAssertions.assertErrors;
+import static org.apache.openejb.config.rules.ValidationAssertions.assertFailures;
+import static org.apache.openejb.config.rules.ValidationAssertions.assertWarnings;
+import static org.junit.Assert.fail;
+
+/**
+ * This Statement is the one which runs the test.
+ */
+public class InvokeMethod extends Statement {
+    private ConfigurationFactory config;
+    private Assembler assembler;
+    // The test method
+    private final FrameworkMethod testMethod;
+    // The TestCase instance
+    private final Object target;
+    // These are all the keys defined in org.apache.openejb.config.rules.Messages.properties
+    private static final Set<String> allKeys;
+
+    static {
+        final ResourceBundle bundle = ResourceBundle.getBundle("org.apache.openejb.config.rules.Messages");
+        allKeys = bundle.keySet();
+    }
+
+    public InvokeMethod(final FrameworkMethod testMethod, final Object target) {
+        this.testMethod = testMethod;
+        this.target = target;
+    }
+
+    @Override
+    public void evaluate() throws Throwable {
+        final Map<Integer, List<String>> expectedKeys = validateKeys();
+        setUp();
+        final Object obj = testMethod.invokeExplosively(target);
+
+        final String outputDescriptors = SystemInstance.get().getProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, "false");
+        try {
+            SystemInstance.get().setProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, "false");
+
+            ValidationContext vc = null;
+            if (obj instanceof EjbJar) {
+                final EjbJar ejbJar = (EjbJar) obj;
+                final EjbModule ejbModule = new EjbModule(ejbJar);
+                vc = ejbModule.getValidation();
+                assembler.createApplication(config.configureApplication(ejbModule));
+            } else if (obj instanceof EjbModule) {
+                final EjbModule ejbModule = (EjbModule) obj;
+                vc = ejbModule.getValidation();
+                assembler.createApplication(config.configureApplication(ejbModule));
+            } else if (obj instanceof AppModule) {
+                final AppModule appModule = (AppModule) obj;
+                vc = appModule.getValidation();
+                assembler.createApplication(config.configureApplication(appModule));
+            }
+            if (!isEmpty(expectedKeys)) {
+                if (vc != null && expectedKeys.get(KeyType.FAILURE).isEmpty() && expectedKeys.get(KeyType.ERROR).isEmpty()) {
+                    if (!expectedKeys.get(KeyType.WARNING).isEmpty()) {
+                        assertWarnings(expectedKeys.get(KeyType.WARNING), new ValidationFailedException("", vc));
+                    }
+                } else {
+                    fail("A ValidationFailedException should have been thrown");
+                }
+            }
+        } catch (final ValidationFailedException vfe) {
+            if (!isEmpty(expectedKeys)) {
+                if (!expectedKeys.get(KeyType.FAILURE).isEmpty()) {
+                    assertFailures(expectedKeys.get(KeyType.FAILURE), vfe);
+                }
+                if (!expectedKeys.get(KeyType.WARNING).isEmpty()) {
+                    assertWarnings(expectedKeys.get(KeyType.WARNING), vfe);
+                }
+                if (!expectedKeys.get(KeyType.ERROR).isEmpty()) {
+                    assertErrors(expectedKeys.get(KeyType.ERROR), vfe);
+                }
+            } else {
+                for (final ValidationFailure failure : vfe.getFailures()) {
+                    System.out.println("failure = " + failure.getMessageKey());
+                }
+                fail("There should be no validation failures");
+            }
+        } finally {
+            SystemInstance.get().setProperty(OutputGeneratedDescriptors.OUTPUT_DESCRIPTORS, outputDescriptors);
+        }
+
+        tearDown();
+    }
+
+    private void setUp() throws Exception {
+        config = new ConfigurationFactory();
+        assembler = new Assembler();
+        assembler.createTransactionManager(config.configureService(TransactionServiceInfo.class));
+        assembler.createSecurityService(config.configureService(SecurityServiceInfo.class));
+    }
+
+    private void tearDown() {
+    }
+
+    /**
+     * Tests to see if the keys specified in the @Keys annotation are also available in the org.apache.openejb.config.rules.Messages.properties file. If there are any invalid keys,
+     * then it throws an exception and causes the test to error out. If all the keys are valid, then it returns those keys. This list of keys can then be compared with all the Keys
+     * in org.apache.openejb.config.rules.Messages.properties and one can then find out the "test coverage" of the keys i.e. this tool can be used to find keys for which tests have
+     * not yet been written
+     *
+     * @return
+     * @throws Exception
+     */
+    private Map<Integer, List<String>> validateKeys() throws Exception {
+        final Keys annotation = testMethod.getAnnotation(Keys.class);
+        final Key[] keys = annotation.value();
+        final ArrayList<String> wrongKeys = new ArrayList<String>();
+        for (final Key key : keys) {
+            if (allKeys.contains("1." + key.value())) {
+                continue;
+            } else {
+                wrongKeys.add(key.value());
+            }
+        }
+        if (wrongKeys.isEmpty()) {
+            final Map<Integer, List<String>> validKeys = new HashMap<Integer, List<String>>();
+            final ArrayList<String> failureKeys = new ArrayList<String>();
+            final ArrayList<String> warningKeys = new ArrayList<String>();
+            final ArrayList<String> errorKeys = new ArrayList<String>();
+            for (final Key key : keys) {
+                for (int i = 0; i < key.count(); i++) {
+                    switch (key.type()) {
+                        case KeyType.FAILURE:
+                            failureKeys.add(key.value());
+                            break;
+                        case KeyType.WARNING:
+                            warningKeys.add(key.value());
+                            break;
+                        case KeyType.ERROR:
+                            errorKeys.add(key.value());
+                            break;
+                    }
+                }
+            }
+            validKeys.put(KeyType.FAILURE, failureKeys);
+            validKeys.put(KeyType.WARNING, warningKeys);
+            validKeys.put(KeyType.ERROR, errorKeys);
+            return validKeys;
+        } else {
+            final String commaDelimitedKeys = Join.join(",", wrongKeys);
+            throw new Exception("The following keys listed in the @Keys annotation on the method " + testMethod.getName() + "() of " + testMethod.getMethod().getDeclaringClass()
+                + " are invalid : " + commaDelimitedKeys
+                + " . Only keys listed in org.apache.openejb.config.rules.Messages.properties are allowed to be used in this annotation. ");
+        }
+    }
+
+    private boolean isEmpty(final Map<Integer, List<String>> expectedKeys) {
+        boolean empty = true;
+        final Set<Entry<Integer, List<String>>> entrySet = expectedKeys.entrySet();
+        for (final Entry<Integer, List<String>> entry : entrySet) {
+            empty = entry.getValue().size() == 0;
+            if (!empty)
+                return empty;
+        }
+        return empty;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Key.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Key.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Key.java
index edf64d5..06ec3bf 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Key.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Key.java
@@ -1,32 +1,32 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-public @interface Key {
-    String value();
-
-    int count() default 1;
-
-    int type() default KeyType.FAILURE;
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+@Target(ElementType.METHOD)
+@Retention(RetentionPolicy.RUNTIME)
+public @interface Key {
+    String value();
+
+    int count() default 1;
+
+    int type() default KeyType.FAILURE;
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Keys.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Keys.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Keys.java
index afda752..cb0dd09 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Keys.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/Keys.java
@@ -1,31 +1,31 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * Used to specify the keys being tested.
- */
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-public @interface Keys {
-    Key[] value() default {};
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+/**
+ * Used to specify the keys being tested.
+ */
+@Target(ElementType.METHOD)
+@Retention(RetentionPolicy.RUNTIME)
+public @interface Keys {
+    Key[] value() default {};
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/MistakenResourceRefUsageTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/MistakenResourceRefUsageTest.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/MistakenResourceRefUsageTest.java
index 0d4f4a0..6cce24f 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/MistakenResourceRefUsageTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/MistakenResourceRefUsageTest.java
@@ -1,55 +1,55 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.apache.openejb.OpenEJBException;
-import org.apache.openejb.jee.EjbJar;
-import org.apache.openejb.jee.StatefulBean;
-import org.apache.openejb.jee.StatelessBean;
-import org.junit.runner.RunWith;
-
-import javax.annotation.Resource;
-import javax.persistence.EntityManager;
-import javax.persistence.EntityManagerFactory;
-
-@RunWith(ValidationRunner.class)
-public class MistakenResourceRefUsageTest {
-    @Keys({@Key(value = "resourceRef.onEntityManagerFactory", count = 2), @Key(value = "resourceRef.onEntityManager", count = 2),
-        @Key(value = "resourceAnnotation.onClassWithNoName", count = 2)})
-    public EjbJar wrongUsage() throws OpenEJBException {
-        final EjbJar ejbJar = new EjbJar();
-        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
-        ejbJar.addEnterpriseBean(new StatefulBean(FooStateful.class));
-        return ejbJar;
-    }
-
-    @Resource
-    private static class FooStateless {
-        @Resource
-        EntityManagerFactory emf;
-        @Resource
-        EntityManager em;
-    }
-
-    @Resource
-    private static class FooStateful {
-        @Resource
-        EntityManagerFactory emf;
-        @Resource
-        EntityManager em;
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.apache.openejb.OpenEJBException;
+import org.apache.openejb.jee.EjbJar;
+import org.apache.openejb.jee.StatefulBean;
+import org.apache.openejb.jee.StatelessBean;
+import org.junit.runner.RunWith;
+
+import javax.annotation.Resource;
+import javax.persistence.EntityManager;
+import javax.persistence.EntityManagerFactory;
+
+@RunWith(ValidationRunner.class)
+public class MistakenResourceRefUsageTest {
+    @Keys({@Key(value = "resourceRef.onEntityManagerFactory", count = 2), @Key(value = "resourceRef.onEntityManager", count = 2),
+        @Key(value = "resourceAnnotation.onClassWithNoName", count = 2)})
+    public EjbJar wrongUsage() throws OpenEJBException {
+        final EjbJar ejbJar = new EjbJar();
+        ejbJar.addEnterpriseBean(new StatelessBean(FooStateless.class));
+        ejbJar.addEnterpriseBean(new StatefulBean(FooStateful.class));
+        return ejbJar;
+    }
+
+    @Resource
+    private static class FooStateless {
+        @Resource
+        EntityManagerFactory emf;
+        @Resource
+        EntityManager em;
+    }
+
+    @Resource
+    private static class FooStateful {
+        @Resource
+        EntityManagerFactory emf;
+        @Resource
+        EntityManager em;
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/ValidationRunner.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/ValidationRunner.java b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/ValidationRunner.java
index d07cf52a..7b2d4ee 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/config/rules/ValidationRunner.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/config/rules/ValidationRunner.java
@@ -1,88 +1,88 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.config.rules;
-
-import org.junit.Test;
-import org.junit.internal.runners.model.ReflectiveCallable;
-import org.junit.internal.runners.statements.Fail;
-import org.junit.runners.BlockJUnit4ClassRunner;
-import org.junit.runners.model.FrameworkMethod;
-import org.junit.runners.model.InitializationError;
-import org.junit.runners.model.Statement;
-
-import java.util.List;
-
-/**
- * This class is created specifically to write tests which test OpenEjb validation code. Specifically, it is used to check the usage of keys defined in
- * org.apache.openejb.config.rules.Messages.properties. To use this runner, simply annotate your test case with @RunWith(ValidationRunner.class). Here are some things to keep in
- * mind when writing tests: 1. A test method needs to be annotated with org.apache.openejb.config.rules.Keys instead of the org.junit.Test 2. Any usage of the @Test annotation will
- * be ignored 3. If the @Keys and @Test annotation are used together on a test method, then the TestCase will error out 4. Every test method should create a EjbJar and return it
- * from the method. It should list the keys being tested in the @Keys annotation 5. The runner will invoke the test method and use the Assembler and ConfigurationFactory to create
- * the application 6. This will kick off validation and this Runner will catch ValidationFailureException and make sure that all the keys specified in the @Keys annotation show up
- * in the ValidationFailureException 7. If the keys listed in the @Keys annotation match the keys found in the ValidationFailureException, the test passes, else the test fails. 8.
- * This Runner also validates that the keys specified in the @Keys annotation are also available in the org.apache.openejb.config.rules.Messages.properties file. If the key is not
- * found, then the Runner throws and exception resulting in your test case not being allowed to run. Sometimes you want to write a test where you do not want any
- * ValidationFailureException to be thrown, in those scenarios, simply annotate your test with @Keys and do not specify any @Key in it
- */
-public class ValidationRunner extends BlockJUnit4ClassRunner {
-    public ValidationRunner(final Class<?> klass) throws InitializationError {
-        super(klass);
-    }
-
-    /**
-     * Flags an error if you have annotated a test with both @Test and @Keys. Any method annotated with @Test will be ignored anyways.
-     */
-    @Override
-    protected void collectInitializationErrors(final List<Throwable> errors) {
-        super.collectInitializationErrors(errors);
-        final List<FrameworkMethod> methodsAnnotatedWithKeys = getTestClass().getAnnotatedMethods(Keys.class);
-        for (final FrameworkMethod frameworkMethod : methodsAnnotatedWithKeys) {
-            if (frameworkMethod.getAnnotation(Test.class) != null) {
-                final String gripe = "The method " + frameworkMethod.getName() + "() can only be annotated with @Keys";
-                errors.add(new Exception(gripe));
-            }
-        }
-    }
-
-    @Override
-    protected Statement methodBlock(final FrameworkMethod method) {
-        final Object test;
-        try {
-            test = new ReflectiveCallable() {
-                @Override
-                protected Object runReflectiveCall() throws Throwable {
-                    return createTest();
-                }
-            }.run();
-        } catch (final Throwable e) {
-            return new Fail(e);
-        }
-        Statement statement = new InvokeMethod(method, test);
-        statement = withBefores(method, test, statement);
-        statement = withAfters(method, test, statement);
-        return statement;
-    }
-
-    /**
-     * By default JUnit includes all methods annotated with @Test. This method only allows methods annotated with @Keys to be included in the list of methods to be run in a
-     * TestCase. Any @Test methods will be ignored
-     */
-    @Override
-    protected List<FrameworkMethod> computeTestMethods() {
-        return getTestClass().getAnnotatedMethods(Keys.class);
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.config.rules;
+
+import org.junit.Test;
+import org.junit.internal.runners.model.ReflectiveCallable;
+import org.junit.internal.runners.statements.Fail;
+import org.junit.runners.BlockJUnit4ClassRunner;
+import org.junit.runners.model.FrameworkMethod;
+import org.junit.runners.model.InitializationError;
+import org.junit.runners.model.Statement;
+
+import java.util.List;
+
+/**
+ * This class is created specifically to write tests which test OpenEjb validation code. Specifically, it is used to check the usage of keys defined in
+ * org.apache.openejb.config.rules.Messages.properties. To use this runner, simply annotate your test case with @RunWith(ValidationRunner.class). Here are some things to keep in
+ * mind when writing tests: 1. A test method needs to be annotated with org.apache.openejb.config.rules.Keys instead of the org.junit.Test 2. Any usage of the @Test annotation will
+ * be ignored 3. If the @Keys and @Test annotation are used together on a test method, then the TestCase will error out 4. Every test method should create a EjbJar and return it
+ * from the method. It should list the keys being tested in the @Keys annotation 5. The runner will invoke the test method and use the Assembler and ConfigurationFactory to create
+ * the application 6. This will kick off validation and this Runner will catch ValidationFailureException and make sure that all the keys specified in the @Keys annotation show up
+ * in the ValidationFailureException 7. If the keys listed in the @Keys annotation match the keys found in the ValidationFailureException, the test passes, else the test fails. 8.
+ * This Runner also validates that the keys specified in the @Keys annotation are also available in the org.apache.openejb.config.rules.Messages.properties file. If the key is not
+ * found, then the Runner throws and exception resulting in your test case not being allowed to run. Sometimes you want to write a test where you do not want any
+ * ValidationFailureException to be thrown, in those scenarios, simply annotate your test with @Keys and do not specify any @Key in it
+ */
+public class ValidationRunner extends BlockJUnit4ClassRunner {
+    public ValidationRunner(final Class<?> klass) throws InitializationError {
+        super(klass);
+    }
+
+    /**
+     * Flags an error if you have annotated a test with both @Test and @Keys. Any method annotated with @Test will be ignored anyways.
+     */
+    @Override
+    protected void collectInitializationErrors(final List<Throwable> errors) {
+        super.collectInitializationErrors(errors);
+        final List<FrameworkMethod> methodsAnnotatedWithKeys = getTestClass().getAnnotatedMethods(Keys.class);
+        for (final FrameworkMethod frameworkMethod : methodsAnnotatedWithKeys) {
+            if (frameworkMethod.getAnnotation(Test.class) != null) {
+                final String gripe = "The method " + frameworkMethod.getName() + "() can only be annotated with @Keys";
+                errors.add(new Exception(gripe));
+            }
+        }
+    }
+
+    @Override
+    protected Statement methodBlock(final FrameworkMethod method) {
+        final Object test;
+        try {
+            test = new ReflectiveCallable() {
+                @Override
+                protected Object runReflectiveCall() throws Throwable {
+                    return createTest();
+                }
+            }.run();
+        } catch (final Throwable e) {
+            return new Fail(e);
+        }
+        Statement statement = new InvokeMethod(method, test);
+        statement = withBefores(method, test, statement);
+        statement = withAfters(method, test, statement);
+        return statement;
+    }
+
+    /**
+     * By default JUnit includes all methods annotated with @Test. This method only allows methods annotated with @Keys to be included in the list of methods to be run in a
+     * TestCase. Any @Test methods will be ignored
+     */
+    @Override
+    protected List<FrameworkMethod> computeTestMethods() {
+        return getTestClass().getAnnotatedMethods(Keys.class);
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/core/security/PermitAllWithDenyAllOnClassTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/core/security/PermitAllWithDenyAllOnClassTest.java b/container/openejb-core/src/test/java/org/apache/openejb/core/security/PermitAllWithDenyAllOnClassTest.java
index 9bd27e2..c37baf7 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/core/security/PermitAllWithDenyAllOnClassTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/core/security/PermitAllWithDenyAllOnClassTest.java
@@ -1,88 +1,88 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.core.security;
-
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.testing.Module;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.annotation.security.DenyAll;
-import javax.annotation.security.PermitAll;
-import javax.ejb.EJB;
-import javax.ejb.EJBAccessException;
-import javax.ejb.Singleton;
-
-@RunWith(ApplicationComposer.class)
-public class PermitAllWithDenyAllOnClassTest {
-    @Module
-    public Class<?>[] beans() {
-        return new Class<?>[]{DenyAllow.class, AllowDeny.class};
-    }
-
-    @EJB
-    private DenyAllow denyAllow;
-
-    @EJB
-    private AllowDeny allowDeny;
-
-    @Test
-    public void allowed() {
-        denyAllow.allowed();
-    }
-
-    @Test(expected = EJBAccessException.class)
-    public void forbidden() {
-        denyAllow.forbidden();
-    }
-
-    @Test
-    public void allowed2() {
-        allowDeny.allowed();
-    }
-
-    @Test(expected = EJBAccessException.class)
-    public void forbidden2() {
-        allowDeny.forbidden();
-    }
-
-    @Singleton
-    @DenyAll
-    public static class DenyAllow {
-        @PermitAll
-        public void allowed() {
-            // no-op
-        }
-
-        public void forbidden() {
-            // no-op
-        }
-    }
-
-    @Singleton
-    @PermitAll
-    public static class AllowDeny {
-        public void allowed() {
-            // no-op
-        }
-
-        @DenyAll
-        public void forbidden() {
-            // no-op
-        }
-    }
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.core.security;
+
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.testing.Module;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.annotation.security.DenyAll;
+import javax.annotation.security.PermitAll;
+import javax.ejb.EJB;
+import javax.ejb.EJBAccessException;
+import javax.ejb.Singleton;
+
+@RunWith(ApplicationComposer.class)
+public class PermitAllWithDenyAllOnClassTest {
+    @Module
+    public Class<?>[] beans() {
+        return new Class<?>[]{DenyAllow.class, AllowDeny.class};
+    }
+
+    @EJB
+    private DenyAllow denyAllow;
+
+    @EJB
+    private AllowDeny allowDeny;
+
+    @Test
+    public void allowed() {
+        denyAllow.allowed();
+    }
+
+    @Test(expected = EJBAccessException.class)
+    public void forbidden() {
+        denyAllow.forbidden();
+    }
+
+    @Test
+    public void allowed2() {
+        allowDeny.allowed();
+    }
+
+    @Test(expected = EJBAccessException.class)
+    public void forbidden2() {
+        allowDeny.forbidden();
+    }
+
+    @Singleton
+    @DenyAll
+    public static class DenyAllow {
+        @PermitAll
+        public void allowed() {
+            // no-op
+        }
+
+        public void forbidden() {
+            // no-op
+        }
+    }
+
+    @Singleton
+    @PermitAll
+    public static class AllowDeny {
+        public void allowed() {
+            // no-op
+        }
+
+        @DenyAll
+        public void forbidden() {
+            // no-op
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/jpa/JTAPuAndBmtTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/jpa/JTAPuAndBmtTest.java b/container/openejb-core/src/test/java/org/apache/openejb/jpa/JTAPuAndBmtTest.java
index cb03686..121c966 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/jpa/JTAPuAndBmtTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/jpa/JTAPuAndBmtTest.java
@@ -1,154 +1,154 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.jpa;
-
-import org.apache.openejb.jee.Empty;
-import org.apache.openejb.jee.StatelessBean;
-import org.apache.openejb.jee.jpa.unit.Persistence;
-import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.testing.Configuration;
-import org.apache.openejb.testing.Module;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.annotation.Resource;
-import javax.ejb.EJB;
-import javax.ejb.EJBContext;
-import javax.ejb.LocalBean;
-import javax.ejb.Stateless;
-import javax.ejb.TransactionManagement;
-import javax.ejb.TransactionManagementType;
-import javax.persistence.Entity;
-import javax.persistence.EntityManager;
-import javax.persistence.GeneratedValue;
-import javax.persistence.Id;
-import javax.persistence.PersistenceContext;
-import javax.persistence.TypedQuery;
-import java.util.Properties;
-
-import static org.junit.Assert.assertNotNull;
-
-@RunWith(ApplicationComposer.class)
-public class JTAPuAndBmtTest {
-    @EJB
-    private BmtManager bmtManager;
-
-    @Configuration
-    public Properties config() {
-        final Properties p = new Properties();
-        p.put("JTAPuAndBmtTest", "new://Resource?type=DataSource");
-        p.put("JTAPuAndBmtTest.JdbcDriver", "org.hsqldb.jdbcDriver");
-        p.put("JTAPuAndBmtTest.JdbcUrl", "jdbc:hsqldb:mem:bval");
-        return p;
-    }
-
-    @Module
-    public StatelessBean app() throws Exception {
-        final StatelessBean bean = new StatelessBean(BmtManager.class);
-        bean.setLocalBean(new Empty());
-        return bean;
-    }
-
-    @Module
-    public Persistence persistence() {
-        final PersistenceUnit unit = new PersistenceUnit("foo-unit");
-        unit.addClass(TheEntity.class);
-        unit.setProperty("openjpa.jdbc.SynchronizeMappings", "buildSchema(ForeignKeys=true)");
-        unit.getProperties().setProperty("openjpa.RuntimeUnenhancedClasses", "supported");
-        unit.setExcludeUnlistedClasses(true);
-
-        final Persistence persistence = new Persistence(unit);
-        persistence.setVersion("2.0");
-        return persistence;
-    }
-
-    @LocalBean
-    @Stateless
-    @TransactionManagement(TransactionManagementType.BEAN)
-    public static class BmtManager {
-        @PersistenceContext
-        private EntityManager em;
-
-        @Resource
-        private EJBContext ctx;
-
-        public TheEntity persist() {
-            try {
-                ctx.getUserTransaction().begin();
-                final TheEntity entity = new TheEntity();
-                entity.setName("name");
-                em.persist(entity);
-                ctx.getUserTransaction().commit();
-                return entity;
-            } catch (final Exception e) {
-                throw new RuntimeException(e);
-            }
-        }
-
-        public TheEntity findWithJpQl() {
-            final TypedQuery<TheEntity> query = em.createQuery("select e from JTAPuAndBmtTest$TheEntity e", TheEntity.class);
-            query.getResultList(); // to ensure we don't break OPENEJB-1443
-            return query.getResultList().iterator().next();
-        }
-
-        public void update(final TheEntity entity) {
-            entity.setName("new");
-            try {
-                ctx.getUserTransaction().begin();
-                em.merge(entity);
-                ctx.getUserTransaction().commit();
-            } catch (final Exception e) {
-                throw new RuntimeException(e);
-            }
-        }
-    }
-
-    @Entity
-    public static class TheEntity {
-        @Id
-        @GeneratedValue
-        private long id;
-        private String name;
-
-        public long getId() {
-            return id;
-        }
-
-        public void setId(final long i) {
-            id = i;
-        }
-
-        public String getName() {
-            return name;
-        }
-
-        public void setName(final String n) {
-            name = n;
-        }
-    }
-
-    @Test
-    public void valid() {
-        assertNotNull(bmtManager.persist());
-
-        final TheEntity entity = bmtManager.findWithJpQl();
-        assertNotNull(entity);
-
-        bmtManager.update(entity); // will throw an exception if any error
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.jpa;
+
+import org.apache.openejb.jee.Empty;
+import org.apache.openejb.jee.StatelessBean;
+import org.apache.openejb.jee.jpa.unit.Persistence;
+import org.apache.openejb.jee.jpa.unit.PersistenceUnit;
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.testing.Configuration;
+import org.apache.openejb.testing.Module;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.annotation.Resource;
+import javax.ejb.EJB;
+import javax.ejb.EJBContext;
+import javax.ejb.LocalBean;
+import javax.ejb.Stateless;
+import javax.ejb.TransactionManagement;
+import javax.ejb.TransactionManagementType;
+import javax.persistence.Entity;
+import javax.persistence.EntityManager;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+import javax.persistence.PersistenceContext;
+import javax.persistence.TypedQuery;
+import java.util.Properties;
+
+import static org.junit.Assert.assertNotNull;
+
+@RunWith(ApplicationComposer.class)
+public class JTAPuAndBmtTest {
+    @EJB
+    private BmtManager bmtManager;
+
+    @Configuration
+    public Properties config() {
+        final Properties p = new Properties();
+        p.put("JTAPuAndBmtTest", "new://Resource?type=DataSource");
+        p.put("JTAPuAndBmtTest.JdbcDriver", "org.hsqldb.jdbcDriver");
+        p.put("JTAPuAndBmtTest.JdbcUrl", "jdbc:hsqldb:mem:bval");
+        return p;
+    }
+
+    @Module
+    public StatelessBean app() throws Exception {
+        final StatelessBean bean = new StatelessBean(BmtManager.class);
+        bean.setLocalBean(new Empty());
+        return bean;
+    }
+
+    @Module
+    public Persistence persistence() {
+        final PersistenceUnit unit = new PersistenceUnit("foo-unit");
+        unit.addClass(TheEntity.class);
+        unit.setProperty("openjpa.jdbc.SynchronizeMappings", "buildSchema(ForeignKeys=true)");
+        unit.getProperties().setProperty("openjpa.RuntimeUnenhancedClasses", "supported");
+        unit.setExcludeUnlistedClasses(true);
+
+        final Persistence persistence = new Persistence(unit);
+        persistence.setVersion("2.0");
+        return persistence;
+    }
+
+    @LocalBean
+    @Stateless
+    @TransactionManagement(TransactionManagementType.BEAN)
+    public static class BmtManager {
+        @PersistenceContext
+        private EntityManager em;
+
+        @Resource
+        private EJBContext ctx;
+
+        public TheEntity persist() {
+            try {
+                ctx.getUserTransaction().begin();
+                final TheEntity entity = new TheEntity();
+                entity.setName("name");
+                em.persist(entity);
+                ctx.getUserTransaction().commit();
+                return entity;
+            } catch (final Exception e) {
+                throw new RuntimeException(e);
+            }
+        }
+
+        public TheEntity findWithJpQl() {
+            final TypedQuery<TheEntity> query = em.createQuery("select e from JTAPuAndBmtTest$TheEntity e", TheEntity.class);
+            query.getResultList(); // to ensure we don't break OPENEJB-1443
+            return query.getResultList().iterator().next();
+        }
+
+        public void update(final TheEntity entity) {
+            entity.setName("new");
+            try {
+                ctx.getUserTransaction().begin();
+                em.merge(entity);
+                ctx.getUserTransaction().commit();
+            } catch (final Exception e) {
+                throw new RuntimeException(e);
+            }
+        }
+    }
+
+    @Entity
+    public static class TheEntity {
+        @Id
+        @GeneratedValue
+        private long id;
+        private String name;
+
+        public long getId() {
+            return id;
+        }
+
+        public void setId(final long i) {
+            id = i;
+        }
+
+        public String getName() {
+            return name;
+        }
+
+        public void setName(final String n) {
+            name = n;
+        }
+    }
+
+    @Test
+    public void valid() {
+        assertNotNull(bmtManager.persist());
+
+        final TheEntity entity = bmtManager.findWithJpQl();
+        assertNotNull(entity);
+
+        bmtManager.update(entity); // will throw an exception if any error
+    }
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/junit/PreDestroyTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/junit/PreDestroyTest.java b/container/openejb-core/src/test/java/org/apache/openejb/junit/PreDestroyTest.java
index 3b66dfb..9f6aea7 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/junit/PreDestroyTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/junit/PreDestroyTest.java
@@ -1,82 +1,82 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.openejb.junit;
-
-import org.apache.openejb.jee.SessionBean;
-import org.apache.openejb.jee.SingletonBean;
-import org.junit.AfterClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.annotation.PostConstruct;
-import javax.annotation.PreDestroy;
-import javax.ejb.Singleton;
-import javax.inject.Inject;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-import static org.junit.Assert.assertTrue;
-
-/**
- * Test for https://issues.apache.org/jira/browse/OPENEJB-2014
- *
- * @version $Rev$ $Date$
- */
-@RunWith(ApplicationComposer.class)
-public class PreDestroyTest {
-
-    private static final AtomicBoolean isConstructed = new AtomicBoolean(false);
-    private static final AtomicBoolean isDestroyed = new AtomicBoolean(false);
-
-    @Inject
-    private TestMe testMe;
-
-    @AfterClass
-    public static void onAfterClass() {
-        assertTrue("onPostConstruct was not called", isConstructed.get());
-        assertTrue("onPreDestroy was not called", isDestroyed.get());
-    }
-
-    @org.apache.openejb.testing.Module
-    public SessionBean getEjbs() {
-        return new SingletonBean(TestMe.class);
-    }
-
-    @Test
-    public void testLifecycle() {
-        this.testMe.noOp();
-    }
-
-    @Singleton
-    public static class TestMe {
-
-        @PostConstruct
-        public void onPostConstruct() {
-            isConstructed.set(true);
-        }
-
-        @PreDestroy
-        public void onPreDestroy() {
-            isDestroyed.set(true);
-        }
-
-        public void noOp() {
-            //no-op
-        }
-
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.openejb.junit;
+
+import org.apache.openejb.jee.SessionBean;
+import org.apache.openejb.jee.SingletonBean;
+import org.junit.AfterClass;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.PreDestroy;
+import javax.ejb.Singleton;
+import javax.inject.Inject;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+import static org.junit.Assert.assertTrue;
+
+/**
+ * Test for https://issues.apache.org/jira/browse/OPENEJB-2014
+ *
+ * @version $Rev$ $Date$
+ */
+@RunWith(ApplicationComposer.class)
+public class PreDestroyTest {
+
+    private static final AtomicBoolean isConstructed = new AtomicBoolean(false);
+    private static final AtomicBoolean isDestroyed = new AtomicBoolean(false);
+
+    @Inject
+    private TestMe testMe;
+
+    @AfterClass
+    public static void onAfterClass() {
+        assertTrue("onPostConstruct was not called", isConstructed.get());
+        assertTrue("onPreDestroy was not called", isDestroyed.get());
+    }
+
+    @org.apache.openejb.testing.Module
+    public SessionBean getEjbs() {
+        return new SingletonBean(TestMe.class);
+    }
+
+    @Test
+    public void testLifecycle() {
+        this.testMe.noOp();
+    }
+
+    @Singleton
+    public static class TestMe {
+
+        @PostConstruct
+        public void onPostConstruct() {
+            isConstructed.set(true);
+        }
+
+        @PreDestroy
+        public void onPreDestroy() {
+            isDestroyed.set(true);
+        }
+
+        public void noOp() {
+            //no-op
+        }
+
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-core/src/test/java/org/apache/openejb/resource/URLAsResourceTest.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/test/java/org/apache/openejb/resource/URLAsResourceTest.java b/container/openejb-core/src/test/java/org/apache/openejb/resource/URLAsResourceTest.java
index dda0eed..d63518d 100644
--- a/container/openejb-core/src/test/java/org/apache/openejb/resource/URLAsResourceTest.java
+++ b/container/openejb-core/src/test/java/org/apache/openejb/resource/URLAsResourceTest.java
@@ -1,71 +1,71 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.openejb.resource;
-
-import org.apache.openejb.jee.EnterpriseBean;
-import org.apache.openejb.jee.SingletonBean;
-import org.apache.openejb.junit.ApplicationComposer;
-import org.apache.openejb.testing.Configuration;
-import org.apache.openejb.testing.Module;
-import org.apache.openejb.testng.PropertiesBuilder;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import javax.annotation.Resource;
-import javax.ejb.EJB;
-import javax.ejb.Singleton;
-import java.net.URL;
-import java.util.Properties;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-
-@RunWith(ApplicationComposer.class)
-public class URLAsResourceTest {
-    @Configuration
-    public Properties config() {
-        return new PropertiesBuilder()
-            .p("url", "new://Resource?class-name=java.net.URL&constructor=value")
-            .p("url.value", "http://tomee.apache.org")
-            .build();
-    }
-
-    @Module
-    public EnterpriseBean bean() {
-        return new SingletonBean(WithUrl.class).localBean();
-    }
-
-    @EJB
-    private WithUrl withUrl;
-
-    @Test
-    public void url() {
-        final URL url = withUrl.getUrl();
-        assertNotNull(url);
-        assertEquals("http://tomee.apache.org", url.toExternalForm());
-    }
-
-    @Singleton
-    public static class WithUrl {
-        @Resource(name = "url")
-        private URL url;
-
-        public URL getUrl() {
-            return url;
-        }
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.openejb.resource;
+
+import org.apache.openejb.jee.EnterpriseBean;
+import org.apache.openejb.jee.SingletonBean;
+import org.apache.openejb.junit.ApplicationComposer;
+import org.apache.openejb.testing.Configuration;
+import org.apache.openejb.testing.Module;
+import org.apache.openejb.testng.PropertiesBuilder;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import javax.annotation.Resource;
+import javax.ejb.EJB;
+import javax.ejb.Singleton;
+import java.net.URL;
+import java.util.Properties;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+
+@RunWith(ApplicationComposer.class)
+public class URLAsResourceTest {
+    @Configuration
+    public Properties config() {
+        return new PropertiesBuilder()
+            .p("url", "new://Resource?class-name=java.net.URL&constructor=value")
+            .p("url.value", "http://tomee.apache.org")
+            .build();
+    }
+
+    @Module
+    public EnterpriseBean bean() {
+        return new SingletonBean(WithUrl.class).localBean();
+    }
+
+    @EJB
+    private WithUrl withUrl;
+
+    @Test
+    public void url() {
+        final URL url = withUrl.getUrl();
+        assertNotNull(url);
+        assertEquals("http://tomee.apache.org", url.toExternalForm());
+    }
+
+    @Singleton
+    public static class WithUrl {
+        @Resource(name = "url")
+        private URL url;
+
+        public URL getUrl() {
+            return url;
+        }
+    }
+}


[06/18] tomee git commit: EOL

Posted by an...@apache.org.
http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyClass.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyClass.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyClass.java
index 10a25e3..d02c411 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyClass.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyClass.java
@@ -1,75 +1,75 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface MapKeyClass {
- * Class value();
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for map-key-class complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="map-key-class">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="class" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "map-key-class")
-public class MapKeyClass {
-
-    @XmlAttribute(name = "class", required = true)
-    protected String clazz;
-
-    /**
-     * Gets the value of the clazz property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getClazz() {
-        return clazz;
-    }
-
-    /**
-     * Sets the value of the clazz property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setClazz(final String value) {
-        this.clazz = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface MapKeyClass {
+ * Class value();
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for map-key-class complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="map-key-class">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;attribute name="class" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "map-key-class")
+public class MapKeyClass {
+
+    @XmlAttribute(name = "class", required = true)
+    protected String clazz;
+
+    /**
+     * Gets the value of the clazz property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getClazz() {
+        return clazz;
+    }
+
+    /**
+     * Sets the value of the clazz property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setClazz(final String value) {
+        this.clazz = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyColumn.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyColumn.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyColumn.java
index 2d02b3f..8655213 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyColumn.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyColumn.java
@@ -1,291 +1,291 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface MapKeyColumn {
- * String name() default "";
- * boolean unique() default false;
- * boolean nullable() default false;
- * boolean insertable() default true;
- * boolean updatable() default true;
- * String columnDefinition() default "";
- * String table() default "";
- * int length() default 255;
- * int precision() default 0; // decimal precision
- * int scale() default 0; // decimal scale
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for map-key-column complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="map-key-column">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="unique" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="table" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="length" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="precision" type="{http://www.w3.org/2001/XMLSchema}int" />
- *       &lt;attribute name="scale" type="{http://www.w3.org/2001/XMLSchema}int" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "map-key-column")
-public class MapKeyColumn {
-
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected Boolean unique;
-    @XmlAttribute
-    protected Boolean nullable;
-    @XmlAttribute
-    protected Boolean insertable;
-    @XmlAttribute
-    protected Boolean updatable;
-    @XmlAttribute(name = "column-definition")
-    protected String columnDefinition;
-    @XmlAttribute
-    protected String table;
-    @XmlAttribute
-    protected Integer length;
-    @XmlAttribute
-    protected Integer precision;
-    @XmlAttribute
-    protected Integer scale;
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the unique property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isUnique() {
-        return unique;
-    }
-
-    /**
-     * Sets the value of the unique property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setUnique(final Boolean value) {
-        this.unique = value;
-    }
-
-    /**
-     * Gets the value of the nullable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isNullable() {
-        return nullable;
-    }
-
-    /**
-     * Sets the value of the nullable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setNullable(final Boolean value) {
-        this.nullable = value;
-    }
-
-    /**
-     * Gets the value of the insertable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isInsertable() {
-        return insertable;
-    }
-
-    /**
-     * Sets the value of the insertable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setInsertable(final Boolean value) {
-        this.insertable = value;
-    }
-
-    /**
-     * Gets the value of the updatable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isUpdatable() {
-        return updatable;
-    }
-
-    /**
-     * Sets the value of the updatable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setUpdatable(final Boolean value) {
-        this.updatable = value;
-    }
-
-    /**
-     * Gets the value of the columnDefinition property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getColumnDefinition() {
-        return columnDefinition;
-    }
-
-    /**
-     * Sets the value of the columnDefinition property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setColumnDefinition(final String value) {
-        this.columnDefinition = value;
-    }
-
-    /**
-     * Gets the value of the table property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getTable() {
-        return table;
-    }
-
-    /**
-     * Sets the value of the table property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setTable(final String value) {
-        this.table = value;
-    }
-
-    /**
-     * Gets the value of the length property.
-     *
-     * @return possible object is
-     * {@link Integer }
-     */
-    public Integer getLength() {
-        return length;
-    }
-
-    /**
-     * Sets the value of the length property.
-     *
-     * @param value allowed object is
-     *              {@link Integer }
-     */
-    public void setLength(final Integer value) {
-        this.length = value;
-    }
-
-    /**
-     * Gets the value of the precision property.
-     *
-     * @return possible object is
-     * {@link Integer }
-     */
-    public Integer getPrecision() {
-        return precision;
-    }
-
-    /**
-     * Sets the value of the precision property.
-     *
-     * @param value allowed object is
-     *              {@link Integer }
-     */
-    public void setPrecision(final Integer value) {
-        this.precision = value;
-    }
-
-    /**
-     * Gets the value of the scale property.
-     *
-     * @return possible object is
-     * {@link Integer }
-     */
-    public Integer getScale() {
-        return scale;
-    }
-
-    /**
-     * Sets the value of the scale property.
-     *
-     * @param value allowed object is
-     *              {@link Integer }
-     */
-    public void setScale(final Integer value) {
-        this.scale = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface MapKeyColumn {
+ * String name() default "";
+ * boolean unique() default false;
+ * boolean nullable() default false;
+ * boolean insertable() default true;
+ * boolean updatable() default true;
+ * String columnDefinition() default "";
+ * String table() default "";
+ * int length() default 255;
+ * int precision() default 0; // decimal precision
+ * int scale() default 0; // decimal scale
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for map-key-column complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="map-key-column">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="unique" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="table" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="length" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *       &lt;attribute name="precision" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *       &lt;attribute name="scale" type="{http://www.w3.org/2001/XMLSchema}int" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "map-key-column")
+public class MapKeyColumn {
+
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected Boolean unique;
+    @XmlAttribute
+    protected Boolean nullable;
+    @XmlAttribute
+    protected Boolean insertable;
+    @XmlAttribute
+    protected Boolean updatable;
+    @XmlAttribute(name = "column-definition")
+    protected String columnDefinition;
+    @XmlAttribute
+    protected String table;
+    @XmlAttribute
+    protected Integer length;
+    @XmlAttribute
+    protected Integer precision;
+    @XmlAttribute
+    protected Integer scale;
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the unique property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isUnique() {
+        return unique;
+    }
+
+    /**
+     * Sets the value of the unique property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setUnique(final Boolean value) {
+        this.unique = value;
+    }
+
+    /**
+     * Gets the value of the nullable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isNullable() {
+        return nullable;
+    }
+
+    /**
+     * Sets the value of the nullable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setNullable(final Boolean value) {
+        this.nullable = value;
+    }
+
+    /**
+     * Gets the value of the insertable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isInsertable() {
+        return insertable;
+    }
+
+    /**
+     * Sets the value of the insertable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setInsertable(final Boolean value) {
+        this.insertable = value;
+    }
+
+    /**
+     * Gets the value of the updatable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isUpdatable() {
+        return updatable;
+    }
+
+    /**
+     * Sets the value of the updatable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setUpdatable(final Boolean value) {
+        this.updatable = value;
+    }
+
+    /**
+     * Gets the value of the columnDefinition property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getColumnDefinition() {
+        return columnDefinition;
+    }
+
+    /**
+     * Sets the value of the columnDefinition property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setColumnDefinition(final String value) {
+        this.columnDefinition = value;
+    }
+
+    /**
+     * Gets the value of the table property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getTable() {
+        return table;
+    }
+
+    /**
+     * Sets the value of the table property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setTable(final String value) {
+        this.table = value;
+    }
+
+    /**
+     * Gets the value of the length property.
+     *
+     * @return possible object is
+     * {@link Integer }
+     */
+    public Integer getLength() {
+        return length;
+    }
+
+    /**
+     * Sets the value of the length property.
+     *
+     * @param value allowed object is
+     *              {@link Integer }
+     */
+    public void setLength(final Integer value) {
+        this.length = value;
+    }
+
+    /**
+     * Gets the value of the precision property.
+     *
+     * @return possible object is
+     * {@link Integer }
+     */
+    public Integer getPrecision() {
+        return precision;
+    }
+
+    /**
+     * Sets the value of the precision property.
+     *
+     * @param value allowed object is
+     *              {@link Integer }
+     */
+    public void setPrecision(final Integer value) {
+        this.precision = value;
+    }
+
+    /**
+     * Gets the value of the scale property.
+     *
+     * @return possible object is
+     * {@link Integer }
+     */
+    public Integer getScale() {
+        return scale;
+    }
+
+    /**
+     * Sets the value of the scale property.
+     *
+     * @param value allowed object is
+     *              {@link Integer }
+     */
+    public void setScale(final Integer value) {
+        this.scale = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyJoinColumn.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyJoinColumn.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyJoinColumn.java
index 5bdbb49..ef0e3b6 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyJoinColumn.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/MapKeyJoinColumn.java
@@ -1,243 +1,243 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface MapKeyJoinColumn {
- * String name() default "";
- * String referencedColumnName() default "";
- * boolean unique() default false;
- * boolean nullable() default false;
- * boolean insertable() default true;
- * boolean updatable() default true;
- * String columnDefinition() default "";
- * String table() default "";
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for map-key-join-column complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="map-key-join-column">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="referenced-column-name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="unique" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="table" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "map-key-join-column")
-public class MapKeyJoinColumn {
-
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute(name = "referenced-column-name")
-    protected String referencedColumnName;
-    @XmlAttribute
-    protected Boolean unique;
-    @XmlAttribute
-    protected Boolean nullable;
-    @XmlAttribute
-    protected Boolean insertable;
-    @XmlAttribute
-    protected Boolean updatable;
-    @XmlAttribute(name = "column-definition")
-    protected String columnDefinition;
-    @XmlAttribute
-    protected String table;
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the referencedColumnName property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getReferencedColumnName() {
-        return referencedColumnName;
-    }
-
-    /**
-     * Sets the value of the referencedColumnName property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setReferencedColumnName(final String value) {
-        this.referencedColumnName = value;
-    }
-
-    /**
-     * Gets the value of the unique property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isUnique() {
-        return unique;
-    }
-
-    /**
-     * Sets the value of the unique property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setUnique(final Boolean value) {
-        this.unique = value;
-    }
-
-    /**
-     * Gets the value of the nullable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isNullable() {
-        return nullable;
-    }
-
-    /**
-     * Sets the value of the nullable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setNullable(final Boolean value) {
-        this.nullable = value;
-    }
-
-    /**
-     * Gets the value of the insertable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isInsertable() {
-        return insertable;
-    }
-
-    /**
-     * Sets the value of the insertable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setInsertable(final Boolean value) {
-        this.insertable = value;
-    }
-
-    /**
-     * Gets the value of the updatable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isUpdatable() {
-        return updatable;
-    }
-
-    /**
-     * Sets the value of the updatable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setUpdatable(final Boolean value) {
-        this.updatable = value;
-    }
-
-    /**
-     * Gets the value of the columnDefinition property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getColumnDefinition() {
-        return columnDefinition;
-    }
-
-    /**
-     * Sets the value of the columnDefinition property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setColumnDefinition(final String value) {
-        this.columnDefinition = value;
-    }
-
-    /**
-     * Gets the value of the table property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getTable() {
-        return table;
-    }
-
-    /**
-     * Sets the value of the table property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setTable(final String value) {
-        this.table = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface MapKeyJoinColumn {
+ * String name() default "";
+ * String referencedColumnName() default "";
+ * boolean unique() default false;
+ * boolean nullable() default false;
+ * boolean insertable() default true;
+ * boolean updatable() default true;
+ * String columnDefinition() default "";
+ * String table() default "";
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for map-key-join-column complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="map-key-join-column">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="referenced-column-name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="unique" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="table" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "map-key-join-column")
+public class MapKeyJoinColumn {
+
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute(name = "referenced-column-name")
+    protected String referencedColumnName;
+    @XmlAttribute
+    protected Boolean unique;
+    @XmlAttribute
+    protected Boolean nullable;
+    @XmlAttribute
+    protected Boolean insertable;
+    @XmlAttribute
+    protected Boolean updatable;
+    @XmlAttribute(name = "column-definition")
+    protected String columnDefinition;
+    @XmlAttribute
+    protected String table;
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the referencedColumnName property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getReferencedColumnName() {
+        return referencedColumnName;
+    }
+
+    /**
+     * Sets the value of the referencedColumnName property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setReferencedColumnName(final String value) {
+        this.referencedColumnName = value;
+    }
+
+    /**
+     * Gets the value of the unique property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isUnique() {
+        return unique;
+    }
+
+    /**
+     * Sets the value of the unique property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setUnique(final Boolean value) {
+        this.unique = value;
+    }
+
+    /**
+     * Gets the value of the nullable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isNullable() {
+        return nullable;
+    }
+
+    /**
+     * Sets the value of the nullable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setNullable(final Boolean value) {
+        this.nullable = value;
+    }
+
+    /**
+     * Gets the value of the insertable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isInsertable() {
+        return insertable;
+    }
+
+    /**
+     * Sets the value of the insertable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setInsertable(final Boolean value) {
+        this.insertable = value;
+    }
+
+    /**
+     * Gets the value of the updatable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isUpdatable() {
+        return updatable;
+    }
+
+    /**
+     * Sets the value of the updatable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setUpdatable(final Boolean value) {
+        this.updatable = value;
+    }
+
+    /**
+     * Gets the value of the columnDefinition property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getColumnDefinition() {
+        return columnDefinition;
+    }
+
+    /**
+     * Sets the value of the columnDefinition property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setColumnDefinition(final String value) {
+        this.columnDefinition = value;
+    }
+
+    /**
+     * Gets the value of the table property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getTable() {
+        return table;
+    }
+
+    /**
+     * Sets the value of the table property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setTable(final String value) {
+        this.table = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/OrderColumn.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/OrderColumn.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/OrderColumn.java
index 96cb5fa..398d0b8 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/OrderColumn.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/jpa/OrderColumn.java
@@ -1,171 +1,171 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.openejb.jee.jpa;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-
-/**
- * @Target({METHOD, FIELD}) @Retention(RUNTIME)
- * public @interface OrderColumn {
- * String name() default "";
- * boolean nullable() default true;
- * boolean insertable() default true;
- * boolean updatable() default true;
- * String columnDefinition() default "";
- * }
- * <p/>
- * <p/>
- * <p/>
- * <p>Java class for order-column complex type.
- * <p/>
- * <p>The following schema fragment specifies the expected content contained within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="order-column">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
- *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "order-column")
-public class OrderColumn {
-
-    @XmlAttribute
-    protected String name;
-    @XmlAttribute
-    protected Boolean nullable;
-    @XmlAttribute
-    protected Boolean insertable;
-    @XmlAttribute
-    protected Boolean updatable;
-    @XmlAttribute(name = "column-definition")
-    protected String columnDefinition;
-
-    /**
-     * Gets the value of the name property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getName() {
-        return name;
-    }
-
-    /**
-     * Sets the value of the name property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setName(final String value) {
-        this.name = value;
-    }
-
-    /**
-     * Gets the value of the nullable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isNullable() {
-        return nullable;
-    }
-
-    /**
-     * Sets the value of the nullable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setNullable(final Boolean value) {
-        this.nullable = value;
-    }
-
-    /**
-     * Gets the value of the insertable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isInsertable() {
-        return insertable;
-    }
-
-    /**
-     * Sets the value of the insertable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setInsertable(final Boolean value) {
-        this.insertable = value;
-    }
-
-    /**
-     * Gets the value of the updatable property.
-     *
-     * @return possible object is
-     * {@link Boolean }
-     */
-    public Boolean isUpdatable() {
-        return updatable;
-    }
-
-    /**
-     * Sets the value of the updatable property.
-     *
-     * @param value allowed object is
-     *              {@link Boolean }
-     */
-    public void setUpdatable(final Boolean value) {
-        this.updatable = value;
-    }
-
-    /**
-     * Gets the value of the columnDefinition property.
-     *
-     * @return possible object is
-     * {@link String }
-     */
-    public String getColumnDefinition() {
-        return columnDefinition;
-    }
-
-    /**
-     * Sets the value of the columnDefinition property.
-     *
-     * @param value allowed object is
-     *              {@link String }
-     */
-    public void setColumnDefinition(final String value) {
-        this.columnDefinition = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.openejb.jee.jpa;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * @Target({METHOD, FIELD}) @Retention(RUNTIME)
+ * public @interface OrderColumn {
+ * String name() default "";
+ * boolean nullable() default true;
+ * boolean insertable() default true;
+ * boolean updatable() default true;
+ * String columnDefinition() default "";
+ * }
+ * <p/>
+ * <p/>
+ * <p/>
+ * <p>Java class for order-column complex type.
+ * <p/>
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="order-column">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="nullable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="insertable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="updatable" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ *       &lt;attribute name="column-definition" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "order-column")
+public class OrderColumn {
+
+    @XmlAttribute
+    protected String name;
+    @XmlAttribute
+    protected Boolean nullable;
+    @XmlAttribute
+    protected Boolean insertable;
+    @XmlAttribute
+    protected Boolean updatable;
+    @XmlAttribute(name = "column-definition")
+    protected String columnDefinition;
+
+    /**
+     * Gets the value of the name property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Sets the value of the name property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setName(final String value) {
+        this.name = value;
+    }
+
+    /**
+     * Gets the value of the nullable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isNullable() {
+        return nullable;
+    }
+
+    /**
+     * Sets the value of the nullable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setNullable(final Boolean value) {
+        this.nullable = value;
+    }
+
+    /**
+     * Gets the value of the insertable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isInsertable() {
+        return insertable;
+    }
+
+    /**
+     * Sets the value of the insertable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setInsertable(final Boolean value) {
+        this.insertable = value;
+    }
+
+    /**
+     * Gets the value of the updatable property.
+     *
+     * @return possible object is
+     * {@link Boolean }
+     */
+    public Boolean isUpdatable() {
+        return updatable;
+    }
+
+    /**
+     * Sets the value of the updatable property.
+     *
+     * @param value allowed object is
+     *              {@link Boolean }
+     */
+    public void setUpdatable(final Boolean value) {
+        this.updatable = value;
+    }
+
+    /**
+     * Gets the value of the columnDefinition property.
+     *
+     * @return possible object is
+     * {@link String }
+     */
+    public String getColumnDefinition() {
+        return columnDefinition;
+    }
+
+    /**
+     * Sets the value of the columnDefinition property.
+     *
+     * @param value allowed object is
+     *              {@link String }
+     */
+    public void setColumnDefinition(final String value) {
+        this.columnDefinition = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/CompatibilityDescriptionGroup.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/CompatibilityDescriptionGroup.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/CompatibilityDescriptionGroup.java
index 9e2e55f..3b63a54 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/CompatibilityDescriptionGroup.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/CompatibilityDescriptionGroup.java
@@ -1,130 +1,130 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlType;
-
-/**
- * <p/>
- * Java class for CompatibilityDescriptionGroup complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained within
- * this class.
- * <p/>
- * <pre>
- * &lt;complexType name="CompatibilityDescriptionGroup">
- *   &lt;complexContent>
- *     &lt;extension base="{common.xmi}DescriptionGroup">
- *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="displayName" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="largeIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="smallIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
- *     &lt;/extension>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "CompatibilityDescriptionGroup")
-public class CompatibilityDescriptionGroup extends DescriptionGroup {
-
-    @XmlAttribute
-    protected String description;
-    @XmlAttribute
-    protected String displayName;
-    @XmlAttribute
-    protected String largeIcon;
-    @XmlAttribute
-    protected String smallIcon;
-
-    /**
-     * Gets the value of the description property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDescription() {
-        return description;
-    }
-
-    /**
-     * Sets the value of the description property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDescription(final String value) {
-        this.description = value;
-    }
-
-    /**
-     * Gets the value of the displayName property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getDisplayName() {
-        return displayName;
-    }
-
-    /**
-     * Sets the value of the displayName property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setDisplayName(final String value) {
-        this.displayName = value;
-    }
-
-    /**
-     * Gets the value of the largeIcon property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLargeIcon() {
-        return largeIcon;
-    }
-
-    /**
-     * Sets the value of the largeIcon property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLargeIcon(final String value) {
-        this.largeIcon = value;
-    }
-
-    /**
-     * Gets the value of the smallIcon property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getSmallIcon() {
-        return smallIcon;
-    }
-
-    /**
-     * Sets the value of the smallIcon property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setSmallIcon(final String value) {
-        this.smallIcon = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * <p/>
+ * Java class for CompatibilityDescriptionGroup complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained within
+ * this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="CompatibilityDescriptionGroup">
+ *   &lt;complexContent>
+ *     &lt;extension base="{common.xmi}DescriptionGroup">
+ *       &lt;attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="displayName" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="largeIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="smallIcon" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *     &lt;/extension>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "CompatibilityDescriptionGroup")
+public class CompatibilityDescriptionGroup extends DescriptionGroup {
+
+    @XmlAttribute
+    protected String description;
+    @XmlAttribute
+    protected String displayName;
+    @XmlAttribute
+    protected String largeIcon;
+    @XmlAttribute
+    protected String smallIcon;
+
+    /**
+     * Gets the value of the description property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /**
+     * Sets the value of the description property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDescription(final String value) {
+        this.description = value;
+    }
+
+    /**
+     * Gets the value of the displayName property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getDisplayName() {
+        return displayName;
+    }
+
+    /**
+     * Sets the value of the displayName property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setDisplayName(final String value) {
+        this.displayName = value;
+    }
+
+    /**
+     * Gets the value of the largeIcon property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLargeIcon() {
+        return largeIcon;
+    }
+
+    /**
+     * Sets the value of the largeIcon property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLargeIcon(final String value) {
+        this.largeIcon = value;
+    }
+
+    /**
+     * Gets the value of the smallIcon property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getSmallIcon() {
+        return smallIcon;
+    }
+
+    /**
+     * Sets the value of the smallIcon property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setSmallIcon(final String value) {
+        this.smallIcon = value;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/tomee/blob/48c99a5a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Description.java
----------------------------------------------------------------------
diff --git a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Description.java b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Description.java
index 8b5e704..ad3086a 100644
--- a/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Description.java
+++ b/container/openejb-jee/src/main/java/org/apache/openejb/jee/was/v6/common/Description.java
@@ -1,293 +1,293 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements.  See the NOTICE file distributed with
- *   this work for additional information regarding copyright ownership.
- *   The ASF licenses this file to You under the Apache License, Version 2.0
- *   (the "License"); you may not use this file except in compliance with
- *   the License.  You may obtain a copy of the License at
- *
- *       http://www.apache.org/licenses/LICENSE-2.0
- *
- *    Unless required by applicable law or agreed to in writing, software
- *    distributed under the License is distributed on an "AS IS" BASIS,
- *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *    See the License for the specific language governing permissions and
- *    limitations under the License.
- */
-package org.apache.openejb.jee.was.v6.common;
-
-import org.apache.openejb.jee.was.v6.xmi.Extension;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlAttribute;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlID;
-import javax.xml.bind.annotation.XmlIDREF;
-import javax.xml.bind.annotation.XmlType;
-import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
-import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * @since J2EE1.4 The description type is used by a description element to
- * provide text describing the parent element. The elements that use this
- * type should include any information that the Deployment Component's
- * Deployment File file producer wants to provide to the consumer of the
- * Deployment Component's Deployment File (i.e., to the Deployer).
- * Typically, the tools used by such a Deployment File consumer will
- * display the description when processing the parent element that
- * contains the description.
- * <p/>
- * The lang attribute defines the language that the description is
- * provided in. The default value is "en" (English).
- * <p/>
- * <p/>
- * <p/>
- * Java class for Description complex type.
- * <p/>
- * <p/>
- * The following schema fragment specifies the expected content contained
- * within this class.
- * <p/>
- * <pre>
- * &lt;complexType name="Description">
- *   &lt;complexContent>
- *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
- *       &lt;choice maxOccurs="unbounded" minOccurs="0">
- *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
- *       &lt;/choice>
- *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
- *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
- *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
- *     &lt;/restriction>
- *   &lt;/complexContent>
- * &lt;/complexType>
- * </pre>
- */
-@XmlAccessorType(XmlAccessType.FIELD)
-@XmlType(name = "Description", propOrder = {"extensions"})
-public class Description {
-
-    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
-    protected List<Extension> extensions;
-    @XmlAttribute
-    protected String lang;
-    @XmlAttribute
-    protected String value;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
-    @XmlID
-    protected String id;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected QName type;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String version;
-    @XmlAttribute
-    protected String href;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    @XmlIDREF
-    protected Object idref;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String label;
-    @XmlAttribute(namespace = "http://www.omg.org/XMI")
-    protected String uuid;
-
-    /**
-     * Gets the value of the extensions property.
-     * <p/>
-     * <p/>
-     * This accessor method returns a reference to the live list, not a
-     * snapshot. Therefore any modification you make to the returned list will
-     * be present inside the JAXB object. This is why there is not a
-     * <CODE>set</CODE> method for the extensions property.
-     * <p/>
-     * <p/>
-     * For example, to add a new item, do as follows:
-     * <p/>
-     * <pre>
-     * getExtensions().add(newItem);
-     * </pre>
-     * <p/>
-     * <p/>
-     * <p/>
-     * Objects of the following type(s) are allowed in the list
-     * {@link Extension }
-     */
-    public List<Extension> getExtensions() {
-        if (extensions == null) {
-            extensions = new ArrayList<Extension>();
-        }
-        return this.extensions;
-    }
-
-    /**
-     * Gets the value of the lang property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLang() {
-        return lang;
-    }
-
-    /**
-     * Sets the value of the lang property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLang(final String value) {
-        this.lang = value;
-    }
-
-    /**
-     * Gets the value of the value property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getValue() {
-        return value;
-    }
-
-    /**
-     * Sets the value of the value property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setValue(final String value) {
-        this.value = value;
-    }
-
-    /**
-     * Gets the value of the id property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getId() {
-        return id;
-    }
-
-    /**
-     * Sets the value of the id property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setId(final String value) {
-        this.id = value;
-    }
-
-    /**
-     * Gets the value of the type property.
-     *
-     * @return possible object is {@link QName }
-     */
-    public QName getType() {
-        return type;
-    }
-
-    /**
-     * Sets the value of the type property.
-     *
-     * @param value allowed object is {@link QName }
-     */
-    public void setType(final QName value) {
-        this.type = value;
-    }
-
-    /**
-     * Gets the value of the version property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getVersion() {
-        if (version == null) {
-            return "2.0";
-        } else {
-            return version;
-        }
-    }
-
-    /**
-     * Sets the value of the version property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setVersion(final String value) {
-        this.version = value;
-    }
-
-    /**
-     * Gets the value of the href property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getHref() {
-        return href;
-    }
-
-    /**
-     * Sets the value of the href property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setHref(final String value) {
-        this.href = value;
-    }
-
-    /**
-     * Gets the value of the idref property.
-     *
-     * @return possible object is {@link Object }
-     */
-    public Object getIdref() {
-        return idref;
-    }
-
-    /**
-     * Sets the value of the idref property.
-     *
-     * @param value allowed object is {@link Object }
-     */
-    public void setIdref(final Object value) {
-        this.idref = value;
-    }
-
-    /**
-     * Gets the value of the label property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getLabel() {
-        return label;
-    }
-
-    /**
-     * Sets the value of the label property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setLabel(final String value) {
-        this.label = value;
-    }
-
-    /**
-     * Gets the value of the uuid property.
-     *
-     * @return possible object is {@link String }
-     */
-    public String getUuid() {
-        return uuid;
-    }
-
-    /**
-     * Sets the value of the uuid property.
-     *
-     * @param value allowed object is {@link String }
-     */
-    public void setUuid(final String value) {
-        this.uuid = value;
-    }
-
-}
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ *   contributor license agreements.  See the NOTICE file distributed with
+ *   this work for additional information regarding copyright ownership.
+ *   The ASF licenses this file to You under the Apache License, Version 2.0
+ *   (the "License"); you may not use this file except in compliance with
+ *   the License.  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+package org.apache.openejb.jee.was.v6.common;
+
+import org.apache.openejb.jee.was.v6.xmi.Extension;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlID;
+import javax.xml.bind.annotation.XmlIDREF;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @since J2EE1.4 The description type is used by a description element to
+ * provide text describing the parent element. The elements that use this
+ * type should include any information that the Deployment Component's
+ * Deployment File file producer wants to provide to the consumer of the
+ * Deployment Component's Deployment File (i.e., to the Deployer).
+ * Typically, the tools used by such a Deployment File consumer will
+ * display the description when processing the parent element that
+ * contains the description.
+ * <p/>
+ * The lang attribute defines the language that the description is
+ * provided in. The default value is "en" (English).
+ * <p/>
+ * <p/>
+ * <p/>
+ * Java class for Description complex type.
+ * <p/>
+ * <p/>
+ * The following schema fragment specifies the expected content contained
+ * within this class.
+ * <p/>
+ * <pre>
+ * &lt;complexType name="Description">
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;choice maxOccurs="unbounded" minOccurs="0">
+ *         &lt;element ref="{http://www.omg.org/XMI}Extension"/>
+ *       &lt;/choice>
+ *       &lt;attGroup ref="{http://www.omg.org/XMI}ObjectAttribs"/>
+ *       &lt;attribute name="lang" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute name="value" type="{http://www.w3.org/2001/XMLSchema}string" />
+ *       &lt;attribute ref="{http://www.omg.org/XMI}id"/>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "Description", propOrder = {"extensions"})
+public class Description {
+
+    @XmlElement(name = "Extension", namespace = "http://www.omg.org/XMI")
+    protected List<Extension> extensions;
+    @XmlAttribute
+    protected String lang;
+    @XmlAttribute
+    protected String value;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+    @XmlID
+    protected String id;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected QName type;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String version;
+    @XmlAttribute
+    protected String href;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    @XmlIDREF
+    protected Object idref;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String label;
+    @XmlAttribute(namespace = "http://www.omg.org/XMI")
+    protected String uuid;
+
+    /**
+     * Gets the value of the extensions property.
+     * <p/>
+     * <p/>
+     * This accessor method returns a reference to the live list, not a
+     * snapshot. Therefore any modification you make to the returned list will
+     * be present inside the JAXB object. This is why there is not a
+     * <CODE>set</CODE> method for the extensions property.
+     * <p/>
+     * <p/>
+     * For example, to add a new item, do as follows:
+     * <p/>
+     * <pre>
+     * getExtensions().add(newItem);
+     * </pre>
+     * <p/>
+     * <p/>
+     * <p/>
+     * Objects of the following type(s) are allowed in the list
+     * {@link Extension }
+     */
+    public List<Extension> getExtensions() {
+        if (extensions == null) {
+            extensions = new ArrayList<Extension>();
+        }
+        return this.extensions;
+    }
+
+    /**
+     * Gets the value of the lang property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLang() {
+        return lang;
+    }
+
+    /**
+     * Sets the value of the lang property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLang(final String value) {
+        this.lang = value;
+    }
+
+    /**
+     * Gets the value of the value property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getValue() {
+        return value;
+    }
+
+    /**
+     * Sets the value of the value property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setValue(final String value) {
+        this.value = value;
+    }
+
+    /**
+     * Gets the value of the id property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getId() {
+        return id;
+    }
+
+    /**
+     * Sets the value of the id property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setId(final String value) {
+        this.id = value;
+    }
+
+    /**
+     * Gets the value of the type property.
+     *
+     * @return possible object is {@link QName }
+     */
+    public QName getType() {
+        return type;
+    }
+
+    /**
+     * Sets the value of the type property.
+     *
+     * @param value allowed object is {@link QName }
+     */
+    public void setType(final QName value) {
+        this.type = value;
+    }
+
+    /**
+     * Gets the value of the version property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getVersion() {
+        if (version == null) {
+            return "2.0";
+        } else {
+            return version;
+        }
+    }
+
+    /**
+     * Sets the value of the version property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setVersion(final String value) {
+        this.version = value;
+    }
+
+    /**
+     * Gets the value of the href property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getHref() {
+        return href;
+    }
+
+    /**
+     * Sets the value of the href property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setHref(final String value) {
+        this.href = value;
+    }
+
+    /**
+     * Gets the value of the idref property.
+     *
+     * @return possible object is {@link Object }
+     */
+    public Object getIdref() {
+        return idref;
+    }
+
+    /**
+     * Sets the value of the idref property.
+     *
+     * @param value allowed object is {@link Object }
+     */
+    public void setIdref(final Object value) {
+        this.idref = value;
+    }
+
+    /**
+     * Gets the value of the label property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getLabel() {
+        return label;
+    }
+
+    /**
+     * Sets the value of the label property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setLabel(final String value) {
+        this.label = value;
+    }
+
+    /**
+     * Gets the value of the uuid property.
+     *
+     * @return possible object is {@link String }
+     */
+    public String getUuid() {
+        return uuid;
+    }
+
+    /**
+     * Sets the value of the uuid property.
+     *
+     * @param value allowed object is {@link String }
+     */
+    public void setUuid(final String value) {
+        this.uuid = value;
+    }
+
+}