Geronimo-Devtools
  1. Geronimo-Devtools
  2. GERONIMODEVTOOLS-728

The original geronimo deployment plan will be cleaned when importing an existing EAR project

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.0
    • Fix Version/s: 3.0-M2, 3.0
    • Component/s: eclipse-plugin
    • Labels:
      None
    • Environment:
      helios jee sr1

      Description

      When importing an existing EAR into eclipse, if selecting geronimo server as the target runtime, the original geronimo deployment descriptor will be flushed.

      For example, the plan in the ear file is like this:
      <?xml version="1.0" encoding="UTF-8" standalone="no"?>
      <!-- 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. -->
      <ejb:openejb-jar
      xmlns:app="http://geronimo.apache.org/xml/ns/j2ee/application-2.0"
      xmlns:bp="http://www.osgi.org/xmlns/blueprint/v1.0.0"
      xmlns:client="http://geronimo.apache.org/xml/ns/j2ee/application-client-2.0"
      xmlns:conn="http://geronimo.apache.org/xml/ns/j2ee/connector-1.2"
      xmlns:dep="http://geronimo.apache.org/xml/ns/deployment-1.2" xmlns:ejb="http://openejb.apache.org/xml/ns/openejb-jar-2.2"
      xmlns:jaspi="http://geronimo.apache.org/xml/ns/geronimo-jaspi"
      xmlns:log="http://geronimo.apache.org/xml/ns/loginconfig-2.0"
      xmlns:name="http://geronimo.apache.org/xml/ns/naming-1.2" xmlns:ns5="http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0"
      xmlns:pers="http://java.sun.com/xml/ns/persistence" xmlns:pkgen="http://openejb.apache.org/xml/ns/pkgen-2.1"
      xmlns:sec="http://geronimo.apache.org/xml/ns/security-2.0" xmlns:web="http://geronimo.apache.org/xml/ns/j2ee/web-2.0.1">
      <dep:environment>
      <dep:moduleId>
      <dep:groupId>default</dep:groupId>
      <dep:artifactId>corbahellobean_ejb</dep:artifactId>
      <dep:version>1.0</dep:version>
      <dep:type>car</dep:type>
      </dep:moduleId>
      </dep:environment>
      <ejb:enterprise-beans>
      <ejb:session>
      <ejb:ejb-name>HelloEJBRemote</ejb:ejb-name>
      <ejb:jndi-name>HelloEJBRemote</ejb:jndi-name>
      <ejb:tss-link>IOR3</ejb:tss-link>
      </ejb:session>
      </ejb:enterprise-beans>
      </ejb:openejb-jar>

      After import, the deployment descriptor will be flushed like this:
      <?xml version="1.0" encoding="UTF-8" standalone="no"?>
      <ejb:openejb-jar
      xmlns:app="http://geronimo.apache.org/xml/ns/j2ee/application-2.0"
      xmlns:bp="http://www.osgi.org/xmlns/blueprint/v1.0.0"
      xmlns:client="http://geronimo.apache.org/xml/ns/j2ee/application-client-2.0"
      xmlns:conn="http://geronimo.apache.org/xml/ns/j2ee/connector-1.2"
      xmlns:dep="http://geronimo.apache.org/xml/ns/deployment-1.2" xmlns:ejb="http://openejb.apache.org/xml/ns/openejb-jar-2.2"
      xmlns:jaspi="http://geronimo.apache.org/xml/ns/geronimo-jaspi"
      xmlns:log="http://geronimo.apache.org/xml/ns/loginconfig-2.0"
      xmlns:name="http://geronimo.apache.org/xml/ns/naming-1.2" xmlns:ns5="http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0"
      xmlns:pers="http://java.sun.com/xml/ns/persistence" xmlns:pkgen="http://openejb.apache.org/xml/ns/pkgen-2.1"
      xmlns:sec="http://geronimo.apache.org/xml/ns/security-2.0" xmlns:web="http://geronimo.apache.org/xml/ns/j2ee/web-2.0.1">
      <dep:environment>
      <dep:moduleId>
      <dep:groupId>default</dep:groupId>
      <dep:artifactId>corbahellobean_ejb</dep:artifactId>
      <dep:version>1.0</dep:version>
      <dep:type>car</dep:type>
      </dep:moduleId>
      </dep:environment>
      </ejb:openejb-jar>

        Activity

        Forrest Xia made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Han Hong Fang [ hanhongfang ]
        Hide
        Forrest Xia added a comment -

        Verified on GEP build 20110705, and it's fixed, so close it.

        Show
        Forrest Xia added a comment - Verified on GEP build 20110705, and it's fixed, so close it.
        Han Hong Fang made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 3.0-M2 [ 12316071 ]
        Fix Version/s 3.0 [ 12314732 ]
        Hide
        Han Hong Fang added a comment -

        fixed at revision: 1141445

        Show
        Han Hong Fang added a comment - fixed at revision: 1141445
        Hide
        Han Hong Fang added a comment -

        After further investigation, I think it should be a bug in GEP. The deployment plan openejb-jar.xml is automatically generated by GEP under namespace http://openejb.apache.org/xml/ns/openejb-jar-2.2, so it should be imported back correctly.

        The current problem is GEP is that it mixed the namespace http://openejb.apache.org/xml/ns/openejb-jar-2.2 and http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0.

        Show
        Han Hong Fang added a comment - After further investigation, I think it should be a bug in GEP. The deployment plan openejb-jar.xml is automatically generated by GEP under namespace http://openejb.apache.org/xml/ns/openejb-jar-2.2 , so it should be imported back correctly. The current problem is GEP is that it mixed the namespace http://openejb.apache.org/xml/ns/openejb-jar-2.2 and http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0 .
        Hide
        Han Hong Fang added a comment -

        http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0 is the excepted namespace for ejb, but in the sample attached, http://openejb.apache.org/xml/ns/openejb-jar-2.2 is used instead of http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0. During EAR file import, the deployment plan will be unmarshalled and then marchalled to filter the deployment plan. Elements lost during this conversion because incorrect namespace is used for ejb elements. To correct the EAR, please replace prefix ejb with prefix ns5, which is also defined in the sample. (BTW, I think ns5 should be replace with a meaningful prefix in GEP code)

        Show
        Han Hong Fang added a comment - http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0 is the excepted namespace for ejb, but in the sample attached, http://openejb.apache.org/xml/ns/openejb-jar-2.2 is used instead of http://geronimo.apache.org/xml/ns/j2ee/ejb/openejb-2.0 . During EAR file import, the deployment plan will be unmarshalled and then marchalled to filter the deployment plan. Elements lost during this conversion because incorrect namespace is used for ejb elements. To correct the EAR, please replace prefix ejb with prefix ns5, which is also defined in the sample. (BTW, I think ns5 should be replace with a meaningful prefix in GEP code)
        Forrest Xia made changes -
        Field Original Value New Value
        Attachment corbahellobean_ejb_ear.ear [ 12474373 ]
        Hide
        Forrest Xia added a comment -

        Attach one ear for reproducing this issue.

        Show
        Forrest Xia added a comment - Attach one ear for reproducing this issue.
        Forrest Xia created issue -

          People

          • Assignee:
            Han Hong Fang
            Reporter:
            Forrest Xia
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development