Posts Tagged ‘Code Camp’

Code Camp!

Sunday, April 13th, 2008

Yesterday, I attended my first Code camp.  I thought it was great! Yes, semesters of lectures in college was a bit tiring, but now, I find I’m hungry for them, especially when it’s just a day. I work with some smart, nice people, but as I’m pretty much on my own in my technical area, I don’t really have any real mentors, and so learning has been kind of a do-it-yourself project. So these sort of events are doubly valuable.

I attended “A Gentle Introduction to Mocking” taught by Scott Allen, which was pretty good-I’ve done some experimentation on my own, so I was ready to hear more. And I really don’t have a C# mentor at work, so seeing someone else do it, and *how* they went though was really informative. Sometimes you pick up little things that they do as a matter of course that you just didn’t catch when walking through examples on your own. And there was a discussion on when to use mocks vs. stubs, which I found interesting. I also had some revelation about my code base at work. There are certain parts of the code base that I’ve never been sure of how to test, or even if it was possible, because they jump off to NH calls a lot. Amusingly, I was also unsure of when one would use DI, or an IoC container. At this talk I suddenly figured out that the way to test those classes is that LOTS of stuff that I hadn’t even considered a problem creating in place needs to be inserted with constructor injection, enough so that it would actually be pretty ridiculous to do by hand. and so, I apparently need a container.

I had originally planned to attend Jay Flowers’ talk on TDD, but as he couldn’t make it, Kevin Jones kinds stepped in for a review of C# 3.0 features. He was actually pretty negative about a fair number of them, and I have to say after reviewing them, I am a little skeptical about some of them as well. The “var” feature in particular seems a bit dubious to me. I mean, we’re dealing with a strongly-typed language here. Introducing something like that feels like inviting in the craziness of vbscript. Maybe I’m wrong, but I feel like opening that door is questionable. I mean it works for Ruby and Python, but but those languages work on the basis of trust-it’s a different philosophy, and I wonder whether mixing in duck typing (though once you assign, it’s actually strongly typed, so it’s hidden typing, not true duck typing as I understand it, at least) to a strongly typed language is really a good idea.

Next was Constructive Code reviews. I was actually hoping for a little more meat in terms of how to approach the code, what things to think about, possibly something involving walking through it with code snippets. It was more a review of the different levels of code review from desk check to a full formal process. Still informative, but maybe not as interesting for me as what I was envsioning.

Next, Michael Podwysocki reviewed Dependency Injection and Inversion of Control. Again, I’d done some review of this on my own, but it was great seeing someone else explain the idea, and then walk through how to actually do it. The lecture took on a lot of extra meaning since I had earlier seen how I could apply it to my current project (whether I actually will be able to reorganize things is a separate manner, but at least I see an application for DI) I’m looking forward to him putting his code up, so I can more closely go over what we did in the class. It was also interesting hearing about other frameworks. I’d also heard about Windsor quite a bit on Alt.Net, and heard mention of Unity and StructureMap and Spring, but hadn’t known there were many more than that. Anyway, very useful.

Lastly, I attended a talk on LINQ To SQL in an N-Tiered Application. I’m still mulling over the level of usefullness of Linq to SQL when there’s NHibernate which is so full-featured. However, the Linq syntax itself is very interesting, particularly as it’s compiled and understood by Intellisense, etc. If it was brought in to nHibernate, it could be a *very* nice third querying option to complement HQL and the criteria interface.

Afterwards, they gave away some swag. Yeah, I can’t complain how I did… got a copy of Vista. Could be very nice to set up for Parallels on a future Mac purchase? Then, some attendees headed over to a next door bar. As usual, some of the most value in the tech events comes from the conversations. Interesting, smart people. Almost enough to make me reconsider my opinion of the average .Net developer… but then I remembered that anyone who cares enough to use their own weekend time to go to a code camp is quite a bit different from the typical 80% of the developer population, so I was not dealing with a good cross section. heh.