Archive for September, 2011

Book Review: Apprenticeship Patterns

I don’t know how I missed not posting a review of Apprenticsehip Patterns: Guidance for the Aspiring Software Craftsman by Dave H. Hoover and Adewale Oshineye (OReilly, 2010), but somehow I did. I read this book quite some time ago so this review will somewhat limited as the material is not fresh in my mind.

The book says it is targeted to the aspiring software craftsman, but I found it the book full of wisdom and good ideas for the most seasoned developer. The book uses the Manifesto for Software Craftsmanship as a basis on what skills you should develop and how you go about gaining those skills. The book is short, only about 140 pages and an easy read, but don’t think it’s something you can just breeze through. Along the way you will take many retrospectives of your own career, see new things you should be doing, and be reminded of concepts you had either forgotten or ignored.

Chapter One gives an overview of Software Craftsmanship. One paragraph lays out the theme for the book:

One of the lessons we’ve learned from the Agile development movement is that just telling people to do things doesn’t create lasting or sustainable change. When people you’ve advised encounter a situation that isn’t covered by the rules, they’re lost. However, if those same people have imbibed the values that underpin the rules, they can come up with new rules to fit any situation. Our goal here is not simply to hand people a rule book, but to give them the ability to create new practices for new contexts, which in turn drives the discipline of software development forward.

The authors then layout a path to move the reader from apprentice to journeyman to master and define an Apprenticeship Pattern as a pattern that “attempts to offer guidance to someone working with the craft model on the ways in which they can improve the progress of their career.”

The remainder of the book is laid out as patterns you can follow to grow and improve as a developer.

Chapter Two, Emptying the Cup, discusses learning your first language and how to move on to learn the second, third, and more. For example, you may have to unlearn something. If one language implements a specific construct one way, you may have to unlearn that and adopt a new way of doing something. Another pattern is Expose You Ignorance. You many be unfamiliar with the technology you are required to use. The solution is to show that you can learn it. Don’t be afraid to let people see you struggle, but showing that you can learn and overcome is important.

In Chapter Three, Walking the Long Road, the authors explain that you are responsible for your career, not your employer, your friends, or your family. You need to plan your own path and then provide the nurturing and sustain your own motivations. Sometimes you will end up in jobs that don’t seem to be taking you on the path you wanted. You then need to Stay in the Trenches and continue or take A Different Road.

The next set of patterns come in Chapter Four, Accurate Self-Assessment. This, to me, is the hardest part of the book to do. People, in general, tend to be hard on themselves and often cannot accurately give a self assessment. Sometimes you’ll find yourself the best developer on your team so to continue growing you need to Be the Worst. Take a new job where you are at the bottom of the group. You may need to find Mentors or Rub Elbows with others to learn new things and grow your network of knowledgeable Kindred Spirits to help you grow..

Perpetual Learning is the next set of patterns. When you want to learn something new, Practice, Practice, Practice. Create a Breakable Toy, some pet project that you can recreate in a new language as a way to learn. Record What You Learn and just as important, Share What You Learn and Learn How You Fail.

Now that you know what you need to do, it’s time to put the plan into action. Chapter Six is Construct Your Curriculum. Create a Reading List and Read Constantly. And just because you’re learning new languages and concepts doesn’t mean that you should give up the Familiar Tools. They often propel you to learn new techniques more quickly because you don’t struggle with the language, which allows you to concentrate on the new stuff.

So, that brings up the conclusion of the book. You then find out how to tell if you are a Master. Oh, I’m not going to give that away. You need to read the book yourself. I will say, go buy the book. Or, read it online for free. Then apply the concepts presented and you will become a better developer.


Converting code, is it a good idea?

I often see forum questions from people asking about converting code from one language to another. It’s often FoxPro to C#, FoxPro to VB, FoxPro to Java, or VB to C#. I don’t recommend converting from one language to another, especially when they are so different from each other, such as the FoxPro conversions.

Earlier this year, I had an assignment to convert C++ code to C#. Because the C++ routine was new and still under development by another team member, I decided to keep everything as close to the same as possible as I thought it would make C# changes easier when the C++ code changed. The program I had to convert took text in one proprietary format and converted it to another. The C++ code used lots of substring manipulations of each line.

But there are subtle problems that cause issues later. For example, while C# is zero-based, C++ claims to be, but isn’t fully zero based. When dealing with substrings, C# starts counting character at zero, while C++ starts at one. You can’t simply subtract one each time because you have to consider other factors such as length of the string, length of the substring, etc.

Well, the “off-by-one” errors have come back to bite me several times. I spent about four hours yesterday to fix one of these issues. I needed to verify that the incoming data was the correct format, what the C++ routine was doing at that point, what the possible side effects would be as a result of the change, compile, unit test, then integrate test the routine. This was four hours that I couldn’t spend on another, high priority project. And this was after the dev on the other team spent over a day trying to figure out where the error was happening.

