XML Schema Tools

Went looking for XML Schema generation tools today, to further my investigations of Castor‘s source generation (which requires a schema to work). XMLSpy appears to be streets ahead of the competition in so many ways. Its not cheap (in fact its very expensive), so a team would have to be doing a LOT of XML / XSL editing to make it worthwhile, but the time saving of being able to take a sample XML document and generate a DTD or Schema from it is huge.

Does anyone know of any open source projects working in the same area?

CVS Tools

Been doing my technology evangelist / mentor bit at work this week, trying to encourage migration away from sourcesafe onto a half-decent scc system. Not having cross-platform access to our source is hampering us in so many ways. We have no budget, so I’ve been focussing on ways to make CVS as attractive as possible. Shamelessly stealing ideas from sourceforge, I find the following combination of tools work very well together:

CVS (duh) on the server.

TortoiseCVS integrated Windows client.

Pageant for SSH key management and passwordless connection.

ViewCVS for a web browsable view of the repository.

Syncmail for doing automated diffs-by-email on commits.

Does anyone know of a

Does anyone know of a means by which I can get my radio rss feeds emailed to me,
or externally replicated? Radio is installed at home, and I can post to it via
email (like now) but I’m starting to rely on my news aggregation more and more,
and it takes a good hour every evening to go through it.

I’ve gotten so used to using server-side apps. that the restrictions of a thick
client are something of a shock to the system. Roll on the day I can afford a
personal CoLo server (or my own leased line)!

My Life as a

My Life as a Cautionary Tale.

I forgot to swap my hard-drives before installing Redhat.

It’s gone. Everything. Gone. For some reason, a couple weeks ago I bought a 25-pack of CDRWs ready to go… and haven’t used any of them except to back up some pics and Ana’s file (during her original move). All my emails for the past 8 months (since my last backup) gone. Dev work? Pretty much gone. Graphics? Passwords? Documents? Software keys? Any digital photos from the past several weeks? Gone, gone, gone.

I just got Win2k Installed again and my ADSL and am starting the long road back to recovery… it’s going to be a long evening. For those of you reading this right now, do yourself a favor. BACK UP. I’ve been wandering around my apartment during the re-install looking for “phantom” back-up CDs that I’m sure I must have made. How could I be so stupid to go for so long without making a backup? I must have made a backup… it’s got to be here somewhere… maybe I put in with the baby-clothes for safe-keeping? It must be here somewhere…

Excuse me while I keep looking…

-Russ [Russell Beattie Notebook]

Nightmare. We’ve all done something similar, although perhaps not as serious. I once trashed an entire hard disk while attempting to restore a single file. This was in the days of DOS 3.0, when the ‘Recover’ command didn’t. What it actually did was smash all the data into individual files, each file containing exactly one cluster. Nice. Mind you, back then 20 meg was big for a hard disk.

Hands up anyone who actually does have a consistent personal backup strategy (and ‘when I remember to’ doesn’t count).

Most of my stuff is in CVS on my BSD box, but if that ever dies…

Excuse me while I go and check the prices of tape drives.

XRAI. Rickard and James

XRAI. Rickard and James Strachan had very good ideas for the XRAI module. I agree with both of you! I like Rickard’s ClassAttributes and serialization idea. I also agree with James that a JAXP-style approach is needed. So we’ve done our WBD (Weblog-Based Design!) and now I have approval for the module from some of the best brains of this industry! Wow! Weblog rocks!

[Memory Dump]

Indeed. And all the bits for implementing this already exist. I had a quick play with QDox and got it printing out all my javadoc tags. Wrapping them in XML should be fairly straightforward. Building an ant task to generate all the MyObjectAttributes.xml files in the build directory should also be trivial. Then its just a matter of the return journey, which simply involves writing a default implementation of Rickard’s ClassAttributes class that knows to stick ‘Attributes.xml’ on the end of the class name and look for it in the classpath. Load the file, parse the XML, cache the Attributes in a HashMap and you’re done.

Its almost too easy…

XRAI

This one’s a new idea from me. You already know that .Net provides a runtime-based system for accessing attributes (@tags), so you can simply do something like anobj.getClass().getAttribute(“ejb.bean”) for example, whereas in java you read an xml file, and XDoclet is a compile time system which reads attributes. JSR 175 works on a runtime system, but for now what do you think about a simple simulation of a runtime attribute access API? So the idea behind XRAI is a post-proccessor ant task which reads source code and modifies the compiled classes with BCEL and injects some static fields to classes. It injects things like private static final Attribute[] attributes = new Attribute[]{new Attribute(“ejb.bean”, …)} and with a naming convention for method level tags too. You’ll be able to access the tags with an API like this: AClass.getAttribute(“ejb.bean”). Looks very simple and feasible imho. Ideas?

Ara.

[Memory Dump]

Superb. This was something I was thinking of at the weekend, how to implement .net style attributes in Java. I was thinking XDoclet or QDox would be the way to go as far as processing the attributes, but was stuck on how to weave them into the code. I initially considered extending the class with a dynamic proxy (I seem to be seeing them everywhere I look these days), but that would only work for interfaces. BCEL could well do the job, but how would you go about injecting the methods into the API? I’m curious.