shahine.com/omar/

homepage | Send mail to the author(s) contact

yet another Microsoft blogger

 Monday, August 22, 2005

FireAnt

FireAnt is a big deal for me. It’s the code name for the “plumbing” of Kahuna, the Hotmail Frontdoor rewrite. It’s one of the “Architecture” pieces that my team is responsible for helping build.

Last summer we spent a lot of time at the white-board evaluating a number of ways to deliver a new architecture for Hotmail. We considered a number of things:

  1. Modification of the current C/C++ ISAPI architecture to support a hybrid ASP model.
  2. .NET rewrite for the DataLayer and BusinessLayer and XML/XSLT for the PresentationLayer
  3. Same as #2 but the Presentation layer would be JavaScript, XMLHTTP, and DHTML/CSS. This now has the fancy name, AJAX.

After much deliberating, we chose #3, and started running. For 4 weeks basically 1 PM, a developer and an intern built a prototype, and then the real thing (in case you are in college I’d note how cool it is that we put an intern on the most important technology we we're building). As more people started to move over to the FireAnt project, we got more and more excited about what was happening. You see, writing AJAX code can be a pain, and we didn’t want to spend our days and nights writing a lot of JavaScript and debugging client side Script. Instead we built an infrastructure that dynamically take server side objects (classes and methods) and automatically generates client side JavaScript stubs. The end result is that the client side object model looked exactly like the server side object model. Information was transported across the wire using XMLHTTP and the whole thing happened Asynchronously.

We extended .NET Attributes to mark classes and methods as FireAnt classes/methods and at build time the script is generated. If you think of SOAP support in the .NET Framework, it’s basically similar. As a developer you do not worry about generating SOAP messages, or building a SOAP parser. All you do is mark your method as [WebMethod] and your classes as [Serializable] and the .NET framework takes care of proxying, class generation etc. That’s what we were shooting for.

This was a big deal for us as it allows us to be incredibly productive. Since last summer, we have built a ton of features using FireAnt and the JavaScript Frameworks from Scott Isaacs. Late last fall we went up to Redmond and showed FireAnt to a number of folks in MSN, one of those folks was Steve Rider. It was really exciting to see the looks on folks faces when Walter (our FireAnt “architect”) setup his “Hello World” demo. You could just see that people realized that doing AJAX style development any other way was crazy.

We’ve since showed our stuff to a number of teams inside Microsoft. As a result of our work, Walter and Scott have spent a considerable amount of time with the Whidbey/ASP.NET folks and it’s pretty exciting to see ATLAS come together. If you want to learn more, Walter will be giving a talk at the PDC on what we’ve built. It’s great so see collaboration between our team and the Developer Division as the end result will be a better more scalable version of the .NET Framework for you.

We also just wrapped up another Channel 9 video, with more folks than the last one. It should be a great video when Robert is done editing it.

 

Monday, August 22, 2005 9:54:26 PM (Pacific Standard Time, UTC-08:00)
Any way an MS Partner can get ahold of FireAnt? I am getting ready to start a big overhaul on our UI, and we are moving towards Ajax. I am hesitant to roll my own when I am hearing about how cool Atlas is, and now how cool FireAnt is.

Also curious...why go through the whole script generation thing, rather than just write everything as a web service, and then implement a javascript WSDL parser - like the old IE Web Service Behavior works?
Monday, August 22, 2005 10:05:10 PM (Pacific Standard Time, UTC-08:00)
You'll have to wait for ATLAS to get your hands on this.

We looked into WebServices. FireAnt methods are basically lightweight web services except no SOAP is used as that's fairly heavyweight. We just proxy JavaScript across the wire as it's tight and highy compressible and requires no client side libraries to unpackage it.
Tuesday, August 23, 2005 3:35:58 AM (Pacific Standard Time, UTC-08:00)
Can't wait to see the video, see it in action in the Hotmail Frontdoor rewrite and eventually get my hands on it.
Robert Banghart
Tuesday, August 23, 2005 5:01:36 AM (Pacific Standard Time, UTC-08:00)
Bryan, if you can't wait. I suggest you take a look at the free Ajax.NET library: http://ajax.schwarz-interactive.de

I've been using it for a few weeks, and it seems super simple to use. Like FireAnt, all you do is mark your method as an Ajax method, and it'll generate the appropriate JavaScript stubs for you and you just call the JavaScript. You can have your methods returning things such as DataTables, DataSets, int, string etc... You can even return your own custom data types if you write a custom object converter. In some ways, reading Omar's description of the FireAnt project, there seems to be a fair amount of similarity with this Ajax.NET library.
Tuesday, August 23, 2005 6:05:18 AM (Pacific Standard Time, UTC-08:00)
at least there is no ambiguity on the name ;)
Tuesday, August 23, 2005 5:00:29 PM (Pacific Standard Time, UTC-08:00)
Omar, would we see a detailed post / video (like the last one) from you as to how exactly you guys architected this. Are the server side objects datasets or custom classes and so forth ...

Thanks,
Vaibhav
Vaibhav Kamath
Tuesday, August 23, 2005 7:01:52 PM (Pacific Standard Time, UTC-08:00)
The video won't be that detailed, but the PDC talk should be. We did a mix of a lot of different things in the video.

We don't use any datasets that I know of. All our objects are custom classes. Our entire end to end system is and has to be asynchronous (data access layer and request/response mechanism).
Wednesday, August 24, 2005 10:17:48 AM (Pacific Standard Time, UTC-08:00)
So in fact you create classes which implement an IFireAnt interface, and with reflection you create the appropriate methods .. ?
M. Schopman
Wednesday, August 24, 2005 12:06:25 PM (Pacific Standard Time, UTC-08:00)
Sounds cool. Any idea when ATLAS is coming out?
Thursday, August 25, 2005 8:17:15 PM (Pacific Standard Time, UTC-08:00)
I hope you would blog after the PDC at least part of what gets said at the PDC for the rest of us.

Thanks,
Vaibhav
Vaibhav Kamath
Thursday, August 25, 2005 11:54:57 PM (Pacific Standard Time, UTC-08:00)
There is no IFireAnt interface. Classes/Methods marked with the attributes are created using reflection/codegen.
Comments are closed.