Configuring a tag graph writer

Configure a tag graph writer to assign a tag to a document based on a predicate.

In the following steps you will be creating and/or configuring Spring beans in a Spring context file. A basic knowledge of Spring and the Spring Framework is required.

  1. Open or create a new Spring context file.
  2. Create a Tag Graph Writer bean.
    The following example will tag documents with the value of the ts:tsResponseRoleLabel metadata that is extracted from the XML content.
    <bean id="samples.tagGraphWriter.mappings" parent="alfresco.rdf.tagGraphWriter.mappings.abstract">
      <property name="mappings">
          <entry key="{}tsResponseRoleLabel" value="{}taggable" />
    Note: Unlike a category, a tag can be assigned to a document even if the tag does not yet exist in Alfresco.
  3. Restart the application server for your changes to take effect.