axafrance / extensions-dependency-injection Goto Github PK
View Code? Open in Web Editor NEWMicrosoft Extensions DependencyInjection for WCF, and asp.net classic projects
License: MIT License
Microsoft Extensions DependencyInjection for WCF, and asp.net classic projects
License: MIT License
I made a disposable service and AddSingleton().
Then I stopped the IIS Server, but the Dispose() method hasn't been called.
public class TestService : IDisposable {
public TestService(){
Debug.WriteLine("The service has been created.");
}
public void Dispose() {
Debug.WriteLine("The service has been disposed.");
}
}
services.AddSingleton<TestService>();
pubic HomeController(TestService test) {
}
In Debug console:
The service has been created.
The service has been disposed.
In Debug console:
The service has been created.
In Global.asax.cs add some code to dispose the provider.
private IDisposable _provider;
public void Application_Start(){
// creating and setting a service provider...
_provider = provider;
}
public void Application_End(){
_provider?.Dispose();
}
Is it a correct solution?
Software | Version |
---|---|
<PROJECT_NAME> |
|
<BUILD_TOOL> |
Visual Studio 2019 |
Operating System | Windows 10 |
It would be awesome
Thanks for this awesome library :)
Please don't forget date into the Licence which is important for legal.
sample :
Copyright (c) 2019 Axa France IARD / Axa France VIE
ps: I won't do the PR because I want you to learn :p
Relates to #19
There are currently 2 WCF samples, net452 and net461. They both share the same files.
https://github.com/AxaGuilDEv/extensions-dependency-injection/tree/master/samples
Having a simpler sample structure.
Keep only one of them ?
It would be great to have a consistent coding style across the codebase.
Use an .editorconfig file
The WebApi.Sample uses both WebApi and MVC packages.
Have a sample for MVC, and a sample for WebApi.
This is confusing when looking at the samples to figure out how to use the MVC package
The license is currently Axa France
. It is not a valid legal entity. It should be Axa France IARD / Axa France VIE
The license should be Axa France IARD / Axa France VIE
The license is Axa France
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.