I've been maintaining an API on 4.3 for quite some time now. Due to a sudden influx of users, the site has been experiencing IDbContext disposed errors.
System.ObjectDisposedException: IDataContext is disposed, see https://github.com/linq2db/linq2db/wiki/Managing-data-connection
Object name: 'DataConnection'.
It usually happens when calls are done in quick succession or at the same time. I was able to get around this by applying a 10-50ms delay before firing the next request, but this isn't effective anymore.
I've read from another topic not to rely on the DI and use the EngineContext resolver instead, but this will require a bit of refactoring, which we do not have the resources for.
Is there another way to solve this?