Set Composite Properties in Global Properties File - Alfresco Content Services - 23.4 - 23.4 - Ready - Alfresco - external

Alfresco Content Services

Platform
Alfresco
Product
Alfresco Content Services
Release
23.4
License

The imap.server.mountPoints property is used as an example for setting composite properties.

The ImapConfigMountPointsBean class that holds the component beans has four properties of its own:

  • beanName
  • store
  • rootPath
  • mode
  1. Open the <classpathRoot>/alfresco-global.properties file.
  2. To set some overall defaults for all component instances, use the format:
     <property>.default.<component property>

    These values would show up, for example, when you added a new component instance but didn’t specify its properties.

    For example:

     imap.server.mountPoints.default.store=${spaces.store}
     imap.server.mountPoints.default.rootPath=/${spaces.company_home.childname}
     imap.server.mountPoints.default.mode=virtual
    

    This example doesn’t define a default for beanName because there’s a way of populating it for each instance.

  3. To set up the imap.server.mountPoints with a composite value, set the master composite property using a comma-separated list.For example:
     imap.server.mountPoints=Repository_virtual,Repository_archive
    

    This defines that the property contains two ImapConfigMountPointsBean instances, named Repository_virtual and Repository_archive. Because ImapConfigMountPointsBean implements the BeanNameAware Spring interface and has a beanName property, these instance names are automatically set as the bean names.

  4. To define component properties specific to each component instance, use the format:
     <property>.value.<component instance name>.<component property>

    For example:

     imap.server.mountPoints.value.Repository_virtual.mode=virtual
     imap.server.mountPoints.value.Repository_archive.mode=archive