Unplanned
Last Updated: 26 Nov 2019 12:25 by ADMIN
Chris
Created on: 20 Jun 2019 12:31
Type: Bug Report
4
Occasional NullReferenceException on rendering

StackTrace of the error:

 System.NullReferenceException: Object reference not set to an instance of an object.
   at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
   at Telerik.Reporting.Interfaces.LocalizationContext.GetString(String resx, String key)
   at Telerik.Reporting.SRDescriptionAttribute.get_Description()
   at Telerik.Reporting.Expressions.EnumContextManager.GetItem(Type enumType)
   at Telerik.Reporting.Processing.ReportExpressionContext.RegisterAllReportingEnums()
   at Telerik.Reporting.Processing.ReportExpressionContext..ctor(Type reportType, AssemblyRefManager assemblyRefManager)   at Telerik.Reporting.Processing.ReportParametersManager`1.CreateExpressionContext(Report report, IList`1 runtimeParameters, AssemblyRefManager references)
   at Telerik.Reporting.Processing.ReportParametersManager`1..ctor(Report definitionReport, IEnumerable`1 definitionParameters, IDictionary`2 reportSourceParameters, IDataProviderContext dataProviderContext, AssemblyRefManager references)
   at Telerik.Reporting.Processing.DocumentParametersManager`1.CreateManager(Report definition, IDataProviderContext dataProviderContext, IParameterValueParser parameterValueParser, IDictionary`2 rsParameters, AssemblyRefManager references)   at Telerik.Reporting.Processing.DocumentParametersManager`1.CreateManagers(IProcessingContext context, IParameterValueParser parameterValueParser)
   at Telerik.Reporting.Processing.DocumentParametersManager`1..ctor(ResolvedReportDocument resolvedReports, IProcessingContext processingContext, IParameterValueParser parameterValueParser)
   at Telerik.Reporting.Processing.ReportProcessor.ProcessReportSource(ReportSource reportSource, IRenderingContext context)
   --- End of inner exception stack trace ---
   at Telerik.Reporting.Processing.ReportProcessor.ProcessReportSource(ReportSource reportSource, IRenderingContext context)
   at Telerik.Reporting.Processing.ReportProcessor.ProcessReportSource(ReportSource reportSource, Hashtable deviceInfo, IRenderingContext context)
   at Telerik.Reporting.Processing.ReportProcessor.ProcessAndRender(String format, ReportSource reportSource, Hashtable deviceInfo, IRenderingContext renderingContext, CreateStream createStreamCallback)
   at Telerik.Reporting.Processing.ReportProcessor.ProcessAndRenderStateless(String format, ReportSource reportSource, Hashtable deviceInfo, IRenderingContext renderingContext, CreateStream createStreamCallback)
   at Telerik.Reporting.Processing.ReportProcessor.RenderReport(String format, ReportSource reportSource, Hashtable deviceInfo, CreateStream createStreamCallback, String& documentName)

2 comments
ADMIN
Todor
Posted on: 26 Nov 2019 12:25

Hi Karl,

Indeed, the issue seems to happen only on startup when trying to render multiple reports at the same time. The workaround is initially to run a single report in the main thread - this will initialize the static dictionary holding the resources. Then you should be able to continue with multi-thread rendering.

Regards,
Todor
Progress Telerik

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Karl
Posted on: 19 Nov 2019 18:43
We are also getting this.  Totally random, but only happens on the first access of a report after the server is started.