After upgrading to SSRS 2016 SP1 CU8, or SSRS 2016 SP2, you might see the following error when running reports or connecting to a SSAS data source using HTTP/MSMDPump with Basic Authentication, “Object reference not set to an instance of an object.”

If you look in the Report Server Error logs, you’ll see the following exception:

ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: , Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Cannot create a connection to data source ‘TestRS1’. —> System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.AnalysisServices.AdomdClient.HttpStream.ImpersonateLogonIdentityAndExecute(Action action)
at Microsoft.AnalysisServices.AdomdClient.HttpStream.GetRequestStream()
at Microsoft.AnalysisServices.AdomdClient.HttpStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at Microsoft.AnalysisServices.AdomdClient.CompressedStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at System.IO.StreamWriter.Flush(Boolean flushStream, Boolean flushEncoder)
at Microsoft.AnalysisServices.AdomdClient.XmlaClient.EndRequest(Boolean useBinaryXml)
at Microsoft.AnalysisServices.AdomdClient.XmlaClient.SendMessage(Boolean endReceivalIfException, Boolean readSession, Boolean readNamespaceCompatibility)
at Microsoft.AnalysisServices.AdomdClient.XmlaClient.SupportsProperty(String propName)
at Microsoft.AnalysisServices.AdomdClient.XmlaClient.Connect(ConnectionInfo connectionInfo, Boolean beginSession)
at Microsoft.AnalysisServices.AdomdClient.AdomdConnection.XmlaClientProvider.Connect(Boolean toIXMLA)
at Microsoft.AnalysisServices.AdomdClient.AdomdConnection.ConnectToXMLA(Boolean createSession, Boolean isHTTP)
at Microsoft.AnalysisServices.AdomdClient.AdomdConnection.Open()
at Microsoft.ReportingServices.DataExtensions.AdomdExceptionHandler.Execute(String connectionString, Action action)
at Microsoft.ReportingServices.DataExtensions.AdoMdConnectionBase.Open()
at Microsoft.ReportingServices.Diagnostics.DataExtensionConnectionBase.<>c__DisplayClass5.b__4()
— End of inner exception stack trace —;

This is due to a defect in the ADOMD client that Reporting Services is referencing. Unfortunately, there’s currently only a workaround at the moment for Reporting Services 2016.

Resolution

1. Download and install the latest ADOMD client library from here: https://docs.microsoft.com/en-us/azure/analysis-services/analysis-services-data-providers
2. Go to the following folder to find your web.config file for Reporting Services, and make a backup copy before proceeding: “C:\Program Files\Microsoft SQL Server\MSRS13.MSSQLSERVER\Reporting Services\ReportServer\web.config”
3. Modify the bindingRedirect for Microsoft.AnalysisServices.AdomdClient to reflect the newest version, which is 15.0.0.0. Like so:

Once that is done, go ahead and restart Reporting Services Service, and you should now see a successful connection like you had before.

If you’re seeing the same issues while using SQL Server Management Studio, Report Builder, or SSRS2017/PBIRS, the fix for this issue is likely to be released in July 2018.