We would like to write a service that waiting for a notifications from 3rd party software. After receiving a notification it should execute some code.
We would like to avoid using Windows Service/WCF and use IIS to host the application. I am looking for a ASP .NET 5 / MVC 6 as a possible solution. Is it possible to use AddSingleton service for that?
services.AddSingleton<IListener, Listener>();
Will the instance of the class created right away if the ApplicationPool recycled (or server restarted)? Any documentation on how AddSingleton work and what to expect?
Thank you!