Avoid Security Trimming when using SPXMLContentMapProvider in MOSS 2007
Had an interesting chat with MS Developer support today.
Several weeks ago, we had a performance issue with a custom application hosted in MOSS 2007. By issue, I mean pages were loading exceedingly slowly, to the point where requests were timing out with some frequency. After much digging around, we eventually traced it to a custom site map file. We were using the SPXMLContentMapProvider with a custom sitemap file. The site map file had role information for each node, and the provider had securityTrimmingEnabled set to "true" in the web.config. Setting securityTrimmingEnabled to "false" immediately resolved the issue.
After a fair bit of digging on their end, MS Developer support concluded that the SPXMLContentMapProvider should not be used with security trimming, or it could cause performance issues. Their recommendation was to " create a custom navigation provider inheriting from OOB SPXMLContentMapProvider and override the 'CreateChildNodes' method. You can implement the security trimming in the 'CeateChildNodes' method and can filter the nodes rather than relying on the parent SiteMapProvider which takes long time to do the security trimming in case of SPXMLContentMapProvider."
10/28/2009 10:36:53 PM
Published by
Harley Green
Category
Sharepoint
Back