XXE and Subversion - My New Best Friends

I’m dabbling with the idea of using DocBook for technical writing projects. Word doesn’t agree with me, and I really want something I can check-in and diff. I finally took the time to visit XMLMind and take XXE for a spin (http://www.xmlmind.com/xmleditor/). I was blow away. From the tutorial, it looks like the standard version will do what I need, but I’ll probably get the professional version, just to show my appreciation. It’s that good. :)

Most everything I do ends up in an open CVS these days. But there are exceptions. Subversion is the new darling of the Apache Group, so I thought I’d take it for a spin too. The Subversion book seems quite good, but I just wanted to get a Subersion up and running on a local machine, so I could start playing with it. Between the book and a quick-start in the FAQ, I was able to get Subversion up and running in the afternoon (so I could check in my XXE-made XML that evening).

Here’s quick step-by-step of what I did from download to first commit.

0. Download and install Subversion - http://subversion.tigris.org/

Accept the defaults. The Windows installer with setup the path and so forth, and be ready to go. The directory conventions follow Unix, but all instructions are for Windows.

1. Create a repository

> mkdir /var
> mkkir /var/svn
> svnadmin create /var/svn/cookbook

2. Setup permissions

edit /var/svn/cookbook/conf/svnserve.conf

[general]
anon-access = write

3. Setup email notifications [TODO]

install perl for windows, install modified scriptenable template

4. Launch svn server

> svnserver -d -r /var/svn

5. Import content

> svn import -m “Initial import” /projects/ORA/svn/readme.txt svn://localhost/cookbook/readme.txt

6. Checkout content

[delete working directory]
> svn checkout svn://localhost/cookbook
Checked out revision 1

7. Commit changes

> svn commit -m “Routine changes” svn://localhost/cookbook/readme.txt
Committed revision 2

Try the Tortoise client to get off the command line.

See also http://www.onlamp.com/pub/a/onlamp/2002/10/31/subversion.htm

NYC Java OpenSource Conference

It’s a small world after all. Vic Cekvenich contacted me earlier in the year about speaking at a conference this spring. It finally came together Saturday April 3 in Manhattan. It was fun to meet some of my favorite code warriors, like Clinton Begin and Matt Raible. Not to mention my Struts partner-in-crime, Steve Reaburn. It was even more fun to learn that Jason Carreira of WebWorks fame lives only a few miles from me. Sounds like an excuse to heft a few Guiness some time. :)

Some of the earlier presentations ran long, and mine was right before lunch, so I had to rush a bit to get everyone out on time. Pity really, since it was bleeding edge stuff. I’m working on an example application for Commons Chain of Responsibility package, using the venerable Struts MailReader. The key idea is that you can reduce the Action to a “state adaptor”. The Action “simply” passes the state of the (web) application to the Command, and the Command (or Chain of Commands) does all the dirty work. In this way, the Command is a pure business object and can be used in any environment. Say, a testing environment or a desktop environment.

Given the abbreviated presentation, I’m not sure everyone got it. But, I’m sure I was at least able to put Commons Chain on everyone’s radar. Aside from the Struts example, I’d also like to do a WebWorks example too, along with a generic Servlet and Portlet example.

The one non open-source presentation was about Macromedia’s new Flex platform. Flex is a flashy front end that you can program via XML, using tools that you already have (like IntelliJ). For now, the cost puts it out of reach of many projects ($12,000 for two cpus). Still, Flex is going to be the technology to watch as the price drops. Someday, I’m sure, all web sites will look like Flex.

One very nice thing is that Flex is a presentation-only platform. If you already using a MVC architecture, say in a Struts application, you can just plug it in where you are using JSP or Velocity templates today.

One area where we all should start working together today is Validation. Validation runs up and down an application, as a system layer. The Commons Validator is a nice start, but there’s still much work to be done.

No Fooling

My Struts Quiz made the java.sun.com home page on April 1st, bouncing the book back into the 500s (or better) again – still in the Java top ten! We’re about to make our fourth printing of SIA, and there’s a Japanese translation in the works. The errata has trailed off, so maybe the 4th time will be the charm =:0)

The Retract Bid story went in easily. Did the Right Thing and set it up to mark the records, as if they were deleted. This made it easy to print a log of the retracted bids under the nominal bids. This also keeps all the detail so we can even undo it. (In case of data-entry error.) If I can get through paging today, that will sum up the necessary changes for the public part of the auction. That leaves improvements for fulfillment and user administration for next week. I’m eager to get through this so I can back to work on the Oklahoma project.

Finally go the laser printer fixed. It’s been pulling multiple pages when it heats up for some tie. Turns out there’s a lawsuit. Deadline for filing is the 8th, and my paperwork is even in the mail!

Fanning the Flames

Still haven’t gotten to write any tests for the auction program =:(. There’s way more business logic in the JSPs than I realized. I started to enter some bidding data to develop the tests and ended up debugging the errorhandling on the JavaServer pages. But it works, and that’s the endgame. As soon as this iteration ships, I’d like to take this whole thing back to drawing board and rebuild it, test by test. The reinstall on the new server cured our missing library woes, and everything went up just fine. Once we straighed out which keystore we were using, and the correct certificate type, the SSL certificate updated just fine too. Only glitch is that port 443 is not responding on the new server. It seems to be a firewall issue, but the sysop hasn’t found the problem yet. I tried SSL over 80 and that worked well enough.

The kids need shoes! We got Jake a new pair last night at the mall. Katie almost found a pair, but the purple ones didn’t come in her size. Stopped at Friendlys: slow service, great food. Tried the open meatloaf sandwich. Hmm, hmm good. Jake entertained his mom with the story of the Donner family, while Katie patiently awaited her sundae. Even managed to get back in time for Wife and Kids!

Buy It Now Buys it

Got the new Buy It Now feature up and running now. Wanted to get some tests running against the bid process in the bargain, but the opporunity never presented itself. By the time I got the feature cut into the (monsterous) JSPs, there was very little business logic left. All I needed to do was put in a short clause to close the lot if a valid BIN bid came by. Not to be foiled, I’m forging on with the Retract Bid story. There must be something in there I justifiably test!

Meanwhile, the sysops ran a fresh install on the new server, with the X-Window libraries this time, so Java could run on native threads. JVM and Resin went in just fine. (Tracing that one down drove me nuts!) Still couldn’t get the MySQL benchmark RPM installed. Seems to be some RPM naming glitch (Mysql vs MySql.) N’suth.