If an image is present in AEM, I am deleting it and then downloading the updated image through assetManager.createAsset().
After downloading, the image is updated:
for example: http://localhost:4502/content/dam/torrid/pdp-assets/185/007/18500707/18500707_av1.jpg
If I access image through this url the downloaded image is previewed.
But if try accessing the image through: http://localhost:4502/assetdetails.html/content/dam/torrid/pdp-assets/185/007/18500707/18500707_av1.... getting the old image, the one before downloading.
Any help regarding the issue is very much appreciated.
Thank you,
Nandan
Solved! Go to Solution.
Views
Replies
Total Likes
@krati_garg thank you for your reply.
I will delete the image if already present in AEM and then download the image by passing image URL to assetManager.createAsset().
The issue is resolved now,
I was calling assetManger API after deleting the image without saving the session.
Adding session.save() after deleting the image and then downloading the new image solved the issue.
@nandan123 Please check the error logs for any errors, when you hit asset details page. Probably a mandatory field must be missing.
Also, please try to elaborate more on usecase, as in when you delete the image, how you update it, if the updated image has the same name as the previous one. If you have implemented this using a Workflow.
Also, please note that Asset Manager API is now deprecated, in case you are on AEMaaCS
@krati_garg thank you for your reply.
I will delete the image if already present in AEM and then download the image by passing image URL to assetManager.createAsset().
The issue is resolved now,
I was calling assetManger API after deleting the image without saving the session.
Adding session.save() after deleting the image and then downloading the new image solved the issue.
Views
Likes
Replies