Expert Texture Home Contact me About Subscribe Digipede Connect on LinkedIn rwandering on Twitter rwandering on FriendFeed

rwandering.net

The blogged wandering of Robert W. Anderson

Archive for September, 2005

Tech @ PDC05

Microsoft is presenting on and / or announcing a lot of new technologies at PDC05 that are interesting for us:

Windows Communications Framework (was Indigo) The more integrated the communications services are with Windows and the more transports-independent they are, the better. I look forward to giving our customers more options on how our components communicate (regarding protocols, transport, and security) to best fit their specific operating environment. Of course, a lot has already been written on WCF. I look forward to hearing more about future directions.

Windows Workflow Framework and Windows Workflow Services (was Windows Orchestration Engine): while we plan the enhancements in the workflow capabilities of the Digipede Network, integrating with existing systems is always a requirement. A no-brainer for us was/is to build a BizTalk adapter. WWS looks interesting (as it looks to replace the existing BizTalk Orchestration services) – it will allow us to integrate with BizTalk 2006 as well as Office 12. This means that Microsoft has just reduced the number of integration points we need while increasing the flexibility of the entire solution. Very cool.

Windows Server Compute Cluster Edition (CCE) This product is going to make a big splash in the growing 64-bit clustering market. The work that that team is doing to improve the platform for distributed computing is all good. As Dan said in a recent post, this is a critical move. I look forward to Kyril’s talk and to catching up with him on their plans.

And more. I’ll blog on that later . . .

Tags: , , ,

Cabbing to the PDC

