Mr. Safe

In the spirit of Jon Udell and Tim Bray, here is my version of a conversation with Mr. Safe.

Mr. Safe: We need to get moving on this extranet project; our partners want better information.
IT Manager: It’s coming along fine; I am going to use RSS for thenewsfeeds.
Mr. Safe: Isour biggest partnerOK with that?
IT Manager: Yeah, I tested withtheir IT managers and they can handle our prototype RSS feed no problem.
Mr. Safe: What does our biggest competitor use?
IT Manager: They use RSS. So does Microsoft and New York Times.
Mr Safe: I feel safe; good work!

~

Deploying RSS is ridiculously low-risk for a company. If some guy in the IT department wants to deploy RSS, all he needs to do is prove that it works for the job at hand and is used by partners and competitors. I don’t think any typical IT Manager is going to perceive or care about the “risks” that Jon and Tim raise.

For starters, if IT Managers could be swayed by allegations of ego mania among the product’s developers, nobody would ever use Linux.

And I doubt that any IT manager would seriously worry that they would get too “locked in” by a “bad design” in RSS. Every decision in IT can be challenged on the grounds that it’s not “future proof” enough, but this one is particularly hard to support in the case of RSS. RSS is not rocket science, and doesn’t require a heavy investment of resources to support, regardless of which version you use. I mean, in the long shot that Mr. Safe’s company ever decides they need to support dc:date instead of or something, he can hire his kids for $20/hour to “fix” the feed.

Thousands of Mr. Safes use CSV files daily to communicate critical information with external parties. For every piece of FUD you can sling about RSS, I have anecdotes about CSV that are ten times worse. RSS is pretty safe.

Missing Future

[Eric Kidd, via Scripting News] But this dream is nearly gone. It’s getting crushed between the awful power of Microsoft, and the onrushing juggernaut of open source. A 30-person company can’t compete with Microsoft. And a 30-person company will have a hard time competing with 300 open source contributors giving software away for free and making their living as in-house developers (though it can be done).

I had to comment on this, particularly the part about “A 30-person company can’t compete with Microsoft“. This statement makes sense at lazy first impression. It’s the sort of myth that keeps people from trying, and gives excuses to those who weren’t really planning to try. But the myth doesn’t stand to scrutiny. It’s ironic to note that Eric’s example ofa person who doesn’t believe the myth is a former ‘softie. Why do you think Joel doesn’t believe the myth? Do you think he has some insight that people outside the company don’t have? What do you think other former employees would say if asked “can a 30-person company compete with Microsoft?” You might be surprised.

I’ve had this explained to me at least twice by successful independent software vendors. First, Microsoft analyzes opportunities very strategically, and will happily kill a project if it doesn’t meet the bar for strategic or financial payoff. We’re not talking about crumbs here, either. There are plenty of extremely lucrative areas where Microsoft could technically compete, but won’t because of self-imposed strategic reasons. IBM had (andstill has)these same sort of self-inflicted blind spots, and ISVs know how to play them.

Second, a smaller company is more nimble. Microsoft does an admirable job of reacting to new things, but there is an inherent difference in the way that large companies react as opposed to smaller companies. Microsoft can rightly brag that we adopted RSS before most ofthe other big behemoths, but it would also be fair to say that it took a few years longer than the small fish hoped or expected. When talking about large organizations, good ideas may be identified at the individual level fairly quickly, but it’s going to take 3 years minimum for a good idea to be identified at the organizational level. That’s just the way it is. If Eric has a great idea, and is afraid that some big behemoth is going to squeeze in, he should just remember RSS.

And finally, Microsoft’s omnipotence is overstated. Even when Microsoft does decide to compete, Microsoft won’t be declaring victory with the release of V1.Victorynormally comes, if at all, after some time-consuming lessons. Intuit is still around, as are plenty of other Microsoft competitors. Do you think they regret having gotten into the business, or feel that they should have done open source? Hardly!

Of course, it all depends on what you mean by “compete”. If you mean “ship a competitor operating system”, then it’s true that a 30-person company can’t do that. But neither can Microsoft or open source — the war over operating systems was finished ten years ago. You get eitherWindows or Unix. That doesn’t prove that Microsoft or open source are any “better” at pleasing customers than a 30-person company; it just proves that operating systems aren’t the “hot” area that they used to be, and consumers are content to get their operating system from a one or two “commodity” vendors. I would also argue that “ship a competitive developer platform” is not much different from operating system. As “platform” components mature, they become less interesting and there is more pressure to standardize. Things like C#/CLI going to ECMA, SOAP to W3C, all point to the fact that the industry has largely acknowledged this trend.

