Metadata templates are a new feature in AEM DAM 5.6.1 that allows users to automatically pre-fill some of the metadata fields of assets when uploading them. This can be useful when uploading a large number of assets that must have some common metadata values, like tags or copyright information.
In order to define a metadata template, you will have to use the Digital Assets tool in the Classic UI, as there is no provision for managing metadata templates in the Touch UI yet. However, once a template has been applied to a folder, it is active regardless of the channel or interface used to upload the assets.
The definition and application of a metadata template is a two-step process. First, you need to create the metadata template proper, which is nothing more than a list of metadata fields with a name attached. Then, you have to assign the metadata template to a folder, thereby creating an instance of the template that specifies values for the fields contained in the template.
I realize this explanation sounds more complicated than it actually is in practice, so let’s look at an example.
Access the Digital Assets tool of an AEM 5.6.1 instance at http://server:port/damadmin, open the “New…” menu and select “New Metadata Template…”. Give the template a name and possibly a description then, in the next page of the dialog, select which metadata fields are to be included in the template.
To apply the newly created metadata template to a folder, select one and bring up the contextual menu by right-clicking and choose the “Apply Metadata Template…” option. In the first page of the dialog that pops up, select the metadata template you previously created and give a name to this instance.In the next page, specify actual values for one or more of the fields contained in the template. In the example of fig. we specify values for Title, Copyright, and Tags.
Now upload one or more assets to the folder and examine their metadata. You should see they have been filled with the values you input into the template instance.
You can now go back to the folder and change or remove the template instance. Notice that, if you do so, existing assets will not be modified. The new template instance definition will only apply to new assets.
The template instance will also se used for any subfolders of the one it is applied to, unless a different instance is applied to a descendant folder. In other words, when uploading an asset, the DAM will look for a template instance in the current folder and up its chain of ancestors, until it find one, and then it will stop. There is no way, presently, to combine different template instances as if they were one: Only the first one found is applied.
What happens when an asset already has metadata?
You might wonder what happens when you upload to a folder that is associated with a metadata template an asset that already contains some metadata that is automatically extracted, like IPTC headers. Is the value specified in the template going to be used, or is it the one inside the file? Well, the answer is both: Those fields will be created as multi-value properties under the jcr:content/metadata node, so no values from the file will be overwritten.
What happens when you move an existing asset to a folder that has a metadata template applied?
Nothing. Metadata templates are only applied when uploading new assets.