We're having significant performance problems related to the internal design of the Microsoft "ReportServer" catalog. If anyone is knowledgable about both the SSRS catalog and SQL performance tuning, I'd love to hear some feedback.
I should start by saying we have a significant reporting load in SSRS and much of it is generated via Subscriptions. As part of the maintenance of these subscriptions we often enumerate them (for all reports, all users) from a background task. This involves calling a web service method ListSubscriptions(null, null).
The ListSubscriptions method is often very, very slow. After a little digging, I come to find that the "ReportServer" SQL database catalog is behaving badly (a SQL database sitting on a remote, clustered database server). After connecting to the catalog, the SSRS server appears to be making a database query similar to the one below.
set statistics io on select S.[SubscriptionID], S.[Report_OID], S.[ReportZone], S.[InactiveFlags], S.[ModifiedDate], S.[LastRunTime], S.[Version], S.[Locale], S.[DeliveryExtension], S.[Description], S.[LastStatus], S.[EventType], --THESE NTEXT S.[MatchData], S.[Parameters], S.[DataSettings], S.[ExtensionSettings] from [Subscriptions] S with (nolock) set statistics io off
The query only returns about 5,000 rows. If I hack further at this SQL query to eliminate the last four NTEXT columns, it comes back instantly. Here is the comparison of the io statistics with and without the NTEXT columns::
Table 'Subscriptions'. Scan count 1, logical reads 519, physical reads 0, read-ahead reads 0, lob logical reads 53669, lob physical reads 0, lob read-ahead reads 1373.
PERFORMANCE: 10 seconds
Table 'Subscriptions'. Scan count 1, logical reads 519, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.
PERFORMANCE: immediate
Notice the "lob logical reads" which are incredibly high in the normal case. Is there some database tuning or regular maintenance that can be done to resolve this issue?
Thanks in advance,
David
David Beavon