During the lab, you will be configuring a new Property Synchronizer to synchronize the
troubleshooting short description (ts:shortdesc) with the Alfresco description property
(cm:description).
-
In the lab folder, create a new Spring context file named
context.xml
.
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd">
</beans>
-
Open the
context.xml
file in your favorite editor.
-
Create a new Property Synchronizer bean.
-
Add the following properties to the Property Synchronizer bean as required:
Property |
Type |
Mandatory |
Description |
properties
|
Collection <QName> |
Required |
Collection of QNames identifying properties. Use a fully-qualified name with Clark notation as the key of the entry. |
<bean id="samples.ts.propertySynchronizer.description" parent="alfresco.node.propertySynchronizer.abstract" depends-on="samples.ts.model">
<property name="properties">
<list>
<value>{http://www.componize.com/model/samples/troubleshooting/1.0/}shortdesc</value>
<value>{http://www.alfresco.org/model/content/1.0}description</value>
</list>
</property>
</bean>
-
Save your changes.
-
Test your Property Synchronizer with the
com.componize.samples.lab06.PropertySynchronizerTest unit test.
-
Deploy your files to the application server.
-
Once the application server has started, connect to the Alfresco Share
interface.
-
Use the Edit Properties action on the
troubleshooting-sample.dita
file to modify the value of the ts:shortdesc property.
The cm:description property should be updated with the
modified value.