I am looking for a OOTB solution to generate a report for used and unused asset's under a dam node. Are there any query for that? I tried using generating report using this query
```path=/content/dam/applicaion-name
type=dam:Asset
property=jcr:content/usages/dam:score
property.value=1
p.limit=-1```
usage dam:score if 0 then its not used anywhere and if its greater than 0 it has uses.
I did tried using `ReferenceSearch.search()` and made a custom report for my use case. But is their any OOTB solution for that?
Solved! Go to Solution.
Views
Replies
Total Likes
There is no direct way to create that. At my work I faced the same requirement and I went following way:
1. Created a servlet
2. Created an html input field where the user can type in the path.
3. Created a query that looks for type "dam:Assest" in given path.
4. Collected and iterate through all founded ressources and used "ReferenceAggregator" for check.
4.1. If the returning list is empty, then current asset is not in use.
4.2. If the returning list is not empty, then current asset is in use.
5. Created output (either html output or csv file)
Note: This way takes a while, depends on the number of stored assets, so may be you need help from your server admnistrator
As far as my understanding in order for the dam:score to populate we need to enable asset insights unless its enabled and tracked with scripts at asset level there is no direct OOTB way to get it as report. Only way as per my understanding is create a servlet using AssetReferenceSearch method as shown this example and generate a CSV file which has asset name and referenced asset.I hope thats the way your generating now.
Once you enable asset insights the usage can be tracked in adobe analytics as a report
Hope this helps.
Regards,
Rajashankar.R
There is no direct way to create that. At my work I faced the same requirement and I went following way:
1. Created a servlet
2. Created an html input field where the user can type in the path.
3. Created a query that looks for type "dam:Assest" in given path.
4. Collected and iterate through all founded ressources and used "ReferenceAggregator" for check.
4.1. If the returning list is empty, then current asset is not in use.
4.2. If the returning list is not empty, then current asset is in use.
5. Created output (either html output or csv file)
Note: This way takes a while, depends on the number of stored assets, so may be you need help from your server admnistrator
Views
Likes
Replies