Uploaded image for project: 'Red Hat Data Grid'
  1. Red Hat Data Grid
  2. JDG-359

Conf. Conversion Tool: singleFile location property parsing

    XMLWordPrintable

Details

    • Bug
    • Status: Verified (View Workflow)
    • Minor
    • Resolution: Done
    • JDG 7.0.0 ER5
    • JDG 7.3 DR1
    • Library
    • None
    • DR1
    • JDG Sprint #19

    Description

      In case when persistence is configured with SingleFileStore class and the location is provided with properties, the generated xml contains both the path attribute and the property with the same value.

      This code:

      <infinispan>
      <namedCache name="withLoaderDefaults">
              <persistence>
                  <store class="org.infinispan.persistence.file.SingleFileStore">
                      <properties>
                          <property name="location" value="/tmp/Another-FileCacheStore-Location" />
                      </properties>
                  </store>
              </persistence>
          </namedCache>
      </infinispan>
      

      is converted to:

      <infinispan>
          <threads/>
          <cache-container name="DefaultCacheManager">
              <jmx/>
              <local-cache name="withLoaderDefaults">
                  <transaction mode="NONE"/>
                  <persistence>
                      <file-store path="/tmp/Another-FileCacheStore-Location">
                          <property name="location">
                              /tmp/Another-FileCacheStore-Location
                          </property>
                      </file-store>
                  </persistence>
              </local-cache>
      </cache-container>
      </infinispan>
      

      Also, if the value of location property is set to e.g.

      ${java.io.tmpdir}
      

      , then the evaluated value is placed in the generated xml.
      So the following xml:

      <infinispan>
          <namedCache name="withLoaderDefaults">
              <persistence>
                  <store class="org.infinispan.persistence.file.SingleFileStore">
                      <properties>
                          <property name="location" value="${java.io.tmpdir}" />
                      </properties>
                  </store>
              </persistence>
          </namedCache>
      </infinispan>
      

      is converted to:

      <infinispan>
          <threads/>
          <cache-container name="DefaultCacheManager">
              <jmx/>
              <local-cache name="withLoaderDefaults">
                  <transaction mode="NONE"/>
                  <persistence>
                      <file-store path="/tmp">
                          <property name="location">
                              /tmp
                          </property>
                      </file-store>
                  </persistence>
              </local-cache>
      </cache-container>
      </infinispan>
      

      Attachments

        Issue Links

          Activity

            People

              ttarrant@redhat.com Tristan Tarrant
              amanukya@redhat.com Anna Manukyan
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: