(From IEEE Software)
Bookshelf
Understanding .NET
Chris Mylonas
Essential .NET Volume 1: The Common Language Runtime
Don Box with Chris Sells
Addison-Wesley
2002
ISBN 0-201-73411-7
400 pp., US$49.99
Some people say that .NET is a clone of Java; others argue that it’s just marketing hype. Yet others claim that it’s the “next big thing” or a silver bullet. I prefer to think that Microsoft simply followed the market trend for better systems. They integrated Win32 technologies with cryptic C-style function APIs into a single framework with a common type system and a fresh programming language set. The Common Language Runtime is the glue that joins all these items together in a complete execution and development platform.
Essential .NET Volume 1: The Common Language Runtime describes the CLR and .NET architecture in-depth. It’s primarily for people interested in writing efficient, proper programs that follow CLR design principles and methods.
Don Box, an architect of Microsoft technologies including .NET, Component Object Model (COM), and SOAP, and Chris Sells, a content strategist, write about CLR internals in their own programmer-friendly language. Box and Sells describe the .NET platform’s origins and the problems with previous component technologies before clarifying the CLR designers’ basic design decisions.
They provide a solid understanding of CLR patterns:
- Chapters 1 and 2 define modules, assemblies, and the CLR loader. They plainly describe the CLR versioning scheme.
- Chapters 3 to 5 describe types and their initialization, metadata, and instances.
- Chapters 6 and 7 explain in full detail the synchronous and asynchronous method invocation models, proxies, and aspects and how to implement custom attributes.
- Chapter 8 uncovers AppDomains, specifically their relationship with Assembly Resolver. It demonstrates how to set up the code management policy to optimize JIT compiler. A special section explains CLR soft threads and their relationship with OS threads.
- Chapters 9 and 10 explain the .NET secured execution environment and how to use the CLR as a COM component.
The text is easy to read, and the topics flow smoothly. Illustrations and tables supplement the text and provide a clear view of the information. Box and Sells expose many undocumented CLR features, such as object header layouts and thread timeouts, which help explain descriptions. However, readers will better understand the examples if they already know how to program with C or C++ or have a COM background.
Box and Sells don’t offer references or a bibliography to guide further research, which I found annoying. However, reading Essential .NET along with Applied .NET Programming by Jeffrey Richter (Microsoft Press, 2002) is your best source of information about .NET and CLR internals.
If you want to build elegant, correct, and optimized applications for .NET, you should definitely read Essential .NET Volume 1.
Chris Mylonas is a senior software engineer at Scan Group. Contact him at chris.mylonas@computer.org; http://chrismylonas.blogspot.com.