Friday, August 31, 2007

Answer("I Don't Know") != Credibility.Diminished()

I’ve long had great disrespect for people who, when confronted with a topic they were unsure of, would blindly prattle on with complete disregard for accuracy.  I once worked around a guy who was pretty close to outright dishonesty on a number of occasions and I hated going on client trips with him.  I was glad to leave that company for any number of reasons, even though it meant me being out of work for awhile.  That guy, while not my direct boss, had enough impact on my line of work that I was glad to be away from him.

I’ve never had a problem saying “I don’t know” because the next phrase out of my mouth is “but I’ll find out for you by tomorrow.”  I never felt that diminished my credibility or weakened my position.  Masiter, Green, and Galford make this point several different ways in The Trusted Advisor: you gain credibilty with your client (the ones you want) because you’re being completely honest with them and they’ll respect that.

Then came a meeting earlier this week.  A couple decades of my stark adherance to “I don’t know” slipped away in a minute when I got confused about some issues several months in the past that I hadn’t been on top.  I’d just moved into the role as project engineer and hadn’t completely caught up with the entire history of what had been going on around me.1  Instead of just saying “I don’t know; I’ll get back to you tomorrow” I prattled on like a complete asshat and talked myself into a spiral for a couple minutes.  The customer was already unhappy for a number of reasons from both our and their side, and all I did was dig that hole deeper.

How do you get out of a hole?  Stop digging first, dumbass.

I let my confusion over those issues, and my new role as the project engineer with a difficult client, lead me astray.  The result?  The client called our sales manager to express a lack of confidence in our ability to deliver.  The customer saw my confused prattle as misleading and borderline dishonesty. 

Ouch.  Mega ouch. 

If you know me personally then you may have an inkling of how much that hurt.  You couldn’t hurt me worse by kicking me in the goolies or telling me my BBQ ribs suck. I had a talk with the sales manager and my boss and they know that I wasn’t intending to mislead, but it still hurts that an aspiring old fart like myself with a fair amount of experience let something get so out of hand.

I’m a firm believer that everyone should have a major “Oh Shit!” moment every once in a long while.  Hard Knocks 101 is a great educator and reminder that there are indeed better ways to do things.  My such moment came Monday.

The great program manager handling the project got things smoothed over with the client from the relationship side.  Now I need to step up and smooth things over from the delivery side.  We’re on track to deliver the client a solid system which will, hopefully, restore some of my credibility with the client.

Lesson learned?  Yes.  Absolutely.

[1] Yes, yes, yes.  Do the agile thing and own the entire code and the entire project.  There’s a different story around all that, but I’ll leave it for another Hard Knocks 101 post sometime later.

Workflow Podcast on Parallel Tasks

ARCast.TV with Ron Jacobs isn’t something I get a lot of useful content out of, so I don’t listen to it on a regular basis.  That said, the ‘cast on DinnerNow’s architecture and workflow had a seriously practical, useful example on getting parallel tasks in workflow done right.

This was a problem I was around when working with Rus on a couple MOSS-hosted workflows in my previous job.  (Rus was really doing the work.  I was just the one doing lots of hand waving in front of the client.)

It was great to hear detailed specifics in an ARCast session, particularly some that I will be able to apply in upcoming work.

(ARCast is a videocast, but they also put out audio casts that I get via an iTunes subscription.)

Wednesday, August 29, 2007

CodeMash Prospectus Updated

We’ve already had one update to the CodeMash Sponsor Prospectus — we’ve lowered pricing for sponsors!

The updated Prospectus is still at the same location on the CodeMash site, so go grab it and pass it around to any folks you think may be interested in being involved with CodeMash.

(“lowered pricing” sounds a helluva lot better than “I screwed up and posted the wrong version of the Prospectus”.  Just run with it, OK?)

Tuesday, August 28, 2007

Fitnesse Presentation Update

The Solutions group at Quick Solutions where I work has a monthly department meeting where we go over the department’s business status followed by a grok talk.  The biz status update is one of the things I love about work at QSI: complete transparency with all employees being encouraged to have a clear grasp on what the company at large and our department is doing.

I gave tonight’s grok on using Fitnesse, but was disappointed in my presentation.  I didn’t get a good story out to the crowd on how Fitnesse can help with difficult biz process testing.  I also didn’t get a good story across on how the workflow of story-driven testing goes with Fitnesse.

I showed my own version of a ColumnFixture table tied to a payroll system, then I used Paul Vlagsma’s port of the examples from the FIT book for the rest of the grok.  I showed the ActionFixture example for the ChatServer which is effectively one set of steps in a workflow, and while it’s simple and cool it’s not really clear how that ties to a business process.

What I should have used was the Rental example showing an entire process flow:

This is a great example because it shows how you can use one test page to create setup values, sub-actions, and a series of workflow steps with specific tests along the way.  This example is a lot better demo of Fitnesse’s goodness.

So if you were at the grok, here’s an additional example for you to think about.  Sorry I didn’t flesh out this part of the talk better.

Now Playing: Mike Ferris — Salvation in Lights. Salvation in Lights has been getting a lot of play time as I work through code on a project I’m getting close to wrapping up.  I don’t spend a lot of time listening to gospel music, but Ferris’s bluesy/rock covers are just amazing.  He’s got a stunning voice, the songlist is wonderful, the band’s fantastic, and the production of the albumn is stunning.  Ferris spent a bit of time fronting for Double Trouble after Stevie Ray Vaughn died and he brings a lot of SRV’s gutsy style to this disk.  Ferris’s Goodnight Sun is also a terrific disk. 

Monday, August 27, 2007

CodeMash Sponsor Prospectus Live!

The Sponsor Prospectus for CodeMash is live and ready for interested parties to peruse.  We’ve a number of very cool opportunities for companies to take advantage of.

If you’re even remotely interested in sponsoring CodeMash, or know a company that might be, please grab the prospectus and have a looksee.

Feel free to contact me directly via the link on the right sidebar if you have any questions.  You can also contact the sponsor alias: sponsors AT codemash DOT org.

CodeMash v2.0.0.8 isn’t far away!

Saturday, August 25, 2007

Book Review: Fit for Developing Software

I’ve been really intrigued by Fitnesse and FIT (Framework for Integrated Tests) for some time now.  Fitnesse’s based on FIT and gives you a way to make tables for testing computations, queries, and workflows.  Those tables are hosted on a Wiki, and a web server plus a test runner enable you to tie the test tables to your software under test via some “Fixture” code you write.  It’s a unique concept, and lends itself to story-based development where you and your customers write up stories detailing how the systems works, then you run off and code up some fixtures and the system behind.

Some folks in the agile world are starting to become less enamored with it, but I think it’s got great potential as an enabler of communication between development teams and customers.  With that in mind, think about picking up a copy of “Fit for Developing Software: Framework for Integrated Tests by Rick Mugridge and Ward Cunningham.  (Prentice Hall Publishing, ISBN 0321269349.

The layout of this book is as unique as FIT/Fitnesse are themselves.  The book’s first half is targeted to business analysts and customers who team together to write up the stories for the system.  The second half targets developers who will write the fixtures to tie the tables to the system.  The stories and use cases are all well-done and, unlike too many other books, are on real-world situations.

There are detailed descriptions of the various fixtures supported by FIT with good examples of when you’d want to use them.  The different parts of the book tie together perfectly in that the story is covered in the beginning and the developer-related sections later in the book amplify on the foundation laid earlier.  I also like the Q&A portions scattered throughout the book.

The book’s tone and style compliment the approach of the book, keeping it light and easy to read while laying out the immense value of FIT.

To Understand Recursion, You Must First Understand Recursion (and XPath and XPathNavigator)

I can’t take credit for that line; I stole^H^H^H^H^Hborrowed it from someone who I can’t remember.

I’ve been having some fun working with recursion, XPathNavigators, and interesting XPath queries, so I thought I’d share some tidbits I worked through.

I’m working on building a converter to take a hand-crafted table of contents in HTML and transform it into an XML structure I’ll use for navigation in an app.  The input HTML is currently used by an ActiveX plugin (barf) which displays the navigation tree.  The HTML’s format is basically this form:


   (cruft elided here)




  <object type="text/site properties">

   (cruft elided here)





      <object type="text/sitemap">

         (cruft elided here)





          <object type="text/sitemap">

           (cruft elided here)





          <object type="text/sitemap">

            (cruft elided here)






(NOTE: I’ve used Tidy to first transform the straight, unbalanced HTML into well-formed XHTML.  That way I’m able to load it up in an XmlDocument object and do all kinds of tomfoolery with it.)

The tree works via unordered list and list items, with the actual entries being the <object> elements.  (They hold navigation and title info which I’ve elided for brevity’s sake.)  An object doesn’t have its children as direct decendants of its element, however.  Instead, they’re decendants of the sibling <li> element.  I need to go through this entire psuedo-tree and pull out and transform the contents of each <object> into a new file where those elements become <TocEntry> elems and children.  The target output will look something like this




    <Title>Operations Manual</Title>












    <Title>Operation Course Manual (top level)</Title>





As part of that transformation I need to assign each <TocEntry> a unique ID.  I also need to do some “interesting” XPath navigation to go back up two levels and then to the previous element in order to find the current <object> element’s logical parent.

Walking the input XHTML tree starts by first selecting the top level of the tree, the html/body/ul element.  I’ll be using an XPathNavigator object and an accompanying XmlNamespaceManager.  The manager will deal with the default namespace for the XHTML document.

NameTable nTable = new NameTable();

XmlNamespaceManager manager = new XmlNamespaceManager(nTable);



//get top-most UL as a node

XmlNode currentNode =

    input.SelectSingleNode("//html:html/html:body/html:ul", manager);


XPathNavigator currentNodeNav = currentNode.CreateNavigator();

XmlDocument output = CreateOutputDocument();

output = WalkTree(currentNodeNav, depth, output);

Now I can head off and work through the tree.

private XmlDocument WalkTree(XPathNavigator currentNodeNav,

                            int depth,

                            XmlDocument output)


    XPathNavigator inputNav = currentNodeNav.Clone();


    if (inputNav.HasChildren)



        ProcessNode(inputNav, output, depth);

        while (inputNav.MoveToNext())


            ProcessNode(inputNav, output, depth);





        while (inputNav.MoveToNext())


            ProcessNode(inputNav, output, depth);




    return output;


I need to do a depth-first walk of the tree in order to build up the parent-child relationships in the easiest order, so the first thing to do is to run down the line of the current node’s children.  If it’s a leaf with no kids then we can process it and look to its siblings, otherwise we’ll dive further into the tree.  This is hanlded by the ProcessNode method.

private void ProcessNode(XPathNavigator inputNav,

                        XmlDocument output,

                        int depth)


    if (inputNav.Name.Equals("object",



        BuildTocEntryNode(output, inputNav, output.DocumentElement, depth);




        WalkTree(inputNav, depth + 1, output);



BuildTocEntryNode just grabs some values from the current input node and creates new elements in the output document in the format I need.  It’s omitted for brevity’s sake since it’s just effectively getter kind of cruft and there’s a moderate amount of it.

The cool bit that took me some work was figuring out the parent node’s ID value.  The structure I’m building for the output file is a flat format with its heirarchy stored via ID and ParentId elements — this feeds into a Telerik TreeView control I’m using to display the table of contents in the app.  I can’t navigate the output file, but I need information from it.  The solution I came up with was to get some unique information from the parent in the input file, then use that as a query in the output file to find the right node.

There’s some cruft elided from the following steps, but you’ll get the idea.  First I need to clone the navigator at the current node so I can move it around without screwing up my working context:

XPathNavigator parentFinderNav = currentInputNodeNav.Clone();


Now I can move up from the current <object>, past its containing <li> elem, and then over to the previous node which should be the parent <object> elem.


if (parentFinderNav.Name.Equals("li",



    //move up one more, then previous from <li> to <object>

    // we decended from




Now I need to grab the target URL, something unique about this parent node.

XPathNavigator targetNav =



string parentTarget = targetNav.GetAttribute("value", "");

Now I need to go find the corresponding node in the output file, so I’ll get a new navigator from my current output context:

XPathNavigator outputParentFinderNav = currentOutputNodeNav.Clone();

Now here’s the cool XPath query: I need to find an <Id> element whose sibling has the same value as the URL I got from my input object’s parent (parentTarget above).  I can use a nifty XPath selection statement to do just that:

"//Id[../Target = \"" + parentTarget + "\"]"

So the complete statements for that look like this:

XPathNavigator idNav =

    outputParentFinderNav.SelectSingleNode("//Id[../Target = \"" +

                                           parentTarget +



string parentId = idNav.Value;

There are undoubtedly improvements which could be made in this code; however, it passed tests and generated the file in the format I needed and all the Id/ParentId values linked up as required.  I’m a happy camper.  This could also have been done in XSL; however, I needed to get the feature done in a few days and didn’t have the patience to spend working through the unintelligble XSL I’d need to create to get the transform done.  If you’re an XSLT ninja who could do all this in eight lines of XSL then good on you, and please write it up and let me know!

This is probably one of the longest posts I’ve ever written, but I had a couple interesting tidbits to share.  Hopefully you’ve found it useful……….

Thursday, August 23, 2007

Handy XPath Tool

XPathmania is a terrific Visual Studio plugin which lets you run XPath queries against an XML document in a VS XML editor window.

Nice highlighted results, as seen below.

Don Demansk I mean Don XML talks about the plugin on his blog.  Obviously it’s not a brand new tool, but it’s highly useful for figuring out PITA XPath expressions.

XPathmania is part of the highly useful Mvp.Xml project out on CodePlex.  I’m using a couple of their libraries in my projects, one of which, EXSLT.NET, will hopefully solve a nasty problem I’m having trying to use XPath for querying poorly written HTML which I’ve converted to XHTML via Tidy.  More on that later after I actually figure it out…

WSS Sucks! WSS Rocks!

Brian wrote a great post on some very cool things he did for the CodeMash site.

Brian’s post highlights a couple of the many things that suck about WSS/MOSS: horrific error messages, and convoluted, brittle implementation of various features.

His post also highlights some of the many cool things about WSS/MOSS, like the ability to use a list to feed out content via web services.  We’re also using a list to catch topic submissions filed on the CodeMash website.  That’s simply wicked cool, and is a great value-add for our speaker committee.

Check his post out.

Tuesday, August 21, 2007

Perhaps the Greatest Design Tenet?

…I've mostly come to the conclusion that any design effort that takes more than, say, 30 minutes is a waste of time.”  Sage advice snipped from a blog post by Eric Gunnerson.

I may be close to dowdification with my selective quote, but I think Eric’s blurb is spot on.  YAGNI, anyway.

Sunday, August 19, 2007

Wandering Speakers: Just Don't Do It!

Twice in the last three months I’ve sat through presentations where the speaker felt the need to wander throughout a large room (200+ folks at dinner tables) while giving a talk. 

That’s an awful, awful habit as far as I’m concerned.  It’s disconcerting to be reading something from the slides, then spend 30 seconds trying to find the speaker in the large room because they think it’s cool to either a) go walkabout or b) play some variation of “Where’s Waldo?”.  In both cases the speakers were otherwise giving a fairly good presentation (too many bullet slides, but that’s beside the point) and I started to tune out because I lost connection with them.

Don’t get me wrong.  Giving your presentation while stapled to your podium or table is also an awful habit, but you shouldn’t be meandering so far that your audience can’t quickly move from watching you to looking at your presentation.

There’s a nice balance involved in moving around while talking.  Casual wandering near your screen or stage is good.  Hanging out in the back corner of a large room?  Not so much.

Saturday, August 18, 2007

Shout Out: Day of .NET In Ann Arbor, 10/20/07

The folks up north are at it again: another episode of the Day of .NET in Ann Arbor, MI.  They’re moving to twice a year for these events which is fantastic.

Check out the site and submit a topic or three if you’re interested in speaking up there.

Friday, August 17, 2007

Nifty XML Editor

GVim rocks.  It’s lightweight, it’s got wicked great support for regex work, it’s loaded with numerous features that really speed editing work, and you have to type “:q” from within the editor to quit.  It doesn’t get better than that.

Wait, it does: There’s a handy XML editing plugin for Vim based off the xml.vim file which ships with Vim.  The extension provides a number of additional features like tag folding, joining tags, changing tags, and my current favorite: adding a tag to a block or tag.

I’m having to do some cleanup of badly balanced, badly written HTML which will be formatted to XML.  There are a number of instances where a particular tagset should be surrounded by a list item tag (<li>) but isn’t.  The tag surround feature comes in very handy for that since I can quickly get some cleanup with just a few keystrokes.

(I’ve looked at writing some XPath code to handle this, but that would actually take longer in this case…)

Tuesday, August 07, 2007

MOSS and Database Mirroring

SQL 2005’s mirroring gives an alternative to clustering for backup/availability scenarios, and of course there are a passle of considerations to grok.  This white paper talks about mirroring for MOSS farms and covers a lot of important territory.  File under Must Read for your MOSS planning.

(Via Joel Oleson via Steve P.)

SharePoint Skillset

SharePoint 2007 is huge.  Clients don’t understand how huge it is, management and sales often don’t get it, and many candidates who express MOSS “experience” also don’t seem to get it.  Joel Oleson has a blog post listing some of the skills a MOSS IT Pro or Architect needs — and his list doesn’t even include the details on the development side of things!

Because of my involvement with the Dayton .NET User Group I’ve had a lot of contacts from staffing companies looking for SharePoint experts.  I have a hard time getting it through recruiters’ heads that finding a MOSS solution architect, developer, or even admin is going to be a tough, tough hunt.  (Recruiters not listening or understanding a position’s requirements?  Go figure…)

Use Oleson’s list as a training plan if you’re interested in moving into the MOSS arena.  Use it as an aid to convincing your management that picking up MOSS is not something you can casually do via a vew hours of homework.

(Via Steve P’s killer SharePoint Link List.)

Monday, August 06, 2007

Updating Template

Something in the various migrations around to the various flavors of Blogger over the last year finally made my customized templates barf.  Ick.

I just blew away the customized template I had stolen from Jason Follas some time back.  If you’re hitting my site via a browser then you’re now seeing one of Blogger’s templates with some light customization.  I may eventually get back to the very cool color and font scheme that Jason came up with; however, time being what it is I may not…

Leave me a comment if you notice anything absolutely awful.

Archtecting for SharePoint Governance and Content

The SharePoint Team posted a great blog article on architecting for SharePoint deployments.  There’s a lot of great content in that article, and it really lays out what I think is a critical tenet: Content Is King.  Figure out how long your content will need to be around, and make many of your architectural decisions around that.

The article has some great discussion on laying out SharePoint installations: How you should host on server farms for particular implementations, how quotas should be addressed for those implementations, what considerations to give for self-service site creation, how to deal with content expiration for that, etc.  It really is great reading.

(BTW, if you’re in the SharePoint space make sure you’re subscribed to Steve Pietrek’s SharePoint Link blog.  Steve gets a great amount of highly useful links out on a daily basis.)

Friday, August 03, 2007

Step Away From The Keyboard

All the great folks in our geeky career domain are passionate about what they do.  They’re passionate about technology, they’re passionate about getting quaility solutions built, they’re passionate about solving tough problems for customers.

That passion is a critical part of our job, yet it can also be a hinderance if taken too far.  Frustration over any number of factors build up, stress piles on, and that passion can turn from a highly motivating force into a massively destructive factor.

If your frustration factor is building up, take a moment to consider how quickly you need to respond to an e-mail or an IM conversation.  High frustration leads to responses that are ill-thought, and/or are in phrases or a tone that’s nothing like you’d use in face-to-face conversation. 

Do yourself and your correspondent(s) a favor and step away from the keyboard.  Put the “urgency” of the issue in the right context.

Consider that last sentance for a moment.  I used to work in a job where urgency meant get something done right away because people could die1.  I also worked in a different job where urgency meant get something done right away or the company would be losing tens of thousands of dollars per minute because of a system outage.

If the situation you’re involved in doesn’t run the risk of death or huge per-minute costs due to outages then you’re not in a situation where you absolutely must respond to that message immediately.  Step away from the keyboard and let your emotions calm down.  Leave off responding to that e-mail for four hours.  Let your IM partner know you’re taking a short break, and be honest about the reason why.  Use the break to re-think your approach and re-assess how you can work with your correspondent to solve whatever the issue is.

(If you are in one of those jobs then stop being an asshat and put your passion aside because what’s called for is calm, cold clarity and speedy precision.)

I’m writing this post after having done just that with a person who is a good, good friend.  We were both getting angry over how to best achieve a very cool goal, but had different views on a few things.  I had to step away from the IM session and go beat my kids.2 When I came back to the computer I was completely calmed down and was able to move past our mini-tantrum.  (Note that was “our” tantrum.)  My good friend and I left the newly-resumed conversation in a much better frame of mind than we otherwise would have.  Problem solved.

Don’t let your passion run rampant over whatever it is you’re trying to accomplish.  Passion’s a Good Thing.  Unbridled passion?  Rarely so.

[1].  My wife and I had served with 75% of the crew of YUKLA 27 when it crashed due to striking a flock of geese just after takeoff.  Good men, all, and I still miss ‘em.

[2].  Be real.  I’m kidding, for crying out loud.

Thursday, August 02, 2007

Need a Mission Statement?

How about

“Our mission is to professionally restore scalable leadership skills and synergistically customize cost effective paradigms because that is what the customer expects.”


“We exist to assertively fashion cost effective technology and globally provide access to multimedia based methods of empowerment in order to solve business problems.”

Both from Dilbert’s Mission Statement Generator.

(Via Scott Berkun’s essay “How to detect bullshit.”  Mirrored here because his server got Dugg hard.)

Using the Immediate Window in VS to Explore APIs

The Immediate Window in Visual Studio can be a great help if you’re trying to grok a particular API, or do a quick spike/prototype to understand behavior of a class, method, or property. The Immediate Window lets you make API calls, check values of variables, and even do assignments.  It’s a handy way to explore how your program’s behaving and how things might work if you alter data or calls.

For example, the documentation for the bits and pieces of the highly useful Uri and VirtualPathUtility classes often don’t include examples of what’s returned from various calls.  This is a hinderance as I’m trying to get formatting of file-based resource URIs correct to play with the WebBrowser control I’m using.  I need to do two things: 1) ensure the format of the URI is correct when I assemble it in the actual <link> element in the content source, and 2) extract a complete absolute path to the resource without the protocol part when I am doing my navigation.

I can write a prototype app with a class full of a bunch of crappy Console.Writeln statements to see the before/after bits. This isn’t much fun, even if I use Snippet Compiler.  On the other hand, I can start my existing project in VS in debug mode with a breakpoint set appropriately, then play around in the Immediate Window to discover the exact format of the URI and which API call I need to make.

For example, say my input Uri is a variable called “resource” which will point to a file-based resource. My starting content for that might be “file://Temp/Test.pdf”.

I flip to the Immediate window and enter


which results in


Not what I wanted since it’s missing the Temp directory.  Maybe I can look at Uri.LocalPath:



Still not right, since the Temp folder is showing up as location component.  Let me alter the actual Uri variable “resource”:

resource = new Uri("file://c:/Temp/Test.pdf")

You’ll see a whole bunch of stuff fly by as all the new Uri’s properties are displayed.  Now let’s check the LocalPath property again:




All this is pretty simplistic use of the Immediate Window, but it shows a different aspect than it’s normally used for.

Wednesday, August 01, 2007

Nifty SharePoint Utility

I haven’t tried this but it looks very cool: A system tray widget to manage AppPools on your MOSS box.  Additionally, you can configure URLs to visit after an IIS Reset or AppPool refresh — that way your sites will automatically get visited after a bounce, reducing the load time when you finally get around to visiting those pages.

I’ve been slowing moving back into the MOSS arena.  This widget will definitely get added to my toolbelt.

UPDATE: Forgot to cite my references.  I found tell of this in a comment on Sahil Malik’s blog post on his VM setup.  (FWIW, I asked him what tools he was using for automation and testing.  Strangely that comment didn’t make it past his moderation.  Maybe he doesn’t do any testing?)

Subscribe (RSS)

The Leadership Journey