The .NET Sweatshop

Working day and night to help .NET users get the most out of programming the coolest platform on the planet.

Wednesday, October 29, 2003


Viva la blocks. Another one is here!!! Everyone needs to monitor apps and there's a host of things to do: determine what info you want, design the event triggers, and make them available for analysis in an appropriate format. But building useful logging capabilities into applications can be a huge pain. To help provide effective event-capture for enterprise applications, PAG has designed the latest patterns & practices : the Logging Application Block. This block uses the Microsoft Enterprise Instrumentation Framework (EIF) and the Microsoft .NET Framework to help customers design instrumented applications. We've made sure that it's available to everyone as well--as opposed to the MSDN Universal subscribers. The link is on the block's home page. I really like the way this block turned out. I think the documentation is pretty good and our field members (who have been using our block for a month or so now) have been raving about it. The block includes event sinks for SQL Server, MSMQ, both Windows Event & Trace Logs and WMI. I know what you're asking: what about the Exception Management Block (EMAB, as well like to call it)? How does it relate? Well, this block provides all the functionality of the EMAB and more. Yes, I know the next question: some of you already deployed EMAB as part of their applications and may wonder how to move forward. Fortuntately, that's pretty well covered in the docs. Basically, the EMAB can use different publishers to raise exceptions to different sinks. Just raise the exception to EIF instead of a data store. Once EIF catches the exceptions, it pretty gets caught by the logging block, which can process the events. Since the EMAB's event sink was set in the config file, you don't even need to touch your app to use the logging block. Ahh, the beauty of config files. :)

Anyway, we've got more blocks out in the future. But we'll try not to deluge you like we did back in June. Enjoy this one. Kick the tires. Experiment with it. And if you like it, let the patterns & practices team know about it through the feedback alias...

Next blog--the PDC wrap up...


Tuesday, October 21, 2003


My code thinks in ink. Really. At Microsoft, they just had a competition for writing PowerToys for the TabletPC that thinks in ink. They plastered ads for the contest all over campus and they kept using the phrase "Does Your Code Think In Ink?" I admit it. I fell for it. But, I dragged my feet for the first few weeks of the contest. I was having a hard time figuring out an idea for what my Power Toy would do. I had a couple of cool ideas around collaborative messaging, but a lot of it had been done already. Besides, I think that ranks higher on the cool factor than the usefulness factor (and anything on a Tablet automatically qualifies as cool :>). So, I kept asking myself--why do I think a Tablet is so useful (see my previous post). And the main thing was that, much like the code I was asked to write, I think in ink. Whiteboard, notepads, whatever. When I want to give feedback on a document, I have a hard time using Word's reviewing feature. It's not that the feature isn't useful--I just prefer to mark a doc with an angry red pen. :> That's when it hit me on what to do. However, to not jinx my submission, I will save the details of my app for another entry. What I will tell you is one man's six-day journey through the world of C#. Not as a guy who does it for a living, but rather someone who understands enough to be dangerous but not enough to have the simple answers all in my head. From Sunday at 1pm to Friday at 11:59pm (the time of my submission), I spent every momentum not on campus thinking about, stressing about, and coding this app. I'd stay up late at night, I'd do it on the bus, etc. As I like to explain it to my wife when I get into this mindset and start fumbling everything else that loses focus, I was in "developer mode"....

So, what was my biggest frustration? I spent 2.5 days figuring out something that was eventually solved with 5 lines of code. ARGHH!!! Wanna hear something worse--it had nothing to do with ink. Double ARGHH! I was trying to launch the toy from IE and then have the app do some info sharing with IE. Now, the obvious avenues were cut off by security and I will NEVER argue against that. In fact, this was a tricky thing that I was asking to do. But the frustration came from sifting the web to find the information--even with the vaunted Google search engine. I know, I know. A guy that works for Microsoft and posts his product on MSDN shouldn't talk. But, to quote a former president, "I feel your pain". What was most frustrating was reading docs that were clearly out of date. I was finding approaches that were appropriate for IE 2.0. People need to stick and XML tag in HTML docs that provides the date the doc was generated. It wasn't until Wednesday night that I was able to start coding in ink. Fortunately, Thursday's baseball playoff Game 7 and the post-game buzz kept me awake and alive for a late night of coding (to answer the certain questions of that statement and make my tangential remark, [a] yes I can code and watch baseball at the same time and [b] I detest the Yankees and hate that they made another World Series and it broke my heart to see the Sox come that close, but that game is the reason why baseball is such a tremendous spectator sport. Who didn't get choked up watching the seeing Bret Boone watch his little brother accomplish something they'd probably acted out in their backyard for years). Anyway, thanks to a patient wife and Aaron Boone, I finished the app at 11:30pm on Friday night. I actually got virtually every feature in there, built the installer, and did some pretty extensive testing to prove the thing was tip top. So, let's review. In a project that really lasted ~130 hours, I spent 60 of it looking for one answer. Not coding. Not architecting. Not testing. Not deploying. Now you can take a shot at me and say it's my fault for not knowing when to cut my losses, but this app would've stunk without this feature (as you'll understand when I post the app explanation in a future blog). I guess the point I am laboring to make is that we really need to make the right answers consumable and readily available. In the tool? Perhaps (I'm a fan of Dynamic Help, but believe that's incrememental and takes a lot of hp when you're coding on a laptop). But cleaning out old irrlevant docs and archiving them where they belong--that'd make me happy. Little written in 1995 helps me today (I should know--I actually knew how to code somewhat proficiently back then before the MBA Gods had their way with me :>). Creating more intelligent search enginers and tagging docs intelligently. I know it's the dream of WinFS to make finding what you're looking for less challenging and I pray that WinFS can save the day. Cuz folks, not even the good folks at Google were able to save me...


