Expand my Community achievements bar.

SOLVED

VersionManagerImpl in Webconsole does not show multiple values

Avatar

Level 3

Hello everyone

I am currently in the process of setting up the automatic version purging service as described at http://docs.adobe.com/docs/de/aem/6-0/deploy/configuring/version-purging.html. There it is stated that both versionmanager.ivPaths as well as versionmanager.purgePaths (PID com.day.cq.wcm.core.impl.VersionManagerImpl) are multi value settings (String[]) however when I check at http://localhost:4502/system/console/configMgr/com.day.cq.wcm.core.impl.VersionManagerImpl I can only see a single textfield for each value.

Since I am configuring my OSGi configurations in the source code I checked the values in the repository (in my case it is /apps/internet/config.author/com.day.cq.wcm.core.impl.VersionManagerImpl) and there I can see that multiple paths do get stored in each property. Yet in the web console it does only show me the first of those values. Am I missing something here or is it supposed to be like this? Does this mean the version purging service does still work properly and takes all paths into account?

Following is the configuration I am using.

<?xml version="1.0" encoding="UTF-8"?> <jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0" jcr:primaryType="sling:OsgiConfig" versionmanager.createVersionOnActivation="{Boolean}true" versionmanager.purgingEnabled="{Boolean}true" versionmanager.purgePaths="[/content/internet,/content/dam]" versionmanager.ivPaths="[/content/internet,/content/dam]" versionmanager.maxAgeDays="{Long}0" versionmanager.maxNumberVersions="{Long}5"/>

Any help is appreciated.

Cheers

1 Accepted Solution

Avatar

Correct answer by
Level 10

Hi John,

As mentioned in the Adobe documentation, by default versionmanager.purgePaths (String[], default: {"/content"})

it will be {"/content"} and multi value can be set {"/content","/content/app"} with comma seperated.

and also, when you set multi value programatically, it should show comma seperated as it shows in the JCR properties.

View solution in original post

4 Replies

Avatar

Correct answer by
Level 10

Hi John,

As mentioned in the Adobe documentation, by default versionmanager.purgePaths (String[], default: {"/content"})

it will be {"/content"} and multi value can be set {"/content","/content/app"} with comma seperated.

and also, when you set multi value programatically, it should show comma seperated as it shows in the JCR properties.

Avatar

Level 3

Hi bsloki

Thank you for your response yet I am not sure if I understand you correctly. Since I am using a content package with XML files to deploy OSGi configs to AEM {"/path/a","/path/b"} is not a valid expression. If I am not mistaken the only valid expressions would be to either use a single string that is comma separated or the approach that I am already using [/path/a,/path/b]. When checking CRX only the latter approach is storing a property of type String[] while the comma-separated string gets stored as a String property (as expected). If "String[]" mentioned in the documentation is not referring to the CRX property type but some internal representation then I think the documentation needs to be more specific in this regard.

This may be a stupid question at this point but just to make sure I understood it correctly. Does that mean I have to store all paths as a single comma-separated string and ignore that the documentation is referring to it as String[] since it does not apply when using a content package with XML files to deploy OSGi configs? I have attached a few screenshots that show the XML, how it gets stored in CRX and what I see in the web console.

Thank you very much.

Cheers

Avatar

Level 10

hi john,

   It is string with comma seperated value. Documentation need correction & please file daycare ticket.

Thanks,

Sham

Avatar

Level 3

Hi there

Thank you both for helping me out with this.

Cheers