Category Archives: Code

Software Development

Doing Architecture with Agile Teams

Alan Gawthorpe & I a talk last month on doing architecture with agile teams:

We did the session agile-style: We had cards for our topics, and the ‘customers’ in the audience prioritised. I think it worked okay, it would probably go smoother doing it a second time. Some of the significant books & articles that went into the slides were:

Agile Methodologies for the Enterprise

* Scott Ambler & Mark Lines – Disciplined Agile Delivery
* Scott’s whitepaper on Agile@Scale

What does a technical architecture for agile look like?

* Coplien & Bjørnvig, Lean Architecture for Agile Software Development
* Poppendieck & Poppendieck, Lean Software Development: An Agile Toolkit

The further reading list

* George Fairbanks, Just Enough Software Architecture
* The UK government’s national audit office report on Agile Governance

Visual Studio 2012 Command Prompt Here

Something I always want with VS projects: The ‘Command Line here’ menu option within Visual Studio; and the ‘Visual Studio Tools Command Line here’ option in Windows explorer. So here they are for VS2012.

NB: that the Explorer right-click works when you right click on a folder icon but not, sadly, when you right click on empty space. If anyone has a solution for that I’ll be glad to know.

Windows Explorer “VS2012 Command Prompt Here” Right-Click Menu Item

To add a Visual Studio 2012 Command Prompt Here to your Explorer Right-Click menu, save this as a .reg file to your desktop, and then run it:

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\Command Line VS2012]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\Command Line VS2012\command]
@="cmd.exe /k echo on & pushd \"%1\" & \"C:\\Program Files\\Microsoft Visual Studio 11.0\\VC\\vcvarsall.bat\" x86"

If you have 64-bit Windows, you might want:

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\Command Line VS2012]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Folder\shell\Command Line VS2012\command]
@="cmd.exe /k echo on & pushd \"%1\" & \"C:\\Program Files\\Microsoft Visual Studio 11.0\\VC\\vcvarsall.bat\" x64"

Visual Studio 2012 External Tools Command Prompt Here Menu Item

In visual studio choose TOOLS – External Tools. Press Add to add a new command with fields as follows:

Title: Command Line Here
Command: %COMSPEC%
Arguments: /K "%VS110COMNTOOLS%\VsDevCmd"
Initial Directory: $(ItemDir)


Visual Studio External Tools Command Line Here VS2012 Dialog Box

Sorted. You can add shortcut key to via TOOLS – Customize – Keyboard and setting a shortcut key for Tools.ExternalCommand{X} … but you have to work out by counting what number your {X} is.
Visual Studio Customize Keyboard Tools.ExternalCommandX Dialog Box

WCF on .Net 4.x ReST Service with IIS 7 or 8 = HTTP Error 404.17

So my newly created WCF ReST service (or webHttp service, as MS more accurately like to call it) runs fine in Visual Studio 2012, using IIS Express. But when I switch to IIS proper (in my case, IIS8 on Windows 8) I get:

HTTP Error 404.17 – Not Found
The requested content appears to be script and will not be served by the static file handler.

Most so-far extant posts on how to fix this, refer to how to fix it for .Net 3 on Windows before Win8: Use "%WINDIR%\Microsoft.Net\Framework\v3.5\Windows Communication Foundation\ServiceModelReg.exe" to register or to repair registration of WCF components. (The other gotcha being, having the right AppPool settings for .Net version & for 32 vs. 64 bit).
This doesn’t work for Windows 8 / .Net 4.X. Instead you must open the control panel “Turn Windows Features On or Off” and tick the box for Http activation:

Windows Features - Windows 8 - Net45 - WCF - Http Activation Tickbox

Windows Features – Windows 8 – Net45 – WCF – Http Activation

Which should fix the issue after a couple of minutes.

Agile Adoption

If a team or organisation wants to adopt agile, should they do it all in one, or gradually? How do you overcome problems in agile adoption?

Agile Principles when Adopting Agile

Agile is not about process and methodology; it’s about people, relationships and learning and so turns out to be very much democratic and consensus based. Effective adoption presupposes that you’ve got the team(s) on board; if you have to impose agile, you’re probably doing it wrong. You can’t adopt faster than your teams and individuals are motivated to adopt.

If you apply the agile manifesto to the project of ‘adopt agile’ then you’d adopt agile incrementally, of course. I suggest an obvious principle: You can’t adopt faster than you can learn.

Agile’s take on organisation & adjustment is that teams self-organise with regular reflection, which enables you to see what’s not going well and consider ways to correct. There is no learning without feedback. Adopt incrementally with regular reflection and adjustment.

Agile teams puts work items in priority order, in to deliver the greatest business value first. Look at your current pain points – what’s not working well – and find out which practices are found to address them. Prioritise changes which add most value.

Risk management is arguably a missing subject in agile, so let’s add that here: soberly consider what, at this stage, you are capable of adopting successfully. First adopting practises you’re capable of to maximise your chance of early success. The choice to deliver value or to attack risk first is a judgement call. When you’re doing something new the risk of failure is high, so that judgement is largely about knowing how new to your team(s) the changes you’re making really are.

Finally, agile starts with the vision of a wider community learning. Any fool can learn from their mistakes but the wise learn from others’ mistakes too. In the past 10 years, others have already tried out all the mistakes for you. Call in someone in who’s done it before.