This, in my opinion, is the biggest flaw with the arguments that say there is no opportunity in software today. If selling operating systems and developer platforms was the only way to make money, the critics would be right. But concentrating exclusively on operating systems and developer platforms is rather unimaginative, IMO, and not likely to bring great investment returns for anyone these days. Sure, they are strategic, but not something the typical end-user is begging for right now. There are plenty of other things that people are asking for, and lots of things that could be done to bring value to normal computer users. That’s going to be the case for the forseeable future, and as long as it’s true there is opportunity in software.

Matrix Persona

Really uncanny, these tests are:

You are Cypher-
You are Cypher, from “The Matrix.”
Selfish, disllusioned, you are misguided at
times. You deviate from the “right”
path.

What Matrix Persona Are You?
brought to you by Quizilla

~

There’s been lots of analysis of Matrix and Matrix Reloaded, but I haven’t seen anyone yet mention the issue that to me was the most glaring plot deficiency of Matrix Reloaded. When Neo talks to the Architect, Neo discovers that the same plot has unfolded 6 times before, and if the Architect is to be believed, the system will hit the “reset” button and it will all start over again this time as well.

Now,why didn’t any of the previous Neos or Zionists ever write down the details on stone tablets and leave them for the next generations to find? It’s hard to believe that this could have happened six times and none of the details were communicated to future humans. Surely something would have made it through? And even if the information never made it through, why didn’t the Zionists invent such a story? The story of a God who hits the reset button is exactly the Biblical story of Babel, and permeates all of the Abraham religions and (I would argue)iseventhe same idea as samsaravs. nirvanahin Buddhism (samsara is caused byfailure to submit to the universal law and manifests itself as continual cycle of life followed bydeath/rebirth, which is essentially thea “hard reset”).

Since this is such a universal concept, and IMO just a basic part of being human, there is no excuse that Neo was surprised by the Architect’s claim. There is no excuse that Neo didn’t expect it based on evidence, or failing evidence expect it based on faith.

SemWeb Play

RDF is my preferred way of tracking my web usage, browsing habits, etc. About a year ago, I wrote an RDF database with a browser plugin and have been tracking my browsing this way ever since. This weekend, I finally decided to rewrite the database part from scratch, and gave it a better API. I am fairly happy with the result. Now I can do code like the following examples:

// traversing the graph
Context c = Context.Open();
Resource r = c.Resource(resourceUri);
Property p = r.Property(propertyUri);
Property[] pa = r.Properties();
p.Value = “foo”; // assign resource, string, or xml literals
c[resourceUri][predicateUri].Value = obj; // indexer support

// querying the graph
Resource[] ra = c.Resources(predicateUri, value); // including fulltext search

// support for built-in RDF stuff
if (p.Value is RdfCollection)
(RdfCollection)(p.Value).Append(“foo”);
r.RdfType = rdfsSchemaUri;

I also whipped up a treeview RDFDB browser in winforms to prove that the API is easy to use, and wrote code to import all of my bookmarks. (Less than ten of the lines in the code snippet below are concerned with talking to the RDFDB; the rest are just parsing out the bookmark, downloading, etc.):