The end result is that I have decided that I will never again simply convert. It’s always a better idea to understand the original code and rewrite in the second language. This will also allow you to take advantage of any constructs in the second language that don’t exist in the first.


Installing Windows 8

This past week, Microsoft unveiled Windows 8 at the Build Windows conference. I was not able to attend so I did not get one of the Samsung tablets that attendees received. However, Microsoft made the Windows 8 Developer Preview available to anyone. This a “pre-beta” version, so I would expect lots of things to not be working. But, the chance to start to learn about new features such as the Metro UI and WinRT are too important to miss. I took two approaches to installing Win8 so I can start the learning process.

The first was to install Win8 on my primary development laptop, a Dell Inspiron 15 with 8 Gig RAM, a Quad-Core processor, and 650 Gig hard drive running Windows 7 Ultimate.. I downloaded the 64 bit version that includes the Visual Studio 11 Express preview. My intent was to run this on a virtual machine. I figured I have enough horsepower on this laptop. But, after reading Scott Hanselman’s post Guide to Installing and Booting Windows 8 Developer Preview off a VHD (Virtual Hard Disk), I thought he described a better option. I created the VHD and made a bootable USB drive following Scott’s instructions. All went well. Win8 looks great on the laptop and the performance is very acceptable. But, as one of Win8′s big features is touch throughout, I couldn’t test this. The laptop is not touch enabled.

Step 2 was to get a laptop or tablet with touch capability. I did a little research, comparing features and price, and settled on a Dell Duo. This is a nifty device that is really a netbook that converts to a tablet by swiveling the screen. It has a 1.6 GHz Atom processor, a 360 Gig hard drive, and 2 Gig RAM running Windows Home Premium. Most importantly, it has touch capabilities. So, I ordered one from Dell and scheduled next day shipping. The plan was to setup the Duo the same way I had seutp my Inspiron. The Duo arrived on schedule, but things went downhill from there. I had problems logging on after initial setup. I spent several hours on the phone with Dell customer non-support and was transfered mulitple times. In all, I talked to 19 people at Dell before I found someone who arranged for a return and refund. But, because I would have the PC over the weekend, I figured I could have a couple of days to hack at the machine and get it usable. I started poking around the Interwebs for ideas on how to logon. I finally stumbled upon a method of booting to one of the safe modes, running NET command that activates the default Administrator ID, thus allowing you to logon. A little luck and some good search results got me logged in and going.

But, the good news was short lived. The Dell Duo does not support boot from USB. And without a DVD drive, I couldn’t boot to Win8 setup. “No problem”, I thought, “I’ll just run Setup and have it install to a different partition”. I created a vhd as I had done the day before and also a logical parition on the drive. But, running Setup in the manner only allowed an upgrade. I could not find a way to force the Win8 install to go to a different partition. I again posted some questions on the Interwebs, got a few ideas, but nothing worked. I finally decided to go ahead and upgrade Win7 to Win8, knowing this could lead to problems later when the Win8 beta is released. I’ll deal with that issue when it comes along.

Performance seems very acceptable for the processor speed and amount of RAM. The screen is beautiful and bright when on AC, but is dimmed all the way down on battery power and Win8 does not allow the brightness to be increased when on battery power. The touch interface is snappy and responsive. The Win7 driver for the accelerometer does not work on Win8, but I expected some of this. I haven’t tested can built-in web cam yet. But, as my goal was to have a touch device to test Win8 and my own apps, the Dell Duo should fit the bill.


Podcasts I listen to

Yesterday in my Software Gardening presentation at Utah Code Camp, I talked about things you can do to make you a better programmer and improve your knowledge and skills. One of those things is listening to podcasts. One attendee asked what podcasts I listen to. I couldn’t make a complete list at the time, and I commited to blog a list of them. So, here are the podcasts I currently have on my MP3 player:

  • .NET Rocks
  • Agile Toolkit
  • CodeCast
  • Community Megaphone Podcast
  • Deep Fried Bytes
  • Get-it Done Guy
  • Hanselminutes
  • Herding Code
  • Manager Tools
  • Mondays: What Sunday Threw Up
  • Polymorphic Podcast
  • Rookie Designer
  • RunAs Radio
  • Software Process and Measurement (SPAM) Cast
  • Spaghetti Code
  • The Digitial Marketers Quick and Dirty Tips for Growing Your Business with Digitial Tools
  • The Public Speakers Quick and Dirty Tips for Improving Your Communication Skills
  • The Thirsty Developer
  • This Week in Web Design

If you have a podcast that you think may be of interest to me, particulalry in the areas of software development and agile, let me know.


Copyright © 1996-2010 Developer.Blog();. All rights reserved.
iDream theme by Templates Next | Powered by WordPress