Open RustyF opened 4 years ago
Btw, I'm using 4.x preview. Gonna switch to 3.x for now.
The only solution I can think of is using your own mediator to wrap the async code synchronously. This is all the sync versions in 3.x
do, and looks like it's been written about here: https://greatrexpectations.com/2016/04/22/autofac-and-async-resources ??
Regarding the removal of all sync methods, Autofac configuration is synchronous and thus means we can't do this anymore:-
builder .Register<NeoServerConfiguration>(context => NeoServerConfiguration.GetConfiguration(uri, user, pwd)) .SingleInstance();
Is there an obvious workaround I've missed?