I am sitting in the cab on the way to the LA convention center for PDC05. Dan is there now having some issues with network connectivity from our booth (#123). SSH and VPN ports blocked? Can’t be – I’m sure he’ll figure it out.

A few weeks ago, I was at the Santa Cruz Beach Boardwalk with my family. I found out that my 4-year old has a stronger stomach than I do.

And I’ve just realized I cannot blog while in the back of an LA taxi.

Tags:

Removing a hanging assembly reference

I don’t know if many people have run into this problem: a .NET assembly referencing another assembly in its manifest, though the referenced assembly isn’t used at all.

I don’t believe this is possible under normal conditions, but it is possible with an application that post-processes the assembly. Specifically, this can happen when using Dotfuscator 3.0. When obfuscating .NET 1.1 assemblies, it supports custom obfuscation attributes defined in a .NET library that they ship. Depending on the way you configure Dotfuscator, these attributes can be stripped from your obfuscated assembly. This is reasonable as the attributes have already served their purpose. There is a confirmed bug (that I’m sure they’ll fix soon) that leaves a reference in the manifest though all the attributes have been removed.

In most cases this doesn’t effect the use of your assembly. The CLR won’t try to load the referenced assembly (as there are no actual references to any types in that assembly). The one problem that I have found, though, is if your assembly is a library that others (e.g., your customers) will reference in their own projects. The assembly still functions properly, but undesirable warnings will be emitted by the compiler. And of course, this only applies if you are not shipping the unreferenced assembly.

As an interim solution, they (i.e., Preemptive support staff) suggest disassembling to il with ildasm, manually editing the il, and then reassembling with ilasm. Of course, this approach doesn’t work in an automated release environment. Understandably, they leave that as an exercise for the reader.

Here is what we did. Since all of our release builds are done with nant,
we made use of the built-in ildasm and ilasm tasks. Then we added a custom task that removes the reference from the il. The following code shows an example target assuming that the name of the library is ‘MyLibrary.dll’:

<?xml version="1.0" ?>
<project name="Hanging reference Example" default="rebuild" xmlns="http://nant.sf.net/release/0.85-rc3/nant.xsd">
    <target name="assembleobf">
        <!-- fix the Preemptive.ObfuscationAttributes.dll hanging reference bug -->
        <ildasm rebuild="true" output="MyLibrary.dll.il" rawexceptionhandling="true" quoteallnames="true"
            utf8="true" linenumbers="true" input="MyLibrary.dll" />
        <!-- define a task that takes an IL file as an input, removes the Preemptive.ObfuscationAttributes.dll, and
             writes the file out again -->
        <script language="C#">
            <imports>
                <import namespace="System" />
                <import namespace="System.IO" />
                <import namespace="System.Text" />
            </imports>
            <code>
            <![CDATA[
                [TaskName("removeRef")]
                public class RemoveRefTask : Task {
                    private string _obfuscatedLibrary;
                    [TaskAttribute("obfuscatedLibrary", Required=true)]
                    public string SomeProperty {
                        get { return _obfuscatedLibrary; }
                        set { _obfuscatedLibrary = value; }
                    }
                                                       
                    protected override void ExecuteTask() {
                        StreamReader inFile = new StreamReader(_obfuscatedLibrary + ".il");
                        string inContents = inFile.ReadToEnd();
                        inFile.Close();
                   
                        StringBuilder sb = new StringBuilder(inContents.Length);
                        StringReader stringReader = new StringReader(inContents);
                        string line;
                        while ((line = stringReader.ReadLine()) != null) {
                            if (line != @".assembly extern 'PreEmptive.ObfuscationAttributes'") {
                                sb.Append(line + '
');
                            } else {
                                for (int i=0; i < 4; i++) {
                                    stringReader.ReadLine();
                                }
                                sb.Append(stringReader.ReadToEnd());
                            }
                        }
                   
                        StreamWriter outFile = new StreamWriter(_obfuscatedLibrary + ".il");
                        outFile.Write(sb.ToString());
                        outFile.Close();
                    }
                }
            ]]>
            </code>
        </script>
        <removeRef obfuscatedLibrary="MyLibrary.dll" />
        <ilasm rebuild="true" output="MyLibrary.dll" resourcefile="MyLibrary.dll.res" target="dll">
            <sources>
                <include name="MyLibrary.dll.il"></include>
            </sources>
        </ilasm>
    </target>
</project>

They’ll fix it soon, I’m sure — but for now this will work just fine.

Tags: , ,

eWeek writes about the Digipede Framework SDK

Darryl Taft at eWeek posted an article yesterday on one of the things we’ll be showing next week at :

Digipede to Release SDK for Windows Grids

Have I said that I’m looking forward to the PDC?

Tags: , ,

Run Plazes while at PDC05

I have been checking out Plazes. If you haven’t tried it out yet, it is a way to share your location with others where location is defined by the network you are running on.

Kind of cool, but not too useful when sitting at home or in the office. I’m looking forward to trying it out at to see how many people (and geeks like me) come up on the Plazes radar.

Maybe I’ll “see” you there.

Scoble says we’ll be amazed at PDC

Today on channel 9, Robert Scoble asked for guesses about what will be announced at PDC next week (because no one seems to have a clue). Then he blogs that will prove that Microsoft is definitely not “roadkill.”

I certainly didn’t think Microsoft is roadkill — but I’m glad I’ll be there to find out first-hand.

See Ye old “guess what MSFT is gonna show at the PDC
and Steve says Microsoft is roadkill (and a few other things), respectively.

COM APIs for .NET Libraries

Recently I added a COM API to the Digipede Framework API – developing a good, maintainable COM API was critical. The “easy” Microsoft .NET COM interop works pretty well, but it defaults too many things for those of us building public libraries.

If your public library needs to support COM, there are several steps you will want to take to make your COM API easier to maintain and to allow your library to behave (or appear) as COM clients expect.

I am thinking of writing an article (or a series of blog entries) on the steps I took designing our COM API. While some material exists out there on this (most of it pure reference), none of it brings it all together, soup to nuts.

My quick outline for the article:

  1. Introduction
  2. Limitations of COM interfaces
  3. Overriding the class interface
  4. Eventing interfaces
  5. Building your Type Library
  6. Embedding your Type Library
  7. Enabling Registration-Free COM
  8. Building a COM API Reference w/NDoc

Every section will include examples.

I guess my only question is: do I blog it or write an article for one of the many .NET related sites? If I write an article, which site should I submit it to?

Tags: ,

Designing .NET Class Libraries

I was talking to a friend of mine the other day about Microsoft and why I choose to develop software for their OS versus some other platform. I won’t post all of that discussion here, but one point I made to him was that Microsoft provides excellent resources to their developer community.

I don’t think I really need to further make that point here (anyone interested in reading my blog probably buys into this view already); however, it did remind me of a series on API design that I downloaded from MSDN earlier in the year. Designing .NET Class Libraries provides good information for all .NET developers, regardless of whether you are designing public libraries or not.

Designing .NET Class Libraries

It is worth the time investment.

Going to PDC05

My company, Digipede Technologies, will be promoting our new SDK at PDC05 next week. At the same time we will be announcing and giving away free licenses to the Digipede Network Developer Edition.

I am looking forward to the trip. In my past companies, the clientele was often not technical outside of their particular vertical experience. As software developers are one of the primary targets for the Digipede Network, I’m happy that our customers and prospective customers are highly technical. This makes the customer meetings much more interesting for me and productive on many different levels.

Basically: We’ll get to talk to lots of smart people about what we are doing. And that is always fun.

Tags: , ,

What is R Wandering?

This blog will track my thoughts on software, process, tools, and technologies. I will also use it as a place to post approaches and solutions to technical problems I come across. I have a bit of a backlog of these that I plan to write up over the next month (e.g., some nant and ccnet stuff, developing COM interfaces and documentation for .NET, some Preemptive posts . . . ).

I have been developing software since high school and basically full time since I was a Junior at Cal. I finished there 15 years ago and have since helped build a couple of companies as the software technology lead. While my primary responsibility is generally planning, designing, and building software product I have also been responsible for or directly involved in every aspect of the business. I’ve been on company boards, managed human resources, hired and fired, performed technical selling and evangelism, worked through various due-diligence processes, sold a company, and more. Aside from developing software, one of my favorite things to do is to discuss business issues with fellow entrepreneurs.

My company, Digipede Technologies (www.digipede.net), sells the Digipede Network, a Windows-based distributed computing product built upon Microsoft .NET.

I became interested in distributed computing while at Energy Interactive (www.energyinteractive.com). Among other products we had an energy billing solution designed for billing the most complex commercial and industrial customer for energy providers. Billing was a long running process and we needed to come up with a way to shorten the total run time for a billing cycle. When scaling up was no longer an option, we did the next logical thing: we scaled out. To do this, we ended up rolling our own solution using DCOM, but, we felt that there had to be a better way. That is one of the motivations for the Digipede Network –a packaged solution with the tools to make it easy to grid-enable applications.

In terms of development technologies, I’ve spent most of my time working with Microsoft tools and technologies. I first started with Windows 2.0 and have, of course, worked on all of the Microsoft platforms since. I have worked with C++, VB, MFC, COM/DCOM, ATL, everything from ODBC to ADO.NET, Java, MSMQ, SQL Server, C#, ASP.NET, and more. Now, I am fully a .NET and WinFx developer.

In addition to my work I also manage a couple of FreeBSD servers for hosting email and Web sites.

 

 

And none of that explicitly defines R Wandering.

« Previous entries