Skip to content

History.Parser.HistoryItemParser.ParseEmailLog times out on a HUGE email #37

@gsherman

Description

@gsherman

likely the regex is timing out.
when we've run into issues like this before, we've executed the regex on its own thread with a timeout, so we can trap for it and handle it.

this seems like a very unrealistic test

2017-11-13 18:59:05,923 [13] ERROR Agent.Core.Configuration.UnhandledExceptionLoggingBehavior - (null) A route /agent/core/history?Id=1002813&Type=case&IsVerbose=false&_=1510627020603 caused an exception that was not handled. 
System.Threading.ThreadAbortException: Thread was being aborted.
   at Dovetail.SDK.Bootstrap.History.Parser.HistoryItemParser.ParseEmailLog(String input)
   at Dovetail.SDK.Bootstrap.History.Parser.HistoryOutputParser.EncodeEmailLog(String input)
   at Dovetail.SDK.Bootstrap.History.CommonActEntryBuilderDSLExtensions.EncodeEmail(IHistoryOutputParser historyOutputParser, HistoryItem item)
   at Dovetail.SDK.Bootstrap.History.HistoryItemAssembler.createActivityDTOFromMapper(ActEntry actEntry, IDictionary`2 templateRelatedGenerics)
   at System.Linq.Enumerable.WhereSelectListIterator`2.MoveNext()
   at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
   at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
   at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
   at Dovetail.SDK.Bootstrap.History.HistoryItemAssembler.Assemble(ClarifyGeneric actEntryGeneric, IDictionary`2 templatesByCode, HistoryRequest historyRequest)
   at Dovetail.SDK.Bootstrap.History.HistoryBuilder.Build(HistoryRequest request, Action`2 genericAction)
   at Dovetail.SDK.Bootstrap.History.AssemblerPolicies.CaseHistoryAssemblerPolicy.BuildHistory(HistoryRequest request)
   at Dovetail.SDK.Bootstrap.History.HistoryAssembler.GetHistory(HistoryRequest request)
   at FubuMVC.Core.Behaviors.OneInOneOutActionInvoker`3.performInvoke()
   at FubuMVC.Core.Behaviors.BasicBehavior.Invoke()
   at FubuMVC.Core.Continuations.ContinuationHandler.InvokeNextBehavior()
   at FubuMVC.Core.Continuations.ContinuationHandler.performInvoke()
   at FubuMVC.Core.Behaviors.BasicBehavior.Invoke()
   at FubuMVC.Core.Behaviors.BasicBehavior.<.ctor>b__0()
   at FubuMVC.Core.Behaviors.BasicBehavior.Invoke()
   at FubuMVC.Core.Behaviors.BasicBehavior.<.ctor>b__0()
   at FubuMVC.Core.Behaviors.BasicBehavior.Invoke()
   at Agent.Core.Configuration.UnhandledExceptionLoggingBehavior.wrapBehaviorInLogger(Action action)
2017-11-13 19:00:05,549 [18] WARN  Dovetail.SDK.Bootstrap.History.Parser.HistoryItemParser - (null) Could not parse email log. Contents:

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions