November 2009 Entries

Command Line Parsing on Windows with Mono.Options

When you have command line arguments to parse (whether on Windows or Linux), the place to look is Mono.Options. To date, I have not found anything better to get the job done. It is a single C# file if you do not want to download the entire Mono Library to use it. I was first introduced in Mono 2.2. The equivalent product is NDesk.Options by Jonathan Pryor. His single Options.cs file has been implemented as Mono.Options. To demonstrate how easy command line parsing can be, I’m going to show you is ......

Turning a New Leaf

public class DevliciousBlog { IBlogger _blogger; public Devlicious(IBlogger blogger) { _blogger = blogger; } } public class Program { private static void Main(string[] args) { IBlogger rob = new FerventCoder(); DevliciousBlog devlicious = new DevliciousBlog(rob); //awesome follows } } This is not goodbye by any means. Just another opening in my life. I was recently accepted to blog at Devlicio.us. Devlicio.us is a great community and is full of some top notch folks and I look forward to the opportunity ......

RoundhousE: Version Your Database

Versioning your database is as important as versioning your code. How much time do we waste currently before we are even productive when we have to fix or enhance something in a database? RoundhousE versions your database how you want. The recommended way is to version based on source control, but that may not be your solution. But for a moment let’s pretend it is. Why would versioning your database based on source control be a big help? What happens if you get a prod fix (or work order) to fix a ......

NHibernate Event Listener Registration With Fluent NHibernate

I’m a huge fan of NHibernate. It has excellent documentation and just makes the whole job of getting things into and out of the database much more enjoyable. There is a whole series of posts on NHibernate from one of the committers, Ayende. When Fluent NHibernate (FNH) came out, it was like butter on sliced bread. FNH makes it even easier to use NHibernate. Ayende had a post a while back on how to use Event Listeners. That helped me to get to event listeners set up. Event Listeners namespace somethingimportant.we.hope.... ......

RoundhousE: Configuration

This week I introduced RoundhousE and it’s getting quite a stir. Let’s take a look at the configuration. We are going to focus on the MSBuild/NAnt task configuration for now because the console isn’t yet complete. The console will actually have at least this much if not more (we’ve talked about how to use it to create the migration scripts and not just run them). Because we like to be able to infer things, we have determined that there are only two required items. Thus – the minimal configuration: ......

RoundhousE DB Migration: Action Shots

I just started the appetites with my last post on RoundhousE. RoundhousE itself has a migration sample to help you get familiar with how it works. You can get to that by using a subversion client to download the source. When you download the RoundhousE source from SVN and run build.bat, you get a code_drop folder. Go in there and look at the deployment folder for a sample run. Prerequisites: Locally installed (and running) SQL Server 2008 Run That Bad Boy When you get into the code_drop folder, take ......

Blogging about Blogging: Most popular topic on GWB!

Right now my post on Sproc Executing Slow is the most popular topic on GWB ......

Enter The Dragon: RoundhousE DB Migrations

One of the coolest projects I have been working on is how to solve issues with database versioning and migration. A project dubbed RoundhousE. RoundhousE is an open source automated database deployment (change management) system that allows you to use your current idioms and gain much more. Currently it only supports Microsoft SQL Server, but there are future plans for other databases. It seeks to solve both maintenance concerns and ease of deployment. We follow some of the same idioms as other database ......

Afterthoughts From Iowa Code Camp and UppercuT Talk

Iowa Code Camp was a great time! I really enjoyed the conference itself. It was probably one of the best conferences I have ever been to. There are a lot of talented people surrounding Iowa and I had the pleasure of hanging out with some very intelligent people that are doing some really awesome things. The talk went well as well. Hopefully there were a few more people that got out there and tried UppercuT. Here are the slides from my talk ......

Sproc Executing Slow? It Might be This

So you have stored procedure and it’s having issues. When you run it, it returns really fast. When .NET runs it, its like a dog. The first thing you learn about SQL Server is that it has something called ARITHABORT and it is turned on in SQL Management Studio and OFF in ADO.NET. Yeah you heard that right. OFF. So when you find this out, your first thought is WTF, mate?! Why do we have to make this hard on ourselves? Reference post: http://sqladvice.com/blogs/... ......

Speaking At IowaCodeCamp

If you are in Des Moines, IA, tomorrow for Iowa Code Camp, I’m speaking on “Automated Builds: How to UppercuT your Code” at 3:45. If you are going to be there and we’ve only met on Twitter before, I’m looking forward to meeting you ......