Populating over 30 assemblies, 16,600 types and 162,000 methods from .NET Framework 2.0 assemblies into your repository !![Prep time]: 5 minutes [Ingredients]: Oslo SDK, CLR instances (.NET 2.0), SQL Server Reporting Services
Another interesting application that we have developed on top of “Oslo” Repository is ‘BuildLoader’.
BuildLoader is the application which has been developed for the purpose of facilitating the process of analyzing the metadata within and across assemblies. It shreds the metadata in an assembly and then loads them into a repository.
Currently, in our team, we are using BuildLoader to shred some main assemblies that are produced from the nightly build process. For each build, we shred the test assemblies and product assemblies into different folders in our repository. This is so that we can perform the analysis across between the test and product assemblies easier.
BuildLoader consists of the 3 main components – CLR Schema, CLR Loader and CLR Reports.
BuildLoader has brought a number of benefits into our team. Having BuildLoader shredding and loading real data into a repository has helped us find and fix problems that customers will face. It also helped us discover holes in our documentation and guidance. Moreover, the test and product assembly metadata available allows us to perform the analysis such as the build content comparison. The called method statistics available from CLR Loader can be used to determine the areas in the product code that are still lack of testing. We use CLR Reports to get an overview of the build and the items within each assembly. For example, the CalledMethodStatisticsReport can provide us a rough estimation of the dependencies on the selected type in the selected assembly. This information is useful when there’s a need to re-design/ or refactor a component. The MethodReport and CSharpTypeReport are also particularly useful for debugging purpose. Using these two reports, a user can drill down to the method that is at the beginning and the end of a chain.
To get a similar experience to BuildLoader, install Oslo SDK and then install CLR instances (.NET 2.0) on top of “Oslo” Repository (comes with Oslo SDK). Then take a look at the CLR Reports under C:\Program Files\Microsoft Oslo SDK 1.0\Samples\Reports\. To give you some idea, this will populate over 30 assemblies, 16,600 types and 162,000 methods into your repository. This should be enough to keep you busy for a while :) Note that CLR schema is already comes with the default installation of an “Oslo” Repository.