Uploaded image for project: '[Read Only] - Hippo Repository'
  1. [Read Only] - Hippo Repository
  2. REPO-1574

contentpropset should have the explicit bootstrap option to indicate that it is multiple or single valued

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Outdated
    • None
    • None
    • None
    • None

    Description

      We need to add support to the boostrap init item for contentpropset something as follows:

      <sv:property sv:name="hippo:multiple" sv:type="Boolean">
         <sv:value>true</sv:value>
      </sv:property>
      

      Namely without this explicit indication, we can never change an existing property from multiple to single valued.
      The code in org.onehippo.repository.bootstrap.instructions.ContentPropSetInstruction is currently something like:

          public PostStartupTask execute() throws RepositoryException {
              if (propexists) {   
                  // do stuff but keep the original property (single or multiple)
              } else {
                  // find out what to write: single or multiple values
              }
      

      If should change into:

          public PostStartupTask execute() throws RepositoryException {
              if (explicit-bootstrap-multi-or-single) {
                 // write property according explicit hippo:multiple true or false indication
              } else  if (propexists) {   
                  // do stuff but keep the original property (single or multiple)
              } else {
                  // find out what to write: single or multiple values
              }
      

      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: