Ĝi Estas La Akvo
Wednesday, March 28th, 2007I don’t know what it is lately, but I cannot stay awake to save my life the last two weeks. At first, I thought it was the new daylight savings time, but now I’m not so sure. Maybe there’s something in the water. It’s frustrating to have time off and constantly need to sleep. I can’t get anything done!
I went to the Apple Store tonight, because on Monday my iPod stopped working. It wouldn’t power on and when hooking it to the computer it wouldn’t do anything. I took it in figuring that there were serious problems.
I handed it to the girl in the store and she had it running without me even seeing her do anything. She apparently triggered a soft reboot by holding down the center and “Menu” buttons. I did this several times, because I knew about that functionality. Somehow she got it to work. She suggested it that it was a woman’s touch. Strangely enough, when the Rockbox screen came up, she didn’t say anything. I figured for sure that she’d ask about that one.
I found a good library to do HTML to PDF conversion at work today. It’s actually about half the price of the software that we were going to purchase, and it’s a library so I can setup different page parameters, which I wouldn’t have been able to do with the other software. I’m pretty excited about that.
When I was talking to the lady on the phone about the product today, she asked me for my phone number and when I gave it to her, she asked if I was in Ames, Iowa, because the prefix is extremely similar to the one that they use at the university. It turns out that she was an Iowa State graduate just a few years before I was! It’s a small world, huh?
Due to all of the goofy requirements for this project, almost all of the processing will be done in .NET, as opposed to the usual SQL Server-based processing. The PDF portion and the decryption software use COM and have .NET bindings, so that’s nice.
Then there’s the XML stuff. SQL Server can handle XML on its own, but I would have had to go through the XML file separately and rip HTML out of it into separate files anyway, so I wrote an application in Java to do that. Unfortunately, the HTML in the files causes issues with Java’s entity expansion limit. All of those <s and >s had to be expanded out before reading the element. This worked fine with small files, but on larger files it first crashed. After upping the entity expansion limit to six-million, it ran, but each record took twenty five minute to get read in. I rewrote the thing in .NET not using a SAX parser, but instead using the provided System.Xml.XmlTextReader class and the whole thing ran in under two seconds! I don’t feel that the XmlTextReader implementation is quite as neat as a SAX parser, but it works.
I’ll still have to do some SQL Server processing, though, as I’ll need to do inventory deductions and batching of orders.