Cook Computing

COM Was Love

December 4, 2002 Written by Charles Cook Inside OLE 2

Clemens Vasters gets nostalgic about COM. I too remember the excitement. Unlike the launch of .NET where we have all been submerged by countless books and articles, Kraig Brocksmidt's Inside OLE was about all we had to work with. Unfortunately the underlying simplicity of COM was hidden by the emphasis on OLE and people would say things like "Its takes 6 months before you understand OLE and can do anything useful with it". I recall being particularly enthusiastic about monikers, which seemed an all-powerful concept, although in the end I never did much with them.

My first misgivings about COM arose when I discovered that it was not possible to configure timeouts in DCOM. This was particularly harmful to a design I worked on which used a client-side broker to locate COM objects from one of multiple servers: we couldn't expect end-users to wait a couple of minutes while a request to a non-running server timed out. I spent a lot of time devising a proprietary solution which did not involve spinning off multiple threads. This problem was made even more frustrating because Microsoft did not seem willing to understand the importance of timeouts in client software, not just in DCOM, for example Outlook until recent versions used to hang for a very long time and often fail to recover if the network connection went down.

The final blow to my relationship with COM was Windows 2000. DCOM had become quite usable under NT and then it all fell to pieces. I guess all the good engineers were already working on .NET and Microsoft used some interns to port DCOM to Windows 2000. Several service packs later the damage is just about repaired but it caused us a lot of extra work and hassle with customers.