Friday, June 30, 2006

I’m Going to France

Since it looks like just about everybody is going to be thrown out of the Tour, I’m going to catch a redeye over there and do my part. I don’t need drugs, just an ample supply of Clif Bars.

Thursday, June 29, 2006

More Impressions

My tour of the Microsoft language/tool suite has been continuing nonstop. While I have many more thoughts about C# at this point I figured I’d take a minute to talk about the tools. Like many other people with a Unix background, I’ve spent most of my time with Emacs and make. Only in the past year did I spend significant time with Eclipse when I worked on a Java project. I was extremely impressed with Eclipse and was expecting the same from Visual Studio.

Unfortunately I have been a bit disappointed. I want to be fair and say that I believe Visual Studio is a far bigger and probably better product. My experience is limited to working with Visual C# and comparing that with writing Java with Eclipse. Anyway, I struggled for a long time to find some of the features I was used to in Eclipse and have learned that in some cases they simply aren’t there.

Two that come to mind are “organize imports” and incremental builds. In Eclipse you can simply write code and then hit the organize imports command to have all of the correct import statements added to your code. It is even smart enough to remove import statements if they are no longer necessary. There is no equivalent in Visual Studio. Sure, it has ways to auto resolve types and add the proper using statements, but the functionality is not as slick as that in Eclipse.

I’m still struggling with not having my IDE continuously building my project. In Eclipse I could just write code and instantly know what compiled and what didn’t. In VS I actually have to click Build to get the results. IMO, this has noticeable lengthened the build/compile/test cycle.

I won’t even start on the lack of refactoring tools. Anyway, all is not lost. I figured Visual Studio is a great product and I must be missing something, so I picked up a copy of Visual Studio Hacks and starting poking around the web. The good news is that by adding several plug-ins I was able to reclaim much of this functionality, save the incremental builds. I’m still learning my way around and I’m sure I’ll find more goodies in my exploration.

On the plus side, it is a very stable/fast product. Eclipse was a bit slow and prone to strange bugs. I have encountered nothing like that with Visual Studio. It is always very snappy and I can leave it running for days with no trouble. Now if only my fingers would adjust to the Windows keybindings….

Monday, June 12, 2006

First impressions of C#/.NET

Now that I've been messing around with C# for a couple of weeks I figured it is time to report on some initial impressions. Today's topic: web services. The quicky summary is that I'm very impressed with the ease of putting together both a simple web service and client.

Writing a class which exposes methods via web service is just like writing any other class. The only difference is that you mark the methods you want exposed using the [WebMethod] attribute. For example, let's start with a very simple, classic example:


public class HelloWorld
{

public Service () {
}

public string HelloWorld()
{
return "Hello World!!";
}
}


To turn this into a service, you only need to make a few changes:


public class Service : System.Web.Services.WebService
{

public Service () {
}

[WebMethod]
public string HelloWorld()
{
return "Hello World!!";
}
}


The rest is taken care of for you, including generation of the WSDL. I come from a world where you start writing the WSDL by hand and then use it to generate stubs for your service code. Believe me, building services this way is a huge relief.

Now, coming from an environment like Amazon makes you immediately skeptical of anything this automated. You start to wonder if it can really perform and how hard it will be to do anything "outside the box". I'll be honest, at this point I don't know the answers. I do know that I was able to get a service running in about 30 minutes, which is a huge productivity win even if I have to get more hands on later in the development process.

What about the client? Writing the code to call the service is just as simple. Once you have your WSDL generated, you can just point one of the provided tools at it to generate your client code. Out of the box you get a client library that can call the service both synchronously and asyncrhonously. Nice.

Wednesday, June 07, 2006

New Commute

Now that I've settled in a bit, I've started bike commuting to Microsoft. All I have to say is... Wow! My commute distance when from 20 miles to 11 and is on much safer, more attractive roads. Yesterday's ride in took 35 minutes, which is about the same time it takes in a car. Of course my commute to Amazon, at 1:15 was better for training, but this fits in with life so much better. I can always make it longer if I really want to.

Friday, June 02, 2006

Day 2.2+

Grumble.. Blogger totally ate my last post so I'm going to make this one quick.

I'm pretty well settled at this point. The second day included another half day of orientation and then I made my way over to my office. Waiting for me was a very nice Dell system (2 dual core processors) which I spent the remainder of the day configuring.

I wasn't brave enough to install Vista, but I did install the Office 2007 beta and have been enjoying it so far. My officemate pointed out that I installed Office before Visual Studio. That could be a bad sign.

I did in fact install Visual Studio and even took a minute to write my first C# program. I'll let you guess what that was...