I'm currently watching the Channel 9 video about WinFS, and I'm using this post to keep track of the questions & thoughts I've while seeing it:

One big one is the ability to delete a file while someone is holding it open. NTFS doesn't allow it, but most of the Linux file system does. The issue here is the ability to upgrade core components without rebooting. If WinFS would make it possible to delete a file while some program is using it, the reasons for reboots would suddenly drop sharply.

What happen if I've a relationship between files and I copy the set of file to a non-winfs medium (ftp, zip, cd, etc) and then I copy it back to a winfs medium, what happen to the relationships, the meta data? From the video it looks like it should work.

I've been voted as a commiter for the Castle Project. You might recall how excited how I was when a patch I made was accepted for Catle, so you can imagine how I feel right now about it. :-D

Along with this there is another big issue: Brail has been accepted into Castle's MonoRail and will now be available as part of their services. So I would finally have a public Subversion server that I can point people to.

I'm going to update everything in the site and upload the repository tomorrow. I want to add some more usability features. Specifically, it's the Brail pre processor that worries me. It's too strict. I'm not sure how to solve this problem, but I'll give it some thought.

I updated NQA today with some bug fixes. Spesifically, it's solved Bug #48 (System.ArgumentException:
'null' is not a valid value for 'stream'.) and preserving stability in
the face of some really funky queries.

A few days ago I noticed a sudden spike in the traffic to the site, attributed to MSN Bot going crazy and hitting my site thousands of times. It's still in the range of hundreds right now. I know that others have noticed the same.

What is interesting is that it seems that I can now find things on MSN that I can't on Google.

Working Effectively with Legacy Code is
a book that should be a mandatory reading for anyone who is interested
in coding for a living. I don't deal with many legacy systems at the
present (except for NQA, of course :-) ) and still this book has
been a fountain of knowledge about techniques, tips and tricks.

This is not a book about pretty code, it's a book about ugly code and
all the myrad ways you can abuse design pricipals and good coding
practices. What it does is show a set to systematically take a legacy
code* and break down the dependencies so you can write tests for the
code. The moment you've tests, you can move forward. Until you've
tests, you're in a position where all you can do is "Edit & Pray"
or... you can write tests.

I've had recent experiance with
developing applications in a TDD from the start (Rhino Mocks) and
converting a legacy application to TDD (NQA). I can't rave enough about
how much easier it is to make a change in Rhino Mocks because of those
tests. When I adapted Rhino Mocks to run on .Net 2.0 I'd broken just
about every part of the application because I didn't consider what the
change from Hashtable to Dictionary<T> would do when there is no
item in the dictionary. Because I'd tests, it was literaly the work of
a minute to find the problem and fix it.

One thing to note about this book, it took me over two months to read it. Like Xp Explained 2nd Ed. I
just can't seem to read it for any length of time without starting to
feel a sudden need to code something. Very productive for my projects,
less so for my reading backlog.

This is the recommended approach from the log4net documentation, and it makes sense, this way, if you don't enable logging, you don't pay for any string concentration. But it's very tedious to do so over and over again. I really wanted a clean way to do it, but at the time Boo's macros were far beyond my capabilities. Even for such a simple task.

Fast forward to the present....

Now I have no difficulities writing this, in fact, the entire utility was developed in one session in Notepad (the way real programmers do it :-) ). What is interesting is that in the meantime I had no education in compilers, AST, etc. I just came back to the subject and it suddenly made sense. It happened to me before in many situations, but this is the first that I can actually find a documented proof of that.

I remember in high school I was unabled to grasp the idea of dynamic memory (on my defense, I didn't try very hard), that was on Pascal with ^ going all over the place. Six months later, I was a triple star programmer (and proud of it :-) ) in C. Again, nothing much has changed, except maybe that this time I was more willing to learn.

Anyway, here is the code, less than 60 lines of code, and I found it useful in reducing common repetitive statements.

"""

This macros allows a convenient way to log properly, without getting tired by writing logger.IsXXXEnabled all the time. The macros depend on a ILog field/local named logger being present, this you've to define yourself.

"""

namespace log4net

import System

import Boo.Lang.Compiler

import Boo.Lang.Compiler.Ast

class LogdbgMacro(AbstractAstMacro):

"""

Logs a debug message if debug messages logging are enabled.

Usage: logdbg "message" [exception]

"""

override def Expand(macro as MacroStatement):

return GenerateStatement("Debug", macro)

class LogwarnMacro(AbstractAstMacro):

"""

Logs a warning message if warning messages are enabled enabled.

Usage: logwarn "warning" [exception]

"""

override def Expand(macro as MacroStatement):

return GenerateStatement("Warn", macro)

class LogerrorMacro(AbstractAstMacro):

"""

Logs an error message if error logging is enabled

Usage: logerror "error" [exception]

"""

override def Expand(macro as MacroStatement):

return GenerateStatement("Error", macro)

class LogfatalMacro(AbstractAstMacro):

"""

Logs a fatal error message if fatal error logging is enabled

Usage: logfatal "fatal error" [exception]

"""

override def Expand(macro as MacroStatement):

return GenerateStatement("Fatal", macro)

class LogInfoMacro(AbstractAstMacro):

"""

Logs an informative message if informative messages logging is enabled.