Tribes and Software Development

Creating software is easy. Selling software is difficult.

Software houses are spending huge amounts of money attempting to create great software to solve problems. Companies spend huge amounts of time and effort on creating amazing technical solutions, attempting to understand the market while pushing their latest release under the noses of anyone who might be interested. This is wrong. For a large amount of time, no one is actually listening. This is a problem, if no-one is listening, how can you expect to make money?

This week I attend Seth Godin – The London Session where Seth was discussing marketing, leadership and being remarkable. For those of you who are unaware of Seth Godin, he is a leading marketing author and speaker, writing a series of influential and thought-provoking books on how to create and market products. His latest book, Tribes, certainly left a lasting impression on myself, but how does it relate to software development?

According to the book, a tribe is a select number of people with a shared vision, passion and goal which you are lucky to be a member of. In order for a tribe to be successful, they need to be lead. Leaders need to understand their tribe, what they want and why they are passionate. To be successful, the tribe also need to be given a goal, or an objective, something which they can all focus on.

Software development is full of tribes. We have leaders, either influencers within their field or companies with amazing software, leading their tribe. We have huge numbers of passionate users who want to get involved, want to improve the products and who want to be lead. The book opens with an example of a leader – Joel Spolsky. Another example is Scott Hanselman. Both are leaders, both have a tribe. Scott Hanselman is a classic example, he engages with his tribe via twitter, blogs, podcasts, conferences and the occasional nerd dinner. The tribe can communicate with each other via comments on his blog and the forum.

Alongside leaders we have enablers. Enablers are similar to leaders as they need to understand the tribe. They are the person who can keep everything on track, guide the tribe when required and basically set the tone. They do not lead, they enable. Two examples of enablers and Michelle Flynn at Conchango and Rachel Hawley, who is currently looking for a new companyposition. Michelle helps organise various user group and community events within London at the Conchango offices, the events run smoothly and this has a positive impact on the Conchango brand. Organising the venue and details allows the leaders to lead.

Rachel Hawley is another great enabler. Having worked with Rachel for the past 18 months at Red Gate, she demonstrated how you can build and enable a tribe. Rachel lead the Friends of Red Gate program, connecting questions with the correct product team, ensuring the tribe was kept up-to-date and happy. One of her many other roles was to enable people to lead tribes. By connecting Red Gate to user group leaders and providing sponsorship and support, she took away some of the pressure allowing them to focus on leading.

But as a software company, why do you need a tribe? If you have a tribe wanting to follow your company and your products, then you are lucky. It means you have a product which people think is worth talking about and worth getting passionate about. The result is that this tribe will evangelise the products for you. An example of this is JetBrains. JetBrains have passionate users who will share their story with friends, give talks at user groups, conferences and write blog posts about how they use the products. For example, I have wrote blog posts and given two presentations on TeamCity. JetBrains don’t pay me, product is free, I do it because I believe in the product and the story.

If you give them a platform, they will shout loud and clear and how amazing they think your product is. This form of peer-to-peer marketing is by far more effective than a banner ad. Because this set of people are part of the public face of your company, you will find that they are happy to answer questions and help people get started.

Once you have your tribe who believes in your software, allow the tribe to improve it. Engage with them to find out what they like, what problems they hear about and the issues being faced. Let the tribe guide your software development. The result is that the tribe will have a closer bond to you and believe even more in the story – because they helped create it! This can even be extended to include idea generation of new products, remember these people are doing their job day-to-day and they know the problems, listen to them. A perfect example of this is Microsoft and the MVP program.

But you can’t force a tribe to follow you, you still need an amazing product and something worth talking about. You also can’t force a tribe to do something they don’t want to, you can only encourage them. You can create the stories, give them a platform, provide them with a goal and celebrate the accomplishments. But you can’t force the tribe to act, it must be off their own back.

As a company, a tribe is something you should value and not a threat as a cost centre. Respect your tribe! The rewards will come.

When Mozilla released Firefox, a tribe was soon created. Firefox had the vision of gaining market ​from IE by being the best browser, focusing on speed, security and extendibility. This story aligned with the tribes worldview of being unhappy with IE6 and as such they shared the goal. However, tribes need a platform, they need somewhere to shout from and people want to know that they are not shouting alone. Mozilla provided this with the Spread Firefox website. This was the tribes platform, this allowed the tribe to communicate with each other, the team and be aware of the latest events. This gave the tribe a sense of belonging. The tribe also had goals to achieve, a focus, a common urgency to push for. First goal was to raise enough money to buy a two page advert in the New York times. The second goal was to set the record for the most downloads in 24 hours. This record resulted in crashing of many servers and 8,002,530 downloads. Finally, Mozilla have also allowed the tribe to improve the product. Firstly by having a public bug tracking system and being open source. Secondly, by having an amazing extension model to allow the product to be extend in ways which Mozilla would never of had time to complete.

Is Firefox technically a better browser than Google Chrome or IE8? Or was it the tribe which made it the best browser available? Would this approach of leading the tribe work for all software? No! Mozilla understood the tribe. They had a story which the tribe believed and Mozilla lead them. The result was a success.

This tribe changed the world.

At the event I was given a copy of the Tribes book. I already have both the audio book and the physical book so I am giving my copy away. To enter, simply send me a request for the book via twitter (@ben_hall). I will then randomly select someone and be in touch for your address.

If you then wanted to share your thoughts on the book and pass it on, that would be amazing! I wonder how many people this book could reach?

Finally, what happens when a company ignores the tribe and what their users are saying?? The tribe will lose their passion, they will stop believing and stop using you. If you are not communicating with your tribe, your competitors will. When that happens, They win – You lose.

MSDN Magazine: Getting Started With IronRuby And RSpec, Part 1

February2009

My latest article has been published in this months MSDN Magazine. The article is an introduction to IronRuby, finishing with an initial focus on how you can use RSpec and IronRuby together to test C# applications. 

Using IronRuby to test C# applications is an interesting concept and I look forward to seeing how people use the two technologies in the future.

image

I’m really pleased to have been published within the magazine. I have been reading it since I started with .Net so it feels a little strange to know that I’m actually one of the authors…

I still need to get my hands on a physical copy.

Read it here:

http://msdn.microsoft.com/en-us/magazine/dd434651.aspx

Keep an eye out for part 2 in next months edition.

DDD7 Session Video – Microsoft Pex – The future on unit testing?

As you may recall, in November I presented at DDD7 in Reading, UK about Pex and the future of unit testing.

Is unit testing about to have a major change? Pex is a project from Microsoft Research which automatically generates a traditional unit testing suite with high code coverage from hand-written parameterised unit tests. In this session, Ben explores the Pex framework, explaining the approach the framework takes and how it computes the test inputs based on your programs execution. Ben demonstrates how to use the framework and how it could potentially change the way we write unit tests.

At the time the session was recorded, with a little help from Liam (thank you!), the session is now available online. I hope you enjoy it!

Slides and code are available to download from here

ASP.net MVC RC1 – Removing Code Behind files

With ASP.net MVC, one thing I always wondered is why we still had to have the code behind files. Looking at the FubuMVC samples, everything looks much cleaner without the additional files – with RC1, code-behind files are no longer required!

However, if your upgrading from beta, you will need to change your ASPX pages. In this post, I will cover the steps I went through to remove these files.

During beta, my solution looked looked like this:

image

In my code behind, I have a mixture of strongly typed ViewPage objects and the standard ViewPage. As a result, in my ASPX page, I had a CodeBehind file and a Inherits tag.

image

With RC1, I can remove the CodeBehind tag and replace the Inherits to System.Web.MVC.ViewPage directly.

image

I can now delete Index.aspx.cs and Index.aspx.designer.cs leaving me with just the Index.aspx file.

If my ViewPage was strongly typed with a model, the the Inherits tag would include this, just like with the code behind model:

image

For ASP.net MVC User Controls, instead of ViewPage you use ViewUserControl:

image

Similarly with Master Pages:

image

After changing all my views, controls and master pages, my solution looks like this:

image

This makes me happy.

UPDATE: Parser Error Message: Could not load type ‘System.Web.Mvc.ViewPage‘.

