EpicorRESTAPICore RequestLog MultiThreading

I am using EpicorRESTAPICore and I noticed that the RequestLog is a List object.

I am unable to set MaxRequestLogLength = 0 to not log (preferred as I don’t need this log)

I get this error when setting the MaxRequestLogLength < 1 and making a REST call, or when more than one request (multithreaded) comes back at the same time and tries to write to the log.

Any way to change the RequestLog to a ConcurrentBag or something multithread safe or turn off logging?

Index was out of range. Must be non-negative and less than the size of the collection. (Parameter ‘index’)

Stack Trace:
at System.Collections.Generic.List1.RemoveAt(Int32 index) at EpicorRestAPI.EpicorRest.RequestLogAdd() at EpicorRestAPI.EpicorRest.HttpJsonAsync(Method iMethodType, String iBaseMethodURl, String iFormattedParams, Object iJsonData, CallContextHeader iCallContext, Dictionary2 requestHeaders)

What version of the library are you using?

This is fixed in V 3.0.2

1 Like