Wednesday, June 25, 2008

The beast has arrived

The Mac Pro arrived yesterday, I am excited, unfortunately i have zero time to play with it as my social calendar is full (What?!? A nerd with a life?!?!) .
So it looks like next Tuesday will be the earliest opportuinity for me to kick the tyres.
In saying that, it does look pretty sweet on the desk... right next to an identical one (my flat mate and i got matching machines and monitors... cute :-p )

Bring on next week!

Thursday, June 19, 2008

Alt.Net Beers

Cheers to the lads (and ladettes) last night for the drinks... much nerd was talked and laptops compared!
Look fwd to next one!

here for photos

Wednesday, June 18, 2008

Repository vs DAO

I am coming to the end of one project and am the prelim stages of another and am trying to get a nice easy to understand architecture that can be clearly explained to new comers. I have come into one issue that I have never really worried about before, however curiosity has got the better of me. It’s the issue of Repositories vs DOA’s.

From my reading around the most logical version that A) makes sense and b) highlight why people don’t really worry about the difference is shown below:

Valid
CustomerRepository : ICustomerRepository //This just passes calls straight through to the DAO

CustomerDAO : ICustomerRepository, ICustomerDAO

OR (more appropriate and most common)
CustomerDAO : ICustomerRepository, ICustomerDAO

Not Valid
CustomerRepository : ICustomerRepository, ICustomerDAO //This concrete class should not exist, shift the ICustomerRepository to the CustomerDAO

CustomerDAO : ICustomerDAO

Often a repository tier will not be used in an application stack as there is no added benefit in the extra level of indirection. However when the IFooRepository start to allow the “creeping in” of the underlying persistence framework then its time to refactor the IFooRepository and separate it out to a separate concrete class and allow the IFooDao deal with the specific persistence issues.

The repository methods should be very generic and as Fabio Kung puts it:

  • Repositories are domain objects, daos aren’t.

So when would repositories be there own concrete class? When IFooRepository != IFooDao. Separate out the repository from the DAO, its just that it rarely happens and if it does probably has not warranted the effort to separate.

For more see:
http://fabiokung.com/2007/11/12/comments-to-gavin-king-about-ddd-and-repositories/

if(J.Miller != A.Lincoln)

A quote used by Jeremy Miller, which is somewhat poignant at this moment in time for me:
“If I had eight hours to chop down a tree, I'd spend six hours sharpening my axe”

Monday, June 16, 2008

New Development Machine Is Ordered

With a large gulp I have ordered what will hopefully be my work machine for the next few years.
Arriving some time this week is a new Mac Pro 8 core (2.8Ghz), 10GB Ram, 1.5TB HDD, 2 x 23' Screens with a bunch of lovely little extras such as Vista 64 pre-installed with boot camp access.

I must say i am looking fwd to ripping open those boxes, but somewhat nervous too.. i have never have a Mac (does an Apple II Gs from 91 count?) and i have never made full use of Virtual machines at home. My confidence is increased with the glowing reports of VM ware fusion product and the fact the Vista 64 issues on macs seemed to have settled.

I am also going to use this as an opportunity to venture out of the snug M$ world I have been sheltered in and play more with Java, Ruby, Python as well as the Nix operating systems that i have never really got my hands dirty with, particularly Ubuntu.

First thing I'll be buying once it lands is VM-Ware Fusion and then start setting up my various virtual machines. I am thinking of keeping quite distinct environments such as a Vista and Server 2008 dev environment, OSx Dev Environment, Ubuntu dev environment and a music environment (for recording) on OSx. I may even push a virtual copy of my existing physical machine up. Why not? I think i'll have the space!

Now all I need is a desk to put all this on... this is my first non latop in over 5 years!

Thursday, June 12, 2008

Solution Genrating and creating your own VS Sln files

Recently I have started building my own solution generator to create all the basic stuff that I just want done before I even really start coding.
The generally idea is that I can get a basic working concept application or web site up and running quickly that still follows the basic architecture that I will implement.
As most of the applications I have built in the last few years have been NHibernate based and I follow a similar standard for them why not generate the majority of the code to get me started. Whether I use all the code is irrelevant, its a starting point and saves a lot of start up time.
I have basic table structures that I use such as Customer, Orders etc so I can use those and generate from there and I have a decent size core library for DAL and non functional aspect based stuff.
One little problem I have run into is that VS sln files are not the basic text files they appear to be. The leading characters as well as the first couple of lines dictate the version of VS that they will run under. Get it wrong and VS wont even open the files. For example the leading bytes for vs2005 (followed by the leading few lines) are:

[byte 239, byte 187, byte 191]
[\r\n or byte 13, byte 10]
Microsoft Visual Studio Solution File, Format Version 9.00
# Visual Studio 2005


Otherwise, mostly the project is coming on ok. I think this is going to be a very handy tool in the coming months, where is seem to have a lot of greenfield projects on the horizon.

Wednesday, June 11, 2008

Less Documentation :(

http://blogs.msdn.com/codeplex/archive/2008/06/06/removal-of-sandcastle-project.aspx

Looks like Sandcastle is gone... hopefully not for long.
M$ feel it is not appropriate to have SC on CodePlex as its source code is not up and CodePlex is an OSS site/repository.... so fair enough, hopefully they find another more suitable place for it and dont keep it a secret.

NB: There are some links for the last release on the link above.

SQL code completion

I am an intellisense addict… I need it..it’s like my crack. I work faster on it and am grumpy when I don’t have it. So needless to say I was pretty excited when I saw
http://www.red-gate.com/products/SQL_Prompt/index.htm?gclid=CLKutfCP7JMCFQJtFQod_hn5Vw

Not having R# at work annoys the living daylights out of me. In 3 hours at home I can do the same amount of work I can do in a whole day in the office (it helps the requirements are a little more fixed)
In saying that, differently implementations of code completion also pisses me off. I love having the help in PL/SQL but I want to use tab for code completion not forced to use Enter… finicky? Yeah… but I switch between IDEs often during the day...

Monday, June 2, 2008

Classic one liner

On the subject of : Creation of Software vs Maintenance of Software in .Net
Scott Bellware is talking about how it is easy to create stuff in .net (such as drag and drop etc) and that developers like creating stuff, but the real issues are in maintenance, to which Ted interjects:
“Sounds kinda like having kids, the moment of creation is short and pleasurable and then you have 18 year of maintenance”

-Ted Neward; classic

Here the show here