Uploaded image for project: 'PUBLIC - Liferay IDE'
  1. PUBLIC - Liferay IDE
  2. IDE-1912

Liferay IDE deployment differs from mvn WAR - missing POM property

    Details

      Description

      When I drag-and-drop my portlet project onto the Liferay EE server in the servers view, the exploded webapp that is copied into the Liferay webapps directory is different than the generated WAR file from a clean maven build.

      I have configured resource filtering in the build configuration in my POM:
      <resources>
      <resource>
      <directory>src/main/resources</directory>
      <filtering>true</filtering>
      </resource>
      </resources>

      ...and I set this property in the global POM properties:
      <properties>
      <timestamp>TEST</timestamp>
      </properties>

      In src/main/resources, I have a properties file called internal.properties:
      build.version=${version}-${timestamp}

      When I do "mvn clean install", maven correctly filters the property file. In the target/WEB-INF/classes directory (and in the zipped-up war file) I see that "internal.properties" has the correct values:
      build.version=1.0.1-TEST

      BUT if I drag-and-drop the Eclipse project onto the Liferay EE server in the Servers View, the property file is not interpolated. I check the EE server's tomcat/webapps directory and I see that the property file is there, but the contents differ:
      build.version=1.0.1-${timestamp}

      The Liferay IDE filtered the ${version} substitution but not my custom property from the POM.

      I tried deleting the app from the EE server (verifying that it was removed from webapps) but this did not resolve my issue.

      P.S. In my test, I hard-coded the property value in the project's POM, but in reality I want to use a property generated by the buildnumber-maven-plugin during the 'initialize' maven lifecycle phase. I cut this other plugin out of my config in order to eliminate it as a source of problems before reporting the issue.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                5 years, 21 weeks ago

                Packages

                Version Package