Cover image for The build master : Microsoft's software configuration management best practices
Title:
The build master : Microsoft's software configuration management best practices
Personal Author:
Series:
The Addison-Wesley Microsoft technology series
Publication Information:
Upper Saddle River, NJ : Addison-Wesley, 2006
ISBN:
9780321332059

Available:*

Library
Item Barcode
Call Number
Material Type
Item Category 1
Status
Searching...
30000010134482 QA76.76.C69 M37 2006 Open Access Book Book
Searching...

On Order

Summary

Summary

Stephen Zeff has been a prolific researcher on the history of accounting and auditing in the twentieth century. He has written numerous papers on the history of standard setting and regulation, of accounting and auditing practice, of the accounting profession, of accounting thought, and of the intellectual contributions of major authors (such as Hatfield, Canning, Paton and MacNeal).This volume brings together the greatest hits of Zeff's academic career, including several articles that were published in out-of-the way places, for easier use by students and researchers of the field. In an introduction, Zeff discusses the evolution of his research interests and explains the factors led to the writing of the papers and their intended contribution to the literature. The book also includes a complete list of his publications.


Author Notes

Vincent Maraia has fifteen years' experience at Microsoft, and has helped ship products ranging from Windows NT and Visual Studio to the Microsoft Mouse. For six years, he has been an Application Development Consultant in Microsoft's Premier Services group, helping customers architect and implement effective source code, build, and test processes.


© Copyright Pearson Education. All rights reserved.


Excerpts

Excerpts

During my 15 years at Microsoft, I have spent 10 years working in various product groups shipping 11 products, including Windows NT, Visual Studio, BackOffice, Small Business Server, and the Microsoft Mouse. I have also been on a couple of canceled projects that never made it out the door. For the past 5 years, I have been consulting on Microsoft's best source code control (SCC), build, test, and deployment processes, with an emphasis on the build process. It seems that for all the years that I have been working at Microsoft, I have always been in some kind of Software Configuration Management (SCM) role working in the build lab, writing and running tests, creating setup programs, or coordinating project meetings. This book contains the knowledge I have gained while working on these various projects. Furthermore, I have built on the experiences of the people who were there before me and the lessons they taught me. I also gathered a lot of tips from people who are currently in the product team. Many things can and have been said about Microsoft, but there is one thing most people will agree on: Microsoft has been one of the more successful companies when it comes to shipping software. Sure, we might be notorious for missing our ship date, but despite this fact, Microsoft cranks out hundreds of released software products per year--thousands if you include hotfixes via Windows Update. That is why we have all the processes mentioned in this book: to minimize the slippage and optimize the development process. I tried to capture the best new and classic processes that we have developed throughout the years so that I could pass them on to you in The Build Master: Microsoft's Software Configuration Management Best Practices . What This Book Is About As I search Microsoft's job database, looking through 397 job titles, none of them contains the words Software Configuration Management . When I look at our acronym or glossary lookup tool and search for SCM, the results come back with Source Code Manager or Supply Chain Management , pronounced SCuM . It is no wonder that the SCM term is used infrequently at Microsoft. I know that I would not like to be referred to as a SCuM manager or champion. Of course, I am being facetious and picky about the semantics here because SCM is a widely used industry term. It just isn't used a lot at Microsoft. The only explanation I can think of is that the processes of SCM at Microsoft are broken down to specific tasks, and SCM is too broad a term to be used to describe these processes on a daily basis. So, despite the lack of the use of the term SCM at Microsoft, that is what this book is focused on since that is what we live and breathe every day. Defining Software Configuration Management Let's define SCM as it is used in this book. I like this definition of configuration management that Steve McConnell gives in his 1993 book, Code Complete , from Microsoft Press: Configuration management is the practice of handling changes systematically so that a system can maintain its integrity over time. Another name for it is change control. It includes techniques for evaluating proposed changes, tracking changes, and keeping copies of the system as it existed at various points in time. A more detailed description might be from Stephen A. MacKay. He quotes several sources, but they all seem to be saying the same thing: The most widely used definition of software configuration management (SCM) comes from the standards community IEEE87, IEEE90a, IEEE90b, Buck93. Configuration management (CM) is a discipline that oversees the entire life cycle of a software product or family of related products. Specifically, CM requires identification of the components to be controlled (configuration items) and the structure of the product, control over changes to the items (including documentation), accurate and complete record keeping , and a mechanism to audit or verify any actions. This definition is not complete. Dart Dart92 suggests that the definition should be broadened to include manufacturing issues (optimally managing the construction of the product), process management (ensuring adherence to the defined processes), and team work (supporting and controlling the efforts of multiple developers). Tichy Tich88 provides a definition that is popular in the academic and research communities: Software configuration management is a discipline whose goal is to control changes to large software system families, through the functions of component identification, change tracking, version selection and baselining, software manufacture, and managing simultaneous updates (teamwork). In short, at Microsoft, SCM is broken into three groups: source control, build, and deployment or release. There could arguably be a fourth group, sustained engineering--hotfixes and service packs--but this separate distinction seems to show up only on the big teams such as Windows. The jobs at Microsoft that have the responsibilities described previously are builder, build management, or release program manager. The really abbreviated term for SCM at Microsoft is builds. This is probably because when code is taken from developers and turned into a product that you can deliver to a customer, it is usually the build team that owns all the steps involved or helps manage the process. Having a good build process seems to be a lost art even in some groups at Microsoft. For example, when I recently spoke with one development team, I heard them talk about trying a distributed build system over a group of build machines (also known as build farms). This idea was tried several years ago--and tried a few times since the original--but has proven to be unsuccessful for various reasons that are covered in Chapter 5, "Build Tools and Technologies." Maybe there have been recent improvements in tools, or the product has been broken into smaller packages of code (componentized) that will make this distributed build process more likely to succeed today than it did years ago. If so, this might justify revisiting the idea even though it was abandoned the last time someone looked at it. But if no changes have been made that would support moving to a distributed build process, trying to pursue this Holy Grail would be a waste of everyone's clock cycles. It is impossible to talk about software builds without also addressing some of the surrounding software development areas around this process, such as source tree configuration and the deployment of a product. Therefore, I want to give the full story of setting up your development source trees, building your code, deploying your product, and supporting your customers with fixes by using examples of how we do it at Microsoft. Who Should Read This Book The target audience for this book is SCM teams at any company that ships software internally or externally. This includes the people outlined in the next sections. Information Technology (IT) Managers If you develop or deploy software to departments within your company or manage the servers that host your developer's source code trees, this book will help you succeed in being more efficient and robust. Software Development and Testing Managers Because you are the one who implements and uses these processes, it would be best to read the explanations behind the processes firsthand. This will help you drive the adoption of these processes within your group or company. Build Teams and Build Managers Being a builder at heart and spending many years in build labs, I wrote this book as a collection of what I have learned. When software is shipped, everyone seems to have specific tasks or jobs: Developers write the code, testers test the code, program or product managers try to figure out what goes into the product, and executives sell it. So who makes sure that the flow of the product does not get interrupted? When there is a block or showstopper, who is the person who will jump through fire hoops to get things started again? It is the build or integration team, which I see as the "heart" of the product and everything else is the "soul." Because this large responsibility falls under the build team, and the most successful groups have a very solid build team, the topics in this book will help you keep the "flow" going. Technical Project and Product Managers If you want to be able to accurately predict when your product will be ready for release and learn the details of how a requested application feature goes from cradle to grave, this book will provide an overview of the whole process. You can work with the developers and testers on how to merge these recommendations into your current process and understand the language or lingo. Anyone Interested in a Microsoft Case Study Although this book is not intended to be a case study in the traditional sense, such as presenting the steps that Microsoft uses to build software and then analyze them to death, you can view this book as an example of a successful software company and the lessons it has learned over the years, with a lot of insight into why Microsoft chose a particular path. Assumptions Made on the Background of People Reading This Book This book assumes that the reader has some experience working on or with a software development team either at a company or in an academic institution. This is not a high-level 35,000-foot view of SCM. Plenty of books out there already take that approach. I am taking a more granular approach as to how to do it rather than just telling you what you need to do. Although some examples in this book concern Microsoft tools and technologies, I have tried to write this book in a tool-agnostic way. In other words, regardless of the tools or platforms that you develop on, you will still be able to use these processes to ship your software effectively. By "ship your software," I mean any way that software can be delivered to your customers, whether via the Internet, disc media, internal server releases, Web services and applications, or out of the box. How This Book Is Organized Each chapter can stand alone, but the book flows from software development processes to product support (sustained engineering). This is my idea of componentizing the build process and this book. You will get a better understanding of how all these topics are linked if you read this book from cover to cover, but I realize that some groups or companies will not need to spend a lot of time on a certain subject that they feel they have already mastered or are not interested in. If someone just wants help on setting up a build lab, he can turn to Chapter 4, "The Build Lab and Personnel," and get the information he needs without having to read the previous chapters. Contents at a Glance Source Code Control--The "Golden" Rule Because it seems that the build team members tend to live in the source code trees and are usually the administrators of the trees, I spend a chapter talking about the best way to configure your sources. The Build Process--The Mission-Critical Assembly Line This is the cornerstone of this book. Nine chapters cover, in detail, how to build your product. For a more in-depth overview, please read the book's Introduction. Setup/Release--Ship It! This is another area that tends to spill over to the build team's responsibilities. This topic is covered in three chapters. Sustained Engineering--The Only Sure Things in Life Are Death, Taxes, and Bugs This tends to be the first area where symptoms of a failing project start to show up. Most notably, everyone on the project team is in reactive mode instead of working on new features. The Future--How to Get There from Here If you are interested in the new tools that Microsoft will be releasing with the future release of Visual Studio, I touch on how to utilize those tools using the processes described in this book. The Story As I write this, Microsoft is productizing some of its internal development-cycle tools to make them available to all developers via its Visual Studio Team System product. The production of this book could not have come at a better time because I can now explain how these tools and processes have evolved in addition to the best practices of product teams that drive the functions of these new tools. This is another objective of this book. I recently completed a build architecture review for a large Microsoft customer. This customer already had a good build process and didn't think it needed much improvement. At the end of my onsite, week-long engagement at the customer's development headquarters, I suggested that this customer adopt the principles that I explain in more detail in this book. He agreed with me on most points but surprised me when he said, "I really appreciate all the information and suggestions that you provided. In order for you to have come up with all of these recommendations, you must have suffered through a lot of pain in the past." This statement blew me away. I never really viewed all of this experience working on builds at Microsoft for the past 15 years as painful, but just lessons we learned by "try and try again until we get it right." Although some initial investment in resources will be required to reboot your processes if you decide to implement all the processes and suggestions in this book, you will save 3 to 5 years of the "pain" of learning all of this from the school of hard knocks. At the very least, you will be enlightened on how software is shipped at Microsoft. And as I always ask my customers, if you know of any other better processes than what I prescribe, please let me know. I am always open to improvement and would love to hear your suggestions. Get Stuck or Get Results. Period. The goal of this book is to get you unstuck from spinning your development cycles or to help you avoid getting stuck in the first place by providing processes and tips to help you become more productive. What do I mean by "getting stuck"? Your developers are spending less time writing new code and are in maintenance mode most of the time. The 80/20 rule usually comes up here. For example, developers should be spending 80 percent of their time writing new code and 20 percent fixing bugs, not vice versa. The morale of your team suffers. Developers and testers get increasingly frustrated with the lack of consistency and reliability of builds and being in reactive mode all the time. A lot of unnecessary finger-pointing is a bad indicator. You miss ship or release dates, and your customer satisfaction suffers. Your ability to reproduce builds and deliver hotfixes becomes increasingly difficult. You spend more time trying to reproduce a build or build a hotfix than you do fixing the code that caused the bug. You do not have a reliable process of tracking and building all the code changes in your product, and the stability of the product is unpredictable at best. At the end of the day, all these issues, which you could avoid, will end up costing your company lots of money because you will be patching or hacking whatever process you currently have that does not seem to be getting the job done. Outsourcing Nowadays, it is unlikely to have all of an application's developers physically situated at one location. If you plan to have developers work remotely either offsite or off-shore, it is mandatory that you integrate the processes explained in this book, especially the concept of the Virtual Build Labs (VBLs) explained in Chapter 2, "Source Tree Configuration for Multiple Sites and Parallel (Multi-Version) Development Work." Experience shows that if your software configuration management is good, outsourcing will be easy or easier to integrate. This book covers all the necessary steps toward making sure the intellectual property of your company is not compromised. This is done through securing your overall build process, not through fingerprinting every piece of code that is in your project. What This Book Is Not About: Software Factories Well, maybe this book has something to do with software factories because you can package everything I talk about in this book, put it in one application, add a few enterprise e-commerce development tools, and crank out your software. Then I think you have a software factory. Or at least that is how I understand the concept of software factories. Everything I read on this topic keeps pointing me to Visual Studio Team System (VSTS). I give an overview of the VSTS tools in Chapter 18, "Future Build Tools from Microsoft," but nothing more. Maybe in another edition of this book, I will talk about how you can use the processes in this book in conjunction with VSTS. Updates and Contact Information For updates, visit my blog at http://blogs.msdn.com/vincem/ . That's also the best way to contact me. Or you can contact me at dvader@microsoft.com or http://www.thebuildmaster.com . For more information on how Microsoft can help provide custom solutions to any software issue, please look at the Microsoft Partner Advantage site at http://www.microsoft.com/services/microsoftservices/default.mspx . For other books from Addison-Wesley, go to http://www.awprofessional.com . (c) Copyright Pearson Education. All rights reserved. Excerpted from The Build Master: Microsoft's Software Configuration Management Best Practices by Vincent Maraia All rights reserved by the original copyright owners. Excerpts are provided for display purposes only and may not be reproduced, reprinted or distributed without the written permission of the publisher.

Table of Contents

Forewordp. xv
Prefacep. xvii
Chapter 1 Defining a Buildp. 1
The Two Types of Builds: Developers and Projectp. 1
Building from the Inside Outp. 3
More Important Build Definitionsp. 4
How Your Product Should Flowp. 8
Microsoft Solution Frameworkp. 15
Summaryp. 16
Recommendationsp. 16
Chapter 2 Source Tree Configuration for Multiple Sites and Parallel (Multi-Version) Development Workp. 17
Definitionsp. 18
How This Process Works: An Example Using VSSp. 21
Hatteras: A Look Into the Future of SCC at Microsoftp. 24
Summaryp. 33
Recommendationsp. 33
Chapter 3 Daily, Not Nightly, Buildsp. 35
The Importance of a Successful Daily Buildp. 38
What Are You Building Every Day?p. 41
Summaryp. 41
Recommendationsp. 42
Chapter 4 The Build Lab and Personnelp. 43
The Need for a Build Labp. 45
Build Lab Rulesp. 46
Hardware Configurationp. 47
Build Personnelp. 51
Summaryp. 53
Recommendationsp. 53
Chapter 5 Build Tools and Technologiesp. 55
First, Every Build Needs a Scriptp. 57
Binary Generating Tools-Also Referred to Loosely as "Build Tools"p. 57
"You Provide the Nose; We Provide the Grindstone"p. 59
In Steps the 800-Pound Gorilla!p. 60
XML Is the Here, the Now, and the Futurep. 62
What Build Tool Should You Be Using and When?p. 62
Summaryp. 64
Recommendationsp. 64
Chapter 6 SNAP Builds-aka Integration Buildsp. 65
What Is a SNAP Build?p. 66
When to Use SNAP Buildsp. 67
How SNAP Worksp. 67
Sample Machine Configurationp. 68
Operations Staffp. 71
Managing Throughputp. 71
Summaryp. 73
Recommendationsp. 74
Chapter 7 The Build Environmentp. 75
Setting Up the Environmentp. 76
Setting Up a Developer or Tester Machinep. 77
A Makefile Example That Explains How This Worksp. 83
Summaryp. 85
Recommendationsp. 86
Chapter 8 Versioningp. 87
Why Worry About Versioning?p. 87
File Versioningp. 88
Build Numberp. 90
Source Code Control Treesp. 91
Should There Be Other Fields in the File Version Number?p. 92
DLL or Executable Versions for .NET (Assembly Versions)p. 93
How Versioning Affects Setupp. 95
Even Installing Correctly Does Not Always Workp. 98
Summaryp. 99
Recommendationsp. 99
Chapter 9 Build Securityp. 101
Physical Security for the Build, Source, and Release Labp. 103
Tracking Source Changes (All Check-Ins)-The Build Processp. 105
Binary/Release Bits Assurancep. 106
IT Infrastructurep. 106
Want More Security?p. 108
Summaryp. 109
Recommendationsp. 109
Chapter 10 Building Managed Codep. 111
The Official Definition of Managed Codep. 111
What Is the CLR, and How Does It Relate to Managed Code?p. 113
Managed Execution Processp. 114
The Definition of Assemblies As It Pertains to the .NET Frameworkp. 116
Delay Signing and When to Use Itp. 116
One Solution or Many Solution Files?p. 119
Summaryp. 120
Recommendationsp. 121
Chapter 11 International Buildsp. 123
Important Concepts and Definitionsp. 124
Method 1 Internationally Ignorant Codep. 126
Method 2 Locale-Dependent Sourcep. 127
Method 3 Single Worldwide Sourcep. 128
Method 4 Single Worldwide Binaryp. 129
USE Unicodep. 131
Summaryp. 132
Recommendationsp. 132
Chapter 12 Build Verification Tests and Smoke Testsp. 133
Smoke Testp. 135
Build Verification Testsp. 137
Summaryp. 143
Recommendationsp. 144
Chapter 13 Building Setupp. 145
The Basic Definitionsp. 147
Setup Is Not a Testing Toolp. 148
Summaryp. 153
Recommendationsp. 153
Chapter 14 Ship It!p. 155
Software Release at Microsoftp. 160
Summaryp. 162
Recommendationsp. 162
Chapter 15 Customer Service and Supportp. 163
Goals of Supportp. 165
How Support Works and Communicates with the Product Teamsp. 166
Summaryp. 168
Recommendationsp. 169
Chapter 16 Managing Hotfixes and Service Packsp. 171
Introduction to "Release Management with VSS"p. 172
Release Management: General Scenariosp. 174
Summaryp. 180
Recommendationsp. 181
Chapter 17 7 Suggestions to Change Your Corporate or Group Culturep. 183
What Is Corporate Culture?p. 186
It Starts at the Topp. 187
When All Else Failsp. 197
Don't Go Gipperp. 198
NASA Columbia and Challenger Disasters: When Management Pulls Rank and There Is a Big Disconnect Between the Manager's View and the Engineer's Viewp. 199
Summaryp. 201
Recommendationsp. 201
Chapter 18 Future Build Tools from Microsoftp. 203
MSBuildp. 204
Visual Studio Team Systemp. 206
Visual Studio Team Buildp. 209
The Microsoft Shell (MSH, or Monad)p. 211
Summaryp. 213
Recommendationsp. 214
Appendix A Embedded Buildsp. 215
Nuts and Bolts of the CE Build Systemp. 216
Appendix B Extreme Programmingp. 219
Extreme Programming Fundamentalsp. 219
Test-Driven Development and Refactoringp. 222
An Extreme Programming Scenariop. 224
Microsoft Case Studyp. 225
References and Further Readingp. 227
Appendix C Testing Guidep. 229
Test Guide: A Compilation from the Developer Division at Microsoftp. 229
Appendix D Debug Symbolsp. 237
The Windows Scenario That You May Run into with Your Applicationsp. 238
Final Thoughtsp. 241
Indexp. 243