Asset metadata property need to update | Community
Skip to main content
Level 2
March 14, 2025
Solved

Asset metadata property need to update

  • March 14, 2025
  • 4 replies
  • 800 views

I have a requirement when an asset uploaded/created in DAM need to update some metadata property like if any spaces in title property need to remove and add some value to that property .What would be the best way to achieve this .

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by giuseppebaglio

If you require both Created and Modified, you must create two separate launchers.

4 replies

giuseppebaglio
Level 10
March 14, 2025

hi @dillipdi 

I suggest leveraging a new workflow launcher, as shown in the image.

The launcher will trigger the processing of your custom workflow, allowing you to incorporate all your custom logic. 

 

As you can see, the launcher has many options that you can use to restrict the type of item and/or event to be processed.

 

WF sample: https://github.com/Adobe-Consulting-Services/acs-aem-samples/blob/master/core/src/main/java/com/adobe/acs/samples/workflow/impl/SampleGraniteWorkflowProcess.java 

DillipDiAuthor
Level 2
March 14, 2025

Hi @giuseppebaglio  thanks for ur quick reply so i need to create a workflow with custom logic  and in launcher config it should be node Node type - created so when i create an asset it ll update the property . Will it work for those assets which is already created ?.

giuseppebaglio
giuseppebaglioAccepted solution
Level 10
March 14, 2025

If you require both Created and Modified, you must create two separate launchers.

AmitVishwakarma
Community Advisor
Community Advisor
March 14, 2025

Hi @dillipdi ,

1. Workflow Launcher Setup

     - You need to create a workflow launcher for the "Created" event so that when an asset is uploaded, the workflow triggers automatically.
     - If you also need to update metadata when an asset is modified, you will need another launcher for the "Modified" event.

2. Custom Workflow Implementation:
In your workflow model, add a process step that:
     - Reads the dc:title (or relevant metadata property).
     - Removes spaces and applies additional transformations as required.
     - Saves the updated metadata.

3. Existing Assets Handling
     - The launcher will not process already existing assets unless they are modified.
     - If you want to update existing assets, consider running a custom script or bulk workflow that processes assets already in DAM.

Regards,
Amit Vishwakarma

Level 4
March 17, 2025

hi @dillipdi - You can use AEM Workflow or an Event Listener with listener registered to listen to appropriate event. You can check for Asset Manager API as well to consider for bulk modifications need.

kautuk_sahni
Community Manager
Community Manager
April 1, 2025

@dillipdi Did you find the suggestions helpful? Please let us know if you need more information. If a response worked, kindly mark it as correct for posterity; alternatively, if you found a solution yourself, we’d appreciate it if you could share it with the community. Thank you!

Kautuk Sahni