Thursday, October 09, 2003


I got a TabletPC a couple of months ago. I had been begging for one for a long time. I love the ability to scribble down notes and keyboards do not support scribbling. I have to admit that when I finally got it, I was a little concerned I'd be disappointed. Y'know, it's like when you get really excited for that Christmas gift and by the time Christmas rolls around, your expectations are so high, there's no way the gift will meet it. Well, I have to say the Tablet achieved as expected and it changes a lot of the way I do things. I love it. I love being able to draw pictures, scribble to-do lists and meeting notes, and even do crossword puzzles on the computer. But the most interesting thing about it has been my ability to sell the idea to the technophobes. My bro, the doc, treats PCs the way a four-year treats asparagus (yuk!). Yes, when I was showing him my Tablet and talking about all the ways he could use it, you could see the skepticism and fear melting away. I started telling him about how he could completely transform his sports medicine clinic and by the end, he was completely sold. In fact, I was starting to dream about building the system for his company. Dozens of Tablets connected via a WLAN that enable easy info capture & sharing. I was also putting it in a student context about how note-taking and documentation annotations could totally increase student productivity and that got my wife (a former techie who's going to grad school for public affairs) on the bandwagon and thinking she needs one. I'm so proud to be part of a company that helped put this thing out. Of course, given my day-to-day work and how we speak of this thing called "smart client", I wonder how many of our enterprise customers realize the potential of this thing to be the next level of business. Probably not many--I feel like the leap forward on this product is more exciting for someone who doesn't like computers more than those who live on it. For those who live on it, it's a cool incremental increase. For those who don't, it breaks down the barrier of keyboards and mice that have scared off too many people. Of course, while the enterprise customer may not need it for its internal users, the enterprise that is trying to make a customer web experience more enjoyable could do themselves a huge favor by finding a way to build this in to their app. We've got the killer device--now, we need the killer app that goes with it...


Friday, October 03, 2003


OK, I spent a lot of time travelling over the past few weeks and I even planned to write an entry on one of my plane rides. But, I got carried away with my non-techie blog entry about the Orioles closing out the year (an off-line entry I still haven't posted :<) and never got around to that fun .NET stuff. Still, travelling out of the friendly (or sometimes, not so friendly) confines of Redmond enables me to see the world in a whole new light. You get away from the techie perspective and see the real world. My two main stops were to do some recruiting back at b-school in Philly and then swing up to Providence to see my technophobic 37-year old brother and recently initiated 74-year old father. I'll cover the latter visit another time, but the visit to business school was pretty interesting. I was there to seek out the hot talent that will be tomorrow's leaders at Microsoft. Whaton is a kick-ass school and I'm proud to be a grad. The amount of Type A's running around there is frightening. Going there was a little like a player going from college to the NFL. The game just speeds up like you are fast forwarding a VCR (or fast-forwarding a DVD player, if you are so technically inclined). This was my second time back to recruit and while the faces change, the spirit and attitudes remain the same. The job market isn't what it was three years ago when I was looking, but confidence helps in situations like these and most of these students are brimming with it. Of course, I feel funny when these people think I hold the key to their future at Microsoft and work hard to impress me. I prefer situations where I can get them excited about the company and just have an informal chat about the future of technology and the business opportunities there. So, while I was signed up to do the recruiting bit on Wednesday, I had a chat with a guy in the Tech Club about doing an informal talk on .NET the night before. No recruiting. No resumes. Just me up there on stage telling the world about Microsoft. I thought it might go for an hour. I'd give them the half-hour schpiel and then answer a few questions and call it a night. Plus, it started at 9pm and the e-mail to solicit the audience didn't go out until the night beforehand. I wasn't even sure if more than 3 people would attend...

Well, there must've been 25-30 people there and they were awesome. The audience was different than what I've become accustomed to (devs + architects), but that made the questions even more interesting. Some wanted to understand the technology a little deeper and I had to be careful how deep I went to avoid giving these guys the bends. I even started writing some C# code before realizing that if OOP is something VB guys are resisting, the MBA world probably isn't anxious for it either. Meanwhile, other people were trying to separate the hype from reality with web services and some of the other "next big things" that Microsoft, Sun, IBM, et al continually push. I was impressed to hear their skepticism and excited to tell them about what Microsoft has done and how much easier it is to make it real. In all, the session lasted over 2.5 hours and it touched on dozens of interesting questions. The main messages: web services are real, they are ready for deployment today, and the things you can do today are amazing. The next generation is just going to make it incredibly simpler. I was telling someone today that some of the future products of Microsoft will do for HST ("hoooking s--t together", the preferred acronym to EAI) what VS.NET did for web services. Make it real and change the game. I, for one, can't wait and I can't wait to make this talk again next year. That's why working for Microsoft is so great--there's always so much to look forward to and it never ends...


Home