I have some users who are bloating some confluence pages with macros which is causing slow performance.
I looked at the AJS API and saw that there is a "AJS.params" object but couldn't find any macro info in there. Also examined the AJS.MacroBrowser API and couldn't find anything useful..
If you have access to running a query against the database this will give you a list of your pages sorted by macro count per page.
(len(cast(B.BODY as nvarchar(max))) - len(replace(cast(B.BODY as nvarchar(max)), '<ac:structured-macro', ''))) / len('<ac:structured-macro') as MACROCOUNT
from CONTENT C
inner join BODYCONTENT B on C.CONTENTID = B.CONTENTID
inner join SPACES S on C.SPACEID = S.SPACEID
where C.PREVVER is null
and C.CONTENT_STATUS = 'current'
and C.CONTENTTYPE in ('PAGE', 'BLOGPOST')
order by MACROCOUNT desc
Badges are a great way to show off community activity, whether you’re a newbie or a Champion.Learn more
Hi Community, Jessica here from the Confluence Product Marketing team! July’s community challenge is all about sharing pictures — and as an extension of our first post on what ...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs