Development comments edit
If you really want to take control of your ASP.NET routes to create a RESTful or at least RESTish URL naming scheme, first you need to let go of default MVC convention-based routes (Controller/Action/{id}) and use something like AttributeRouting. (AR is now half-baked into MVC 5, unfortunately without some of the more useful things AttributeRouting has to offer, like the ~/routes.axd route debugging handler.) In any case, once you use either method of getting attribute routes, you’re now faced with how to integrate that data in your controllers. The first step is to put a RoutePrefix attribute on your controllers, but then to get that data out, you have to scrape the data out of the RouteData manually within your action method, or override OnActionExecuting to do the same except drop the values in an instance variable.

Read more →

Development comments edit
Recently a colleague referred me to a video from Marius Gunderson’s session at JSConf EU 2013 entitled A comparison of the two-way binding in AngularJS, EmberJS and KnockoutJS. It’s an excellent watch, comparing and contrasting the two-way databinding capabilities of each product without descending into a flame war about which is better, and it only weighs in at 20 minutes long. Here’s the video itself.

Read more →

Development comments edit

I presented an introduction to Service Oriented Architecture at Twin Cities Code Camp over the weekend, and unfortunately hit a little bit of a snag during one one of the demos, so unfortunately while the audience got to see all the code that makes Publish/Subscribe work in NServiceBus, they didn’t get to see it actually, you know, work. Such is the risk of a live demo. (Even if you test it the day before, which I did!)

This morning I was able to take a closer look at the error message and figure out what is going on. I’m currently starting a project using RavenDB so the first thing I did was to upgrade RavenDB to the latest stable version, 2.5 Build 2700.

Ummmmm….shouldn’t have done that.

A license for NServiceBus (including the developer license you get for free from the NServiceBus website) covers your use of RavenDB to handle NServiceBus related storage, for subscriptions, sagas, timeouts, and a few other things that are handled by the NServiceBus framework. If you want to use Raven for your own application (which I would highly recommend) you need a separate license for that in production.

For development where Raven isn’t really licensed anyway, I didn’t think it would matter that much, but I was wrong.

Raven.Abstractions.Exceptions.OperationVetoedException: PUT vetoed by Raven.Database.Server.Security.Triggers.WindowsAuthPutTrigger because: Cannot setup Windows Authentication without a valid commercial license.

Oops! NServiceBus V4 uses Raven 2.0 and hasn’t been tested with 2.5 yet. So what to do if you want to develop solutions with both simultaneously? First, allow NServiceBus to install RavenDB 2.0 on port 8080 as is the default. Then, if you want to develop with RavenDB 2.5 as well, install that to port 8081. In my opinion it’s easier to set the nonstandard port on your DocumentStore’s URL (which you have to set anyway) than to modify the NServiceBus conventions that (while they are overridable) expect to see RavenDB 2.0 living on port 8080.

Development comments edit

I will be presenting an Introduction to Service Oriented Architecture, featuring NServiceBus, at the Twin Cities Code Camp 15 this weekend. The code camp is on the University of Minnesota campus so if you’re in the area, I would highly encourage you to come out and see me as well as some other awesome presentations. I will be speaking at 12:45 in room 3-180. Personally I’m really looking forward to seeing Judah Himango, the brains behind the new HTML 5 version of the RavenDB Management Studio, speak about TypeScript. Of course the code camp is entirely free, and I think you can still register.

As a bonus, I’ll be giving away a free hardcopy of my book, Learning NServiceBus, during my session!

I hope to see you there!

Development comments edit

Well Christopher Columbus was kind of an all around poor example of a human being, but the upside is that my publisher is running a pretty awesome sale on all of their eBooks, including my book, Learning NServiceBus. Anyone who uses the promotional code COL50 at checkout will get 50% off any eBooks or videos. That’s a pretty good deal. Aside from my book, I would also strongly recommend RavenDB 2.x Beginner’s Guide by Khaled Tannir, and RavenDB High Performance by Brian Ritchie.

Columbus Day Sale

The sale has been extended until Monday, October 21, so get your order in now!

Development comments edit

I’m really thrilled that my book has finally been published. I really love NServiceBus and so writing the book was a labor of love.

What’s even more exciting is that, thanks to my publisher Packt, 5 lucky winners stand a chance to win digital copies of my book for free!

How to enter?

All you need to do is go to Packt’s Learning NServiceBus book page, look through the product description, table of contents, etc. and then leave a comment on this blog post to let us know what interests you the most about this book. Not rocket science. Packt will select the 5 best comments, and those people will receive a digital copy of the book for free!


You have until Saturday, September 21, 2013 at midnight UTC (that’s after Friday is done, or 2013-09-21T00:00:00Z) to enter the contest. The winners will be contacted by Packt via email, so be sure your comment includes a real email address where they can reach you.

Thanks and I hope you enjoy the book!


The contest is officially over. Thanks everyone for your entries! Here are the winners:

  • Geert Depickere
  • Adrian Thompson Phillips
  • afifmohammed
  • Guillem Sola
  • Megadesty

Packt will be contacting you soon to deliver your free digital copy. Congratulations!

For everyone else who did not win, or if you would like a physical copy, you can buy the book from Packt, Amazon, Amazon UK, or Barnes & Noble.

Technology comments edit

About two months ago, I received a very exciting email. “Your Pebble has shipped!” it proclaimed, and on June 10, my gray Pebble finally arrived after months of waiting. Unboxing videos are all well and good, but this week marks 60 days since the Pebble first hit my wrist. It’s no longer a new thing, and instead just a thing, and so I thought this would be a good time to share my thoughts about the device.

Read more →

Development comments edit

The NServiceBus Host process is a pretty amazing piece of software that hosts your message handlers, can be run from the command line or installed as a Windows service, and is supremely extensible. This is a great strength for NServiceBus but it can also be a little overwhelming for the developer just starting to wade into the great pool of service bus logistics.

Much of how an endpoint will configure itself is based on Profiles and Roles:

  • Profile – controls the environment and features the endpoint is supposed to run with. These are set at the command line by passing the class name (or names) of the desired profile (or profiles) like “NServiceBus.Host.exe NServiceBus.Integration”. Because this is set at run-time, this allows the same collection of code to run in different configurations depending on environment.
  • Role – controls what services the endpoint will need based on how it will interact with other services. There are 3 defined roles: AsA_Client, AsA_Server, and AsA_Publisher, and these are set in code, so these are static for an endpoint.

In this blog post I will try to spell out everything that these profiles and roles do, based on my experience and source code snooping with Reflector. Use this as a quick reference so you don’t have to go hunting through reflected source yourself.

Read more →

Development comments edit

Visual Studio 2010 added the ability to add transform files to web.config files so that you could have one combination of settings during development, and then another set when deploying to different environments with the Publish Website tool.

This is immensely powerful, allowing obvious things such as turning off debug mode for production builds, and changing database connection strings, but also more subtle ones like ensuring that QA people banging against new code don't unknowingly send a bunch of test emails to people who will not be interested in non-production data.

This means that there is really ZERO excuse for saying something like "So how you deploy this app is you build it locally and then you copy over everything except the Web.config file." No, that is not OK. That will definitely result in a bad build at some point in the future. But unfortunately, I worked on a project where I heard exactly that sentence.

Read more →

Development comments edit

Recently Charlie Barker (@Porkstone on Twitter) asked me what I felt were pros and cons of using RavenDB over a standard relational database. In this series of posts I highlight the differences between RavenDB and a RDBMS that I have experienced after completing three projects that incorporate Raven in some capacity.

Originally I wrote this series as 4 posts, after which my boss read the series and asked me a bunch of pointed and very interesting questions. These made me realize I forgot this very important advantage that Raven has over pretty much any relational database out there – searching!

Why did I forget about it? Because I was approaching the blog series from the perspective of things both Raven and a relational database do, and how they did them. But relational databases really don’t do searching, at least, not with the same level of basic competence that they store data. My last experience was with Microsoft SQL Server Full Text Search and it wasn’t fun. If you’ve tried, you probably know what I’m talking about. If not, you don’t have to take my word for it – take it from these guys instead.

Read more →