Ok – I made a little mistake. When I hit my ViewPage, I received a Parser error message. If I had paid more attention to the release notes, I would have noticed I needed to copy an additional block of xml into my web.config.

     pageParserFilterType=”System.Web.Mvc.ViewTypeParserFilter, System.Web.Mvc, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35″
     pageBaseType=”System.Web.Mvc.ViewPage, System.Web.Mvc, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35″
     userControlBaseType=”System.Web.Mvc.ViewUserControl, System.Web.Mvc, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35″>
      
           
      

Technorati Tags:

Upgrading a project from ASP.net MVC Beta to ASP.net MVC RC1

As I’m sure you are well aware, the ASP.net team have released ASP.net MVC RC1 tonight.  Eager to find out how much additional work I had, I downloaded and upgraded my solution – I was pleasantly surprised.

All I had to do was:

  • Uninstall beta bits
  • Install RC1 bits
  • Update project references for System.Web.Abstractions.dll, System.Web.Mvc.dll and System.Web.Routing.dll
  • Build
  • Test
  • Done!

Following my own advice, I commit the updated installer and assemblies into source control. Everything appears to be working, but I guess your mileage may vary.

Technorati Tags:

Annotating Code with .NET Reflector and Review Add-In

My latest article for Simple Talk has just been published. In the article, I cover how you can use the reflector addin ‘Peli’s Review’ from CodePlex that allows you to add annotations about your .Net assemblies from within reflector.

Reflector - Peli's Review

You can read it here:

http://www.simple-talk.com/dotnet/.net-tools/annotating-code-with-.net-reflector-and-review-add-in/

Identify the location of your SQL Server databases using T-SQL

While creating a series of test databases, I was required to hardcode a location to store the files. This caused me a problem as I wanted the script to be reusable on different machines platforms while also being consistent. I couldn’t enter the path for the SQL Server data files as this can be different, and I couldn’t enter a different path because it might not exist and I wasn’t keen on creating directories via T-SQL and xp_cmdshell.

While, it turns out you can find the location of your default SQL Server store simply by querying the system tables –sysaltfiles and getting the path for a particular database such as master.

DECLARE @device_directory NVARCHAR(MAX)
SELECT @device_directory = SUBSTRING(filename, 1, CHARINDEX(N’master.mdf’, LOWER(filename)) – 1) FROM master.dbo.sysaltfiles WHERE dbid = 1 AND fileid = 1

After executing the query, on my local machine the value of @device_directory is ‘C:Program FilesMicrosoft SQL ServerMSSQL.3MSSQLDATA’

The variable can then be used when creating the files, for example filegroups for your database.

EXECUTE (N’CREATE DATABASE Northwind
  ON PRIMARY (NAME = N”Northwind”, FILENAME = N”’ + @device_directory + N’northwnd.mdf”)
  LOG ON (NAME = N”Northwind_log”,  FILENAME = N”’ + @device_directory + N’northwnd.ldf”)’)
go

Unable to access or ping Windows 2008 server

After being bitten by this for the second time, I thought I should write a post for future reference. I had setup a brand new virtual machine and I wanted to access the SQL Server 2008 instance. Because of the firewall built into Windows all external connections are blocked – this means I cannot ping the machine, let along connect to the SQL Server instance running.

image

Disabling the firewall isn’t a problem, in the control panel you simply set the option.

image

Generally, this solves the problem. However, after doing this on 2008, I still couldn’t ping the machine.  After paying a bit more close attention, I found that the Windows 2008 Firewall has different profiles, each with their own firewall setting. While I had disabled the firewall for the domain, public and private where still active and blocking my connection.

image

After disabling the firewall on both of those profiles, I could happily ping the machine and connect to the SQL Server Instance running.

IronTwitter – Sending a tweet from the IronRuby REPL

In my previous post, I discussed how to parse XML from a REST service. As it happens, the REST service I was interested in was the Twitter API. My aim was to use IronRuby to update my Twitter status from the REPL (Read-eval-print loop) – the interactive console. The result is IronTwitter 🙂

While I’m no expert on REST, I understand that you simply ping a URL with a correctly formed URL and process the response in the correct format (xml, json etc).

One of the great things about IronRuby is the REPL, this is the ir.exe console application and allows you to interact with the language and .net at runtime, they are very simple – type a line, hit enter and the line is executed.  They are great for executing quick lines of code, or learning how do a task in the language. I used the REPL a lot while creating the XML parser as I could easily modify the code dynamically to see if something worked as I expected.

Interacting with IronTwitter

Interacting with IronTwitter is very easy. First you need to reference the library.

require ‘IronTwitter’

You then need to construct the object, providing your username and password

@twitter = IronTwitter.new ‘username’, ‘password’

The IronTwitter object has a method called update which has a parameter for your new status. Under the covers, it calls the API and updates your status. However, in order to make this easier to type, I added an alias for the method called t. To update your status, you simply type.

@twitter.t “Hello from IronTwitter!”

This will send a request to ‘http://twitter.com/statuses/update.xml?status=Hello from IronTwitter!’ and your twitter status will be updated.

We can now start taking advantage of IronRuby and we can start constructing tweets dynamically!  For example, if we had a method which counted all the files and directories, we could tweet the result.

def count(dir)
   num = 1
   Dir[dir + ‘/*’].each do |d|
     if File.file? d
       num = num + 1
     else
       num = num + count(d)
     end
   end
   return num
end

All we would need to do is call the method and join the response onto the string argument for the method.

twitter.t ‘The number of files currently in %TEMP% is ‘ + count(‘C:/Users/BENHAL~1/AppData/Local/Temp’).to_s

While this isn’t the most interesting tweet, it’s an interesting concept. You can see my various test tweets at http://twitter.com/ben_hall_test, note my main twitter account is http://twitter.com/ben_hall.

image

After being able to send a tweet, I wanted to see how to process the response. The API has a FriendsTimeline method, this will return the timeline you see on your twitter homepage, the tweets of you and the people your following. Using my xml wrapper, when you call the method friends_timeline, you then use a block to process each status, which is a monkey patched XmlElement object from the Xml Parser I created.

>>> @twitter.friends_timeline {|status| puts status.get(‘text’)}
Hello from IronTwitter!
…..

Under the covers of IronTwitter

While that is very interesting, what happens under the covers is more relevant. When dealing with the API, there are two important items, the first is the url, the second is the options. For update, I send a request to ‘statuses/update.xml’ with a parameter status containing my message.

def update(msg)
  url = “
http://twitter.com/statuses/update.xml”
  options = { :status => msg }
  send_request url, options
end
alias :t :update

This is then passed into my send_request method, this uses the WebRequest object from System.Net to send the correctly formatted request.

def send_request(url, options)
  requestUrl = convert url, options
  request = WebRequest.Create(requestUrl)
  request.Method = “POST”;
  request.ContentType=”application/x-www-form-urlencoded”;
  request.ContentLength = 0;
  request.UserAgent = “IronTwitter”
  request.Credentials = NetworkCredential.new(@username, @password)

  @response = request.GetResponse
end

The URL which is requested looks like this. As we use HTTPAuth, your status is updated.

http://twitter.com/statuses/update.xml?status=Hello from IronTwitter!

A similar approach is taken when it comes to the friends timeline.  First, I’ve used an optional parameter so you can define the limit of statuses returned – by default it is 20. The method then takes a block, this is used to process the request.  If a block is not provided, I raise an exception. I then use the Xml Parser I created to start processing the xml response.

def friends_timeline(tweetCount=20, &b) 
  url = “http://twitter.com/statuses/friends_timeline.xml”
  options = { :count => tweetCount }
  send_request url, options

  readStream = System::IO::StreamReader.new(@response.GetResponseStream)
  doc = Document.new(readStream.read_to_end)
  if block_given?
    doc.elements(‘statuses/status’) do |status|
        b.call status
    end
  else
    raise ‘Block required for processing statuses’
  end
end

From the calling code, I simply access the elements on the node and output them to the screen.

twitter.friends_timeline do |status|
      status.node(‘user’) {|u| print u.get(‘name’) }
      print ‘    ‘
      puts status.get(‘text’)
end

The name and the status of the user is then sent to the console, the result being this:

E:IronTwitter>ir sample.rb
Ben Hall    This is a test tweet

Download the code and sample from here. I’ve also uploaded the code to the MSDN Code Gallery

Technorati Tags: ,