The session started out to answer three questions:
- How to install the .NET Framework
- How do I share libraries or components
- How do I make my app start faster
Basically we were shown how to tell VS installer project to install the .NET framework. This can be either downloaded from the web or included as part of the installation. The only new thing that was mentioned is the '.NET Framework Client Profile'. To quote MS:
'The .NET Framework Client Profile is a subset of the full .NET Framework 3.5 SP1 that targets client applications. It provides a streamlined subset of Windows Presentation Foundation (WPF), Windows Forms, Windows Communication Foundation (WCF), and ClickOnce features. This enables rapid deployment scenarios for WPF, Windows Forms, WCF, and console applications that target the .NET Framework Client Profile. '
Sharing .NET Assemblies
The issues that were covered here were: how to share a /NET assembly and how to version it. Basically, we install them to the GAC. However, nothing was said about multiple applications installing uninstalling same file and if this is handled by the method he showed us using VS.NET. With respect to versioning, when a new version is to be built, the question to ask is what is the new version for? Is it to add new features or to fix existing features? In the first case, the strong name of the assembly must be changed - so changing the version number will do this. This way, an old version and a new version of the same assembly can be installed side by side in the GAC. If it is to fix something, when two options are possible. The first is not to change the version, in which case the new version will replace the old one. If however the new change is a breaking change, this is not a good idea. The next option is to change the version number. However, in this case, applications using the old version will have to be configured using the 'Publisher Policy' to use the newest assembly.
Performance
Traditionally, we were told, strong named assemblies may have been installed to the GAC in order to speed up their loading time because the strong name of assemblies in the GAC is only verified at install time. However, .NET 3.5 SP1 has a new feature called 'strong name bypass'.
Finally we were shown a tool called that has been in the framework for a while that I was not aware of called NGen. This recompiles IL into native code so that assemblies load faster. This must be done when installing assemblies, and must be re-done every time an assembly is updated. We were also told that in .NET 3.5 SP1 there has been a lot of work done on cold start-up time, and this has been reduced by up to 20%
No comments:
Post a Comment