07-27-2018 12:42 PM
Hi Alfresco Experts,
Please can you tell me why bootstrapping is not working as expected? I am putting my share and platform jar under .
/opt/alfresco/app/alfresco/modules/share/ and /opt/alfresco/app/alfresco/modules/platform
Currently, I see that the first JAR (5.1 version) that I added got picked up by alfresco. I then added but the next versioned JAR (5.2) but that did not get picked up by alfresco. The logs do say that the jar version has been upgraded. But I don't see the changes getting applied by alfresco.
1. I have tried both the ImporterModuleComponents with the same moduleId but different versions ((higher version to the previous) - This does not work
2. I have also tried have different names and different version (higher version to the previous) - This also does not work
3. I also added a depends On with the higher version dependent on the lower version. This also does not work
<bean id="com.test.alfresco.bootstrap.site.sg"
class="org.alfresco.repo.module.ImporterModuleComponent"
parent="module.baseComponent">
<!-- Module Details -->
<property name="moduleId" value="alfresco-bootstrap-platform-jar" />
<property name="name" value="test-sg" />
<property name="description" value="Bootstrap test SG site" />
<property name="sinceVersion" value="5.1" />
<property name="appliesFromVersion" value="5.1" />
<!-- Data properties -->
<property name="importer" ref="spacesBootstrap"/>
<property name="bootstrapViews">
<list>
<props>
<prop key="path">/${alfresco_user_store.system_container.childname}</prop>
<prop key="location">alfresco/module/${project.artifactId}/bootstrap/sites/test-sg/groups.xml</prop>
</props>
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.sites.childname}</prop>
<prop key="location">alfresco/module/${project.artifactId}/bootstrap/sites/test-sg/Contents.acp</prop>
</props>
</list>
</property>
</bean>
<bean id="com.test.alfresco.bootstrap.test.sg.folders"
class="org.alfresco.repo.module.ImporterModuleComponent"
parent="module.baseComponent">
<property name="moduleId" value="alfresco-bootstrap-platform-jar" />
<property name="name" value="test-sg-folders" />
<property name="description" value="test SG folders" />
<property name="sinceVersion" value="5.2" />
<property name="appliesFromVersion" value="5.2" />
<property name="importer" ref="spacesBootstrap"/>
<property name="bootstrapViews">
<list>
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.sites.childname}/cm:test-sg/cm:documentLibrary</prop>
<prop key="location">alfresco/module/alfresco-bootstrap-platform-jar/bootstrap/bootstrap-folders.xml</prop>
</props>
</list>
</property>
</bean>
07-30-2018 03:15 AM
Once a patch has been applied to an Alfresco installation, it's not applied anymore.
You should change "moduleId" value in order to be loaded.
07-30-2018 08:59 AM
I changed the moduleId to a different name and also increased the version., but that did not import the new module with the higher version. Not sure what I am missing here.
07-30-2018 09:09 AM
Have you tried with...
<property name="executeOnceOnly" value="false" />
?
07-30-2018 09:42 AM
But won't that try executing the module every time alfresco starts up? That will cause issues if my importer is bootstrapping content model or sites for example, isn't it?
07-30-2018 09:59 AM
Yes.
You can also change your strategy and use "org.alfresco.repo.admin.patch.impl.GenericBootstrapPatch" instead.
Explore our Alfresco products with the links below. Use labels to filter content by product module.