static void Main(string[] args)
{
string baseDir = “c:documents and settingsjoshuaafavorites”;
string connectionString = “Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=favorites;Data Source=(local)”;
Guid contextId = new Guid(“0c1d3732-bdf9-42e0-bdd3-d72a265202a4”);

Context c = Context.Open(connectionString, contextId);
if (c == null) c = Context.Create(connectionString, contextId);

foreach (string file in Directory.GetFiles(baseDir, “*.url”))
{
DateTime createDate = File.GetCreationTime(file);

StreamReader sin = File.OpenText(file);
string line = sin.ReadLine();
string section = “”;
string url = “”;
while (line != null)
{
line = line.Trim();
if (line.StartsWith(“[“) && line.EndsWith(“]”)) section = line;
else if (section == “[InternetShortcut]”)
{
if (line.StartsWith(“URL=”))
{
url = line.Substring(4,line.Length – 4);
}
}
line = sin.ReadLine();
}
if (url != “”)
{
string dcTitle = “
http://purl.org/dc/elements/1.1/title“;
string dcCreator = “
http://purl.org/dc/elements/1.1/creator“;

Resource r = c[url];

r.RdfType = “http://purl.org/webstuff/bookmark“;

string title = file.Substring(0, file.Length – 4);
int spos = title.LastIndexOf(“”);
if (spos < title.Length && spos > -1)
{
title = title.Substring(spos + 1, title.Length – (spos + 1));
}
r[dcTitle].Value = title;

string docBody = “”;
XmlDocument doc = null;
try
{
doc = new XmlDocument();
WebRequest req = WebRequest.Create(r.Uri);
StreamReader sr = new StreamReader(req.GetResponse().GetResponseStream());
SgmlReader reader = new SgmlReader();
reader.InputStream = sr;
docBody = sr.ReadToEnd();
doc.LoadXml(docBody);
}
catch (Exception e)
{
//Console.WriteLine(“Unable to load {0}: {1}”, r.Uri.AbsoluteUri, e.Message);
}
if (doc != null)
{
try
{
r[“
http://purl.org/webstuff/bookmark#body”].Value = doc;
}
catch (Exception ie)
{
}
r[“
http://purl.org.webstuff/bookmark#text”].Value = doc.InnerText;
ArrayList links = new ArrayList();
XmlNodeList nodes = doc.SelectNodes(“
//a/@href“);
foreach (XmlNode node in nodes)
{
Uri u = new Uri(r.Uri, node.InnerText);
links.Add(u);
}
r[“
http://purl.org.webstuff/bookmark#links”].Value = r.Context.CreateCollection(links);
}
else
{
if (docBody != “”)
r[“
http://purl.org.webstuff/bookmark#text”].Value = docBody;
}
}
}

}

MSFT Are

Bunches of new bloggers from MSFT. I need to update my list, and thanks to one of the new bloggers, I’m changing the title of the “MSFT is” blogroll. I was just checking out David Chalmers’ inaugural post. (David, along with Morris Sim and Gavin King, completes a trifecta of MSFT academic bloggers from the UK) . In his post, David points to a video his team made; the opening words of the video are “Microsoft are on the road again”.

That used to be proper grammar in the U.S., too. However, nobody says that today, and most Americans upon hearing it would think the speaker made a mistake. In fact, most grammar books in the U.S. have been revised to allow or even require the incorrect grammar form now. “MSFT are” is the only really defensible subject-verb agreement, and the colloquial “MSFT is” can be blamed for some reduction in critical thinking capacity, IMO. The colloquial grammar makes it all too easy for politicians and journalists to anthropomorphize organizations which are in reality very complex.

Hair Bear Bunch

One of our devs was explaining something today about how our XML parser works when reading the very beginning of an XML text file. The xml declaration is always something like ““, and the XML 1.0 spec requires conforming documents to begin with the “

Not that we would have used the built-in decoder to process the declaration anyway, but I thought this was fascinating bit of info. It’s also something you will very likely never find useful, but I decided to post it because it is so typical of the issues we deal with on a daily basis in my team. Being part of a team that does core XML APIs has some relatively unique challenges:

  • You are working from externally-developed specs, and these specs can be amazingly ambiguous at the most inconvenient places. Trying to figure out what the spec “really means” can get to be downright metaphysical. To be fair, the ambiguities are as often from issues that we never thought about (because they weren’t relevant when the spec was written, they arise from strange interactions between multiple specs, etc.) when writing the specs as from poor writing.
  • The whole point of XML is to provide interoperability, so you have very little flexibility to change the spec to make your life easier. No matter how insane the spec is, the path of least resistance is often just to do it the insane way.
  • XML is about data, so it is much harder to change behavior if you already shipped a version. A breaking change for the typical stateless API is not as big a deal, since code is only alive when it is running and recompiling is easy. On the other hand, that XML file your APIcreated for the user could be sitting around on disk for ten years, and when she tries to open it ten years from now, it had better be readable. Basically, you will always get handcuffed by backwards-compatibility issues if you are dealing directly with persistence formats. Of course, that’s kind of the point of interop, so it’s not such a bad thing. But it gets really interesting when you have alreadyshipped a minor conformance bug and fixing it would technically be a breaking change to existing users. Everyone knows what the right answer is, but the problem is that half of them know thatit is “fix it” and half of them know it is “don’t fix it”, and they all scream really loud.
  • Since XML is about interop, it is smart to minimize the number of XML processors that your company uses. Having every team write their own, or having internal teams use different parsers than external customers, greatly increases the risk that these parsers will not be “bug compatible” and will lead to the embarassing situation of you not interoperating with your own stuff. Of course, you should run your tests using as many parsers as possible,but it is common sense that everyone uses the same APIs in production. However, that puts the APIs in the position of having to serve a bunch of different masters both internal and external to the company. Some masters want raw throughput, some masters want usability, some masters want low working set, and so on. No master is the most important, since the point is to serve as many masters as possible. This leads to some very interesting discussions when prioritizing work. Any API team willhave this particular “many masters”issue to some degree, but the whole interop angle makes it more pressing, IMO.

~

It was before I was born, but what a nice song. “Hair Bear” seems to have been a play on the name “Hanna Barbera”. The name reminds me of two silly poems:

My beard grows to my toes
I never wears no clothes
I wraps my hair around my bare
And down the road I goes
– Shel Silverstein

Fuzzy Wuzzy was a bear
Fuzzy Wuzzy had no hair
Fuzzy Wuzzy wasn’t very fuzzy, was he?
– Unknown

Hope Springs

This warms my heart:

“I’ve been the subject of not one, but two, fawning puff pieces published in[NYT]in the course of my young life. So I should join the suck-up parade too, right? Wrong. There are more important matters at stake – the future of Authentic Journalism and democracy in an era of Simulated News…”

Could American journalism be approaching a reformation? As the layers of the onion begin to peel off, we see just how widespread and systemic the disease is. But who has the will to fix things? I don’t think it’s going to be a revolution, but instead a replay of Luther’s 95 theses. I’m guessing three things (it will be fun to check in two years and see if I was right):

  • The general public will get bored with the issue; they’ll still buy their local newspaper
  • The mainstream newsrooms will continue to be run by cynical people who see this all as a PR issue that they simply need to “wait out” and then deal with in a PR fashion
  • Many conscience-motivated journalists will get disgusted by the lack of reform and will break away from mainstream

Therefore, this issue will play out over a number of years as the “protestant” journalists gradually expose all of the dark areas of the orthodoxy to the glaring lights of publicity. Further scandals and exposures probably won’t have much influence on the general public, since people have short attention spans and the mainstream newsrooms can easily steer their opinions. Butthis willimpact j-school graduates. Mainstream newsrooms will not change except in the most superficial ways. But the “other side” now has a critical mass of journalists who are not playing along with the lies. These journos can attract others who are driven by conscience and a sense of “doing the right thing”, which is very attractive to idealistic j-school grads. Thus the schism will grow.

XML Editors

I have been getting a ton of use recently from a new piece of code that one of our architects,Chris Lovett, wrote. If you are into System.Xml, you may have seen the XmlNodeWriter, SgmlReader, or XmlCsvReader that he built. I hope that his latest tool will make it onto gotdotnet soon as well.

I’m also using InfoPath a lot. I was tempted to jump in with comments a month or two ago when everyone was raving about InfoPath, but I thought I would hold out and get some more miles before making public judgment. I was on the team a long time ago (two name-changes ago), and went through my initial infatuation with the product at that time. So I figured I should use it day-to-day in the same version that will be shipping to customers (it has changed a lot) so I could give a realistic report. My relationship with InfoPath has matured, and I am happy to say that it looks like it is going to last. I am finding that I use it to keep track of all sorts of things; it makes it a breeze to whip up a form for keeping track of partly-structured information. For example, each item on my to-do list can have a timestamped list of notes in XHTML. And I actually use it. Here are the main tips I can think of right now:

  • If you don’t want to come up with an XSD schema first (I never do), just drag-drop controls on the form, and hover over the control to change the name of the element or attribute that InfoPath picks for you.
  • Alternately, you can use notepad to whip up a sample XML file with your general shape,then let InfoPath infer an XSD and form layout from that sample XML. I’ve used this a few times; it grows on you. It’s like “schema design by example”. That feature alone makes it a product worth having.
  • You can use the “infer from sample” technique just described if you want infopath to create a schema that doesn’t use namespaces.
  • .xsn file is just a .cab file. Rename it to .cab and double-click. Now you have some power.
  • The InfoPath form designer generates portable XSLT that you can use anywhere. I tried it, it works.
  • Form designer doesn’t let you draw a recursively-nested form. But you can edit the XSLT manually to recursively apply templates, and InfoPath honors the recursion when editing XML using that form.
  • If you use InfoPath form designer to create/edit your XSD, it changes the namespace URI whenever you add or change fields in the data source. Each instance of your XML document will be bound to the namespace that was used when the instance was first saved. If you want an XML instanceto use the new, updated form, you can change the namespace URI used in the document. Of course, you should only do that if you know that the existing doc is still valid to the new schema. Another option is to hard-code the namespace URI in the solution, by using an external XSD schema; but then you are on your own for versioning.

~

I like words. I need to make a list of “cool words” that I can use to keep track of words that make me happy. I’ve noticed that the quality of language in general use in literature and rhetorichas deteriorated dramatically over the past decades. I would suppose that it’s gotten steadily worse for the past hundred years or so, but the declineis detectable even since I left high school. As an example, today I heard a news anchor for one of the major networks refer to Martha Stewart’s indictment as “the mother of all perp-walks”. I’ll admit that “perp-walk” is effective at communicating a whole range of desired connotations, but where is the dignity? And how hackneyed is “mother of all”? I really don’t think the newsperson was effectively communicating. She was trying to convey the sense that “cameramen and news crews are eagerly waiting to catch the moment on film”, and perhaps that“this indictment is prompting a bigger media feeding frenzy than Gotti”. There is a slight chance that she used “mother of all” in a cutesy matronly sense, but in my opinion such punny and double-entendreuse of words by newspeople is even less excusable (albeit common)than would be the use of a hackneyed phrase. That sort of thing wasfunny in sixth grade, not in my newspaper.

Getting Personal

This is too bad. Lots of people seem to harbor deepresentment toward Dave Winer. Now,ifyou think Dave is a jerk (and I don’t care so please don’t comment), Ihave some advice:

  • Resentment isn’t productive.Itpollutes the consciousness and saps attention from your goals.Ifyou really don’t like someone, why give them that power over you? Of course, you’ll sometimesmeet people who piss you off, raise your blood pressure, and so on — butthere is a difference between eye-rolling and debilitating resentment.Be honest with yourself, and don’tmake excuses for yourself if you’re indulging in debilitating resentment.
  • Ask yourself if you can passively and objectively acknowledge the contributions Dave has made? Can you admit to any of his good personal qualities? That’s a good measure of how well you have your own emotions under control, and demonstrates personal integrity.
  • Don’t waste your precious hours on the earth trying to personally tarnish someone’s image. Stalking around the chatrooms (or conferences)endlesslytrying to rally others to the “Dave Winer sucks” cause is not productive. Again, there is nothing wrong (and maybe even something healthy)with getting resentment off your chest and saying what you feel when someone upsets you; but if you find yourself lurking around the chat rooms and jumping on at every opportunity, you just might have a problem. And besides the negative effects on your own psyche, there is the simple matter that such behaviordoesn’t work. It’s far more likely to make you look petty than to make him get hurt (or apologize, or fail, or whatever the heck else you are hoping for).

Basically, there is nothing wrong with disliking someone, but you have to think about yourself sometimes. In the flurry of commentary surrounding the OSCON keynote, I’ve certainly seen some examples of “normal” dislike, butI’ve seenmore than enoughexamples of pathological dislike. It’s not good.

~

From Aaron Swartz’s notes, I wonder what this Charlie Nesson guy was thinking. I wasn’t there, but it looks like Nesson jumped in with some advice about “we need an unbiased moderator to facilitate this discussion; that is what a lawyer would do.” And then things veered into an idealistic meta-discussion about how software people couldlearn from lawyers about howto be nice to each other and get along.

With all due respect, Nesson didn’t invent RSS. Dave Winer has done huge work to make the two-way web a reality. Bill Kearney has contributed a thing or two, as well. The place we’re at today was reached without any moderators, and lots of the people never got along very well. Some of the best developers I know have big egos, drink lots of coffee, and have strong opinions. (and some are really nice, too :-))

Anyway, I really doubt that lawyers are all that superior when it comes to issues like this. I suspect that stronglawyers have modestly better interpersonal skills and prefer different stimulants, but otherwise ingest equally large amounts of those stimulants and are jerks with big egos. And this isn’t peculiar to software IMO. I’m reminded of an Oscar Wilde quote about “unreasonable men”. The whole meta-discussion seemed a bit silly. But like I said, I wasn’t there.

Memories, Memories

AP says “Big Brother Wants to Watch You Digitally“. Basically, what they are describing is a fully multimedia personal weblog. People today already have blogs that track their GPS position, use emoticons to describe emotions, publicize their interpersonal relationships, and so on.

John Pike of Global Security.org, a defense analysis group, says “they have not identified a military application”. I would add, they could have said the same thing about DarpaNet. The example of darpanet is not accidental. I think I already explained why digital memory (“indelible”) is the inevitable evolution of the Internet.

And I think the article is presenting just one side of the issue. There are two sides:

  • Side A: If everything is recorded, someone might look at what you did when you thought you had privacy. If it’s not recorded, nobody can know. This is the side thatthese newspaper articles focus on exclusively.
  • Side B: If everything is recorded, you can remember it. You can battle amnesia and even death.

Humans grasp and claw to hang onto life as long as possible; and when faced with mortality, they do whatever it takes to pass on their knowledge so that their children don’t have to re-learn the same lessons. Nothing is more human than these two impulses, so the development of things like LifeLog should surprise nobody.