Expand my Community achievements bar.

SOLVED

Uploading New Versions of an Asset in AEM Assets

Avatar

Level 3

Hi team, 

 

We are currently testing the capabilities of AEM Assets and we have been able to find videos that walk us through how to upload new versions of assets in AEM Assets. We have been unable to find any that help us fully understand how the naming convention of the new asset needs to be the same as the existing asset in AEM Assets to be added as a new version. I've recently uploaded a new asset with the same name as the existing asset into AEM Assets and it uploaded as a new separate asset in the system. Is there a reason why this would happen? Would metadata have anything to do with it? Has anyone else had this experience or know of any documentation that covers the naming convention and versioning relationship in depth? 

 

Best,

E

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Hi @Erika_Antkowiak 

 

Please find answers inline:

 

We have been unable to find any that help us fully understand how the naming convention of the new asset needs to be the same as the existing asset in AEM Assets to be added as a new version.

[KG]: To get a prompt for new version while uploading another asset, there are following rules:

1. New asset should be uploaded in the same folder as the older one for creating a new version

2. File Extension should be same

3. File Name should be same

Not meeting any of the above rules would make AEM believe that its a new asset and it will not prompt you for a new version.


I've recently uploaded a new asset with the same name as the existing asset into AEM Assets and it uploaded as a new separate asset in the system.

[KG]: Please check out above response

Is there a reason why this would happen? Would metadata have anything to do with it? Has anyone else had this experience or know of any documentation that covers the naming convention and versioning relationship in depth? 

[KG]: As per OOTB functionality, as far as same filename+extension matches, it would detect the new asset upload as a candidate for new version. However, if you want to customize this behavior based upon binaries, you might need to enable duplicate detection config "Day CQ DAM Create Asset" OSGI config. This config depends upon dam:sha1 value(by default - can be changed to any other metadata asset property).

dam:sha1 is  SHA 1 checksum value of the binary and if this is same for any two assets, it would not even check for Filenames and would take both assets as same and shall prompt you for new version.

 

https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service/content/assets/admin/det...

 

Hope this helps

View solution in original post

9 Replies

Avatar

Level 8

@Erika_Antkowiak : 

For asset versioning, it seems to work with same name only (I have tested on 6.5).


However, there is a way to identify if the same Asset already exists in entire Assets irrespective of its name or assets path. This would help to know if same asset already exists and at which path it is present.

Please refer: for AEMaaCS: https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service/content/assets/admin/det...
For AEM 6.5: https://experienceleague.adobe.com/en/docs/experience-manager-65/content/assets/managing/duplicate-d...

 

The detect duplicate feature is now enabled in Assets. When a user attempts to upload an asset that exists in Experience Manager, the system checks for conflict and indicates it. The assets are identified using SHA-1 hash stored at jcr:content/metadata/dam:sha1, which means duplicate assets are detected irrespective of the filenames.

 

I am not sure if this helps with your use-case but let me know if it does.
thanks.

Avatar

Correct answer by
Employee Advisor

Hi @Erika_Antkowiak 

 

Please find answers inline:

 

We have been unable to find any that help us fully understand how the naming convention of the new asset needs to be the same as the existing asset in AEM Assets to be added as a new version.

[KG]: To get a prompt for new version while uploading another asset, there are following rules:

1. New asset should be uploaded in the same folder as the older one for creating a new version

2. File Extension should be same

3. File Name should be same

Not meeting any of the above rules would make AEM believe that its a new asset and it will not prompt you for a new version.


I've recently uploaded a new asset with the same name as the existing asset into AEM Assets and it uploaded as a new separate asset in the system.

[KG]: Please check out above response

Is there a reason why this would happen? Would metadata have anything to do with it? Has anyone else had this experience or know of any documentation that covers the naming convention and versioning relationship in depth? 

[KG]: As per OOTB functionality, as far as same filename+extension matches, it would detect the new asset upload as a candidate for new version. However, if you want to customize this behavior based upon binaries, you might need to enable duplicate detection config "Day CQ DAM Create Asset" OSGI config. This config depends upon dam:sha1 value(by default - can be changed to any other metadata asset property).

dam:sha1 is  SHA 1 checksum value of the binary and if this is same for any two assets, it would not even check for Filenames and would take both assets as same and shall prompt you for new version.

 

https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service/content/assets/admin/det...

 

Hope this helps

Avatar

Level 3

@krati_garg Thanks for the outline you provided! I'm wondering if you could elaborate on your - File Extension should be the same - note. Can you explain the difference between the File Extension and the File Name? I want to make sure I understand.

 

Best,

E

Avatar

Community Advisor

Hi @Erika_Antkowiak Well let me jump in here real quick
@krati_garg most likely meant the suffix -  
logo-new.eps vs logo-new.svg 
logo-new beeing the file name and svg/eps/ai etc. to be the file extension.
I would also like to add that the file name is considered case sensitive.
So "logo-new.eps" can't be versioned with "Logo-New.eps".

There was a time when the filename was displayed in all caps - which caused some confusion when somebody wanted to create a version.

@krati_garg, please correct me if I am wrong - but I do think that metadata has an impact on dam:sha1. 

So in case you upload logo-new.eps into folder A, then edit some metadate, e.g. add a text to its dc:description, and then later upload the same logo-new.eps into folder B - the duplication detection might not be able to recognise it as a duplicate.

Avatar

Employee Advisor

@Adilos-Cantuerk Metadata which is embedded in Binary has an impact. This is stored in Binary in XMP format.

Only if XMP writeback workflow is enabled, and then an edit to any Metadata Field which gets written back to binary, would eventually change its dam:sha1 value. Now even if you upload the same asset with same name, it would not be recognized as duplicate because its the binary has changed.

 

Agree to your points related to extension and case sensitivity of file names.

 

 

Avatar

Level 3

@krati_garg @Kamal_Kishor So to confirm, it sounds like either the metadata or file extension may be the issue here. I noticed when using card view in AEM Assets it lists the title of the asset under an image of the asset AND then lists the name of the asset with an extension under Document. Do either of you know what the name + file extension under document comes from? Can it be edited? I've provided a grayed out example of what I'm referencing below.

 

Screenshot 2024-04-09 at 11.11.59 AM.png

@krati_garg @Adilos-Cantuerk Thank you both for your insight on this item. Nevermind my last question above. I was able to talk through this issue with a member of the Adobe AEM Assets team today and we are now able to upload updated versions of existing assets in AEM Assets. I've outlined our findings below.

 

To upload a new version of an existing asset in AEM Assets you must:

  1. Confirm that the title of the existing asset in AEM Assets and the updated asset being uploaded as a new version are the same.
    • Can be edited in AEM Assets under Properties.
  2. Confirm that the document/asset name of the existing asset in AEM Assets and the the updated asset being uploaded as a new version are the same.
    • Can be edited in AEM Assets under ..., Move.

 

Screenshot 2024-04-09 at 11.11.59 AM copy.jpg

Avatar

Community Advisor

I am not sure if dc:title or any other metadata will block the file from beeing recognized as a version. The filename (and assetpath are the key factors).
As long as the filename matches, and you are uploading the new version into the right folder, this should do the trick.

Avatar

Community Advisor

@Erika_Antkowiak Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community



Esteban Bustamante