Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-3840

${project.version}, ${project.groupId} and ${project.artifactId} do not get replaced in page-composer artifact during build

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • High
    • Resolution: Fixed
    • None
    • 4.0.3
    • None
    • None
    • Platform Sprint 141

    Description

      Note that also the id 'annotationJsonSerializer' in SpringComponentManager-pagecomposer.xml is duplicate with 'annotationJsonSerializer' in SpringComponentManager-cmsrest.xml : That is tricky. Let's give it a different name.

      Some more background: In HSTTWO-3664

              <bean class="com.fasterxml.jackson.core.util.VersionUtil" factory-method="parseVersion">
              <constructor-arg value="${project.version}" />
              <constructor-arg value="${project.groupId}" />
              <constructor-arg value="${project.artifactId}" />
            </bean>
      

      got added to SpringComponentManager-pagecomposer.xml. This was copied from SpringComponentManager-cmsrest.xml which has something similar. However, the cms-rest/pom.xml has:

      <resources>
            <resource>
              <directory>src/main/resources</directory>
              <filtering>true</filtering>
            </resource>
          </resources>
      

      which is missing in page-composer/pom.xml : As a result, the built jar for the page-composer contains

      ${project.version}, ${project.groupId} and ${project.artifactId}
      

      Normally this should not matter because we have:

      <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
        <property name="ignoreUnresolvablePlaceholders" value="true" />
        <property name="systemPropertiesModeName"
      value="SYSTEM_PROPERTIES_MODE_FALLBACK" />
        <property name="location"
      value="classpath:/org/hippoecm/hst/site/container/SpringComponentManager.properties"
      />
      </bean>
      

      However, if someone overrides this or for some reason has ignoreUnresolvablePlaceholders=false, the HST spring component manager won't start up. There seems to be a customer having this problem

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              aschrijvers Ard Schrijvers
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: