Archive for the ‘Reviews’ Category

Book review – Debug It!: Find, Repair, and Prevent Bugs in Your Code

Saturday, August 29th, 2009

41wUoTodBVL._SL160_[1]

I bought Release it! some time ago, and it was a really good book. Now Prag­matic Pro­gram­mer released a new book in their ‘do it!’ series – Debug it!, so when I got a change to snap a copy, I did, and I’m here to let you know that it is a remark­able book.

First of all, I think the title might be a lit­tle mis­lead­ing for some peo­ple. It is about debug­ging in a broader sense than most peo­ple define it. If for you debug­ging equates deal­ing with debug­ger, you won’t find much of that in this book. The book talks about debug­ging as in get­ting the bugs out of your soft­ware (and doing your best to make sure they won’t come back).

The book is divided into three parts:

The first part, which accounts for almost half of the book, talks in great detail about four stages of deal­ing with bugs in your code – repro­duc­tion, diag­nos­tics, actual fix and reflect­ing over rea­sons why the bug was there in the first place. There is not much earth shat­ter­ing here, and when read­ing this part you’ll (hope­fully) think to your­self – “yeah, I knew this” and “sure, it makes per­fect sense”. The fact that this all com­mon sense, and rules of thumb are gath­ered in one place though, and backed up by con­crete dis­cus­sion and good anec­dotes helps you orga­nize your work­flow when deal­ing with mis­be­hav­ing code. The fact that what you felt under your skin is said out loud makes you stop and real­ize there’s deeper mean­ing to all this.

Sec­ond part is rel­a­tively small, but con­cen­trates on very impor­tant topic – work­ing with peo­ple. That includes both, work­ing with QA depart­ment and users as well as work­ing with bug track­ing sys­tems. It dis­cusses what makes a good bug report, what it should con­tain, what it should not con­tain etc. This part was a rev­e­la­tion, and if I could I would make it manda­tory to read for all my clients, and peo­ple sub­mit­ting bugs to OSS projects I con­tribute to. Then it moves to prag­matic approach towards work­ing with bugs (hey, it’s a Prag­matic Book­shelf book after all). It talks about per­fec­tion­ist atti­tude of bug-free soft­ware, and work­ing with soft­ware that is rid­dled with bugs, which was inter­est­ing to read in the con­text of Tim’s post.

The final part, is a loosely con­nected group of top­ics, though it is as valu­able as the pre­vi­ous ones. It talks about spe­cial cases, like ser­vice releases, about build­ing the ideal debug­ging envi­ron­ment, which I found par­tic­u­larly inter­est­ing as this is topic close to my heart, although I would dis­agree with the author, who dis­cour­ages exten­sive use of branch­ing is source con­trol. We also get a chap­ter on how to make soft­ware easy to debug. The book ends with list of anti-patterns along with dis­cus­sion about how to rem­edy them.

I know that this book influ­enced the way I work now, and there aren’t many books I could say some­thing like this about. It dis­cusses extremely impor­tant part of soft­ware engineer’s pro­fes­sion, and does it very well. If you call your­self a prag­matic pro­gram­mer I think you should read this book.

Tech­no­rati Tags: ,

Book review — C# in Depth, 2nd edition

Friday, August 28th, 2009

Note, that this is a review of very early MEAP release – this is not com­plete book, and I review only 2 chap­ters that are avail­able at the time of this writing.

skeet2_cover150[1]

If you are at least a casual user of Stack­Over­flow you know who Jon Skeet is. Jon has a hard earned rep­u­ta­tion of being an expert in just about any­thing he touches, so it came as no sur­prise that first edi­tion of his C# in Depth book was uni­ver­sally praised for its high quality.

Fast for­ward almost 2 years later, we’re await­ing new ver­sion of .NET frame­work, along with its tools (Visual Stu­dio) and what’s more impor­tant – new ver­sion of C# lan­guage. So while some of us are cheer­ing for the new fea­tures and sce­nar­ios that new improve­ments enable we’re all faced with a task of upgrad­ing our knowl­edge with this infor­ma­tion. Here’s where Jon comes to the res­cue with sec­ond edi­tion of the book.

So far two chap­ters are avail­able, both cov­er­ing new addi­tions to C# 4.0. “Minor changes to sim­plify code” talks about optional para­me­ters, named argu­ments, COM improve­ments and generic vari­ance. “Dynamic bind­ing in a sta­tic lan­guage” is all about the dynamic key­word and all the things around it. The whole book how­ever is going to talk about improve­ments intro­duced in ear­lier ver­sions as well, and how they fit together in the grand scheme of things.

This is a lan­guage book, and lan­guage books tend to be either focused on a new­comer to the lan­guage, or try to sat­isfy both new­com­ers as well as peo­ple with expe­ri­ence which results in tomes of mon­strous sizes. If you’re con­cerned that this is the case with this book – rest assured. This book is “lean and mean” — it does not waste your time explain­ing basic prin­ci­ples that would make you yawn or skip pages. It’s also very focused and con­cen­trated on get­ting you up to speed with new fea­tures. It is really very well bal­anced in that it spends just enough time for you to grasp the fea­ture, and then move on to the next one.  The only place where I felt lost was generic vari­ance and higher order func­tions, but this is very con­vo­luted stuff, so it’s not a down­side by any means.

The book not only describes fea­tures from a bystander’s per­spec­tive, but is full of opin­ions and tips about them, which is arguably the best aspect of this book, and some­thing that dif­fer­en­ti­ate it from MSDN doc­u­men­ta­tion or lan­guage specification.

That’s the great value of this book – it’s incred­i­bly well writ­ten, and after you’ve read it, you feel like you not only know what the new fea­tures are – you also feel like you know how to put them into good use, how they work under the cover, what are their lim­i­ta­tions, and how you might go about over­com­ing few of them. If you’re look­ing for a quick way of get­ting up to speed with C#’s fast progress, search no more – this is the book for you. Highly recommended.

Tech­no­rati Tags: ,,,,