MySQL Gotchas makes for some interesting reading. I was particularly intrigued to read that an ALTER on an InnoDB table causes the table to be rebuilt.
Certainly, ALTER statements are going to affect database performance, but this is definitely a Gotcha! operation. [via random($foo)]
Oracle 10g Early Adopters Release 2 (10.1.0.3) was released for MacOS X on Thursday. 10g is supposed to be the first production release certified for MacOS, and Apple and Oracle have been doing a grand tour to promote it. All the PR talks about 10.3 (Panther) Server but it will likely run under normal Panther installations (it's really required to have the DB available locally if you're trying to create or debug code when removed the net; on a plane, in a train or carpool PowerBooks rule) as it does today. We're using in some fashion or another every database I have installed (Oracle, MySQL, BDB, SQLite) except PostgreSQL (and I'm reasonably sure someone is using that somewhere). It's one of the drawbacks to growth by acquisition and merger; lots and lots of variety but it's also a positive so I can't complain too much. Today, we're running the 9i developer release on all kinds of hardware including a bunch of PowerBooks.
I don't remember where I saw this but Berkeley DB Java Edition is now available. Frankly, I don't get it. The press release indicates that they created a whole new BDB version in Java while the world was waiting on them to get around to creating a decent JDBC driver (that would be news). The Berkeley Java API was a complete waste of time (as some co-workers found out last summer and fall) and the folks at Sleepycat Software don't seem to get it. No one wanted a whole new DB which needs to be shaken down from top to bottom, they wanted a rational and sane Java oriented API to the existing DB. JDBC is where Java developers live.
Finally, the fist SQLite 3.0 alpha was released last week. SQLite seems to be the best choice available today for desktop application developers who need to bundle a high performance DB layer with their application. Everyone I've talked to who has done some serious work with the DB has been impressed with the performance. NetNewsWire is the only commercial application that I'm aware of using today, but I'm sure the list is going to grow quickly.
Are you looking for a better way to read long text files, proposals, documentation, eBooks and the like? Today's MDJ had a note about a free utility called Tofu that I decided to try out. I'm quite happy that I did.
The basic premise of the application is that online documents are hard to read because they're typically displayed in a single wide column and moving through a document vertically causes a loss of context as the text is scrolled vertically. In the authors words:
So why not just take a normal window and make it narrower, scrolling down as you need? Well, there are usually a lot of lines in a text, and all look more or less the same, so if they move past your eyes vertically, they are difficult to keep track of. The text doesn't feel stable, and you get lost easily.
Even though I wasn't totally convinced about the narrow columns versus wide column argument, the horizontal movement ideas seemed sound. Certainly that was one of the reasons I started pushing lots of things to PDF and reading them in Preview... once the window size and position are setup appropriately, paging through a document using left and right arrows is quite convenient.
So off I went to try it out.
It appears that the theory is sound.
The text is laid out like a virtual book, with the column widths set by preference and the number of columns being determined by the window width. Auto window resizing worked pretty well in the limited tests I used (better than many other applications). I had to fiddle with the font and column sizes a bit to get what I was after, but I did eventually find a combination that works on all my monitors pretty well.
You can use any combination of mouse wheel and keyboard control (up/down, left/right, spacebar and probably a lot of others) to move around, although the wheel moves parts of pages which I found a bit disorienting. If things get stuck mid page, left or right will align the 'pages' again.
After a couple hours, my eyes started getting tired (bothered?) as they inevitably do when reading on a bright white background so I looked for a preference to play with the background colors and sure enough, it had one (a big win in my book). I normally use a background color scheme close to manila in Eudora and something a little bit more pinkish in BBEdit. I ended up with something a lot closer to gold in Tofu, but it seemed to work and was a lot more like old paper than 'blind me' white.
The image above is a couple pages from 20,000 Leagues Under the Sea which I'm still working on in fits and starts. I read another seven or so chapters in Tofu after getting bored with work and work related reading.
The most interesting thing I noticed was that I started reading online documents a lot like a book. I'd read the two pages on screen, then hit the space bar twice to move to the next pair of pages. If there was a loss of context during the transition, left arrow would get me to the last page and I could transition with old and new on screen at once, reminiscent (but not identical) to flipping a page.
I've tried out its handling of RTF files, which work as expected but haven't yet thrown any Word files that way (I don't think it will care too much for all the tables we use in some of our reference documents).
Even if it weren't free, I'd pay a small fee for Tofu. Since it is free, by all means go get it now.
And thank you Amar Sagoo for such a useful utility.
No, I'm just not a web guy.
I've been tinkering with gmail for the last few days and I just can't edit anything but the most simple message there. It's a wonderfully full featured web application but I feel lost in some ways.
I have a hard problem with wiki's too. I don't want to edit in a scaled down version of HTML. I certainly don't want to edit inside a text area in a browser.
What I want is a full featured client that allows me jump back and forth between the markup applications I like, build something that looks appropriate, paste it in and have the server side twiddle as appropriate. When it comes right down to it, I like rich clients and in some ways I'm having issues with the whole semantic web concept.
I like the idea from a data transformation perspective. Honestly, I put too much markup in the cruft I post here, much less in the data that goes into real documents. Presentation layer separation is essential for future doc portability.
That said, we're at the rudimentary stone age of tool development for real people, and perhaps for those like me who are tired of this silliness. I was there in the days when you had to examine control characters (in hex) in documents. And when things moved to a more sane, but really clumsy first pass markup mechanism (I wasn't there for Electric Pencil, but shortly thereafter). We finally arrived near WYSIWYG (whizziwig) in the mid eighties. I always called it 'What you see is nearly what you get' but it was darned close for a lot of documentation purposes.
It seems today (nearly twenty years after the whole concept of type, format and print became a commercial reality), that if you really wanted to be able to generate a large quantity of format agnostic text, you need to use something really crazy like DocBook. I feel like a criminal, but I'm not going back there damn it.
I'm quite willing (still) to segregate my writing and my markup. But my patience with doing markup inline is growing thin. Why can't I have an editor that deals well with rich text concepts and exports well to all the other important formats (PDF, HTML, Wiki, DocBook, RTF, who knows what might come). It should be simple, but it isn't, not by any stretch of the imagination.
The National Commission on Terrorist Attacks Upon the United States (aka the 9-11 Commission) web site (and the documents therein) makes for some fascinating reading. Perhaps not the best way to relax on a weekend but I believe that it's as close to an unvarnished version of the truth as we're ever going to get.
I didn't really want to pay attention to the various news reports from this past week (and I was far too busy to make that possible) until I'd had a chance to look myself at the data presented. I'd known the commission was gathering evidence, generating reports, and holding hearings but had not in any real way been paying close attention.
The staff reports are well worth reading (really!) as are some of the individual bits of testimony. The transcripts are where everything gets tied together, but I caution the reader that they're long and contain duplicates of the staff statements read into the record. That's not an admonition to read selectively, just a warning. The complete online record is also two meetings behind (the last one with full documentation was on April 13 — Hearing Ten) which is frustrating. It's also missing all charts, photos, diagrams; they may be present in the media streams but they're not easily available elsewhere.
When I explained to Sarah what I'd been doing today and how wonderful I thought it was, she gave me the usual "I love you but you are not quite sane" look, rolled her eyes and smiled; such is life after many years of marriage.
The final report, when it comes out, is going to be a very interesting read. Unlike other massively read and researched investigative reports, this will be the first to emerge in a massively networked world. My hope is that it will be complete and contain all the relevant materials (or link to them in a way that won't break over a long period of time).
I went out for Sushi with Stephen tonight and he now has a new favorite dish, White Fatty Tuna.
Oh my! Not only does it have a wonderful texture, ranging from a true Hamachi (Yellow Tail) softness (maybe even more soft — I'll have to do this again) to a more chewy fatty layer, but there is also a wonderful sweet flavor.
It's not something you're likely to stumble into every day but if you do, you need to try it.
Just got back from a short drive with our eldest in which the conversation turned to manual transmissions.
Once again, a youthful exuberance for manual versus automatic raises its head.
he: If you're back far enough at this light, you can just let the car handle it.
me: Huh?
he: Well, you don't need brakes or gas, it just sits there.
me: You could get the same affect on any hill using a manual transmission; just give it a little gas.
he: I want a manual transmission so bad...
me: And I wish I could make sure you had a manual (transmission) next year in San Francisco just so that you'd finally understand the good and bad (the insurance would kill us and having a car in the city is almost beyond pointless), but that's not happening.
I loved (and still do) having a manual transmission.
At the same time, when I had a car which was performing badly (something most young people have to deal with — it runs, sorta), the last place I wanted to find myself back then was on a hill, at a light with someone driving an expensive vehicle (usually an automatic) less than twelve inches behind me. The bigger the hill the bigger the intimidation factor.
In part because of the recent organizational turmoil here, I started poking around in my server logs again (in ways I haven't done in quite some time). What have I learned? Nothing particularly thrilling, but I did get to the bottom of a couple questions that had been bugging me.
Starting on Memorial Day I began seeing a lot of daily referrals linking straight back to Yahoo! which seemed odd. I figured my hack of a parsing job was screwed up and moved on. Since they're still happening and I was digging around I decided to figure it out. How are all these referrals happening? Simple, they're not. I seem be getting hit by a bunch of sites that act as redirect agents for some porn site in the Netherlands which for some odd reason is using Yahoo! as the referrer. Weird stuff... I don't see the point of it all (unless it is to cause confusion and eventually make us go look, done that, now go away please).
There is also someone (until now known as unknown.level3.net) who is pulling my RSS 1.0 feed every 15 to 35 minutes (it's somewhat erratic but seems to be on a slightly less than 20 minute schedule). It's coming from a user agent of "Mozilla/5.0 [en] (Windows NT 5.0, U)", so I figured that it's someone running a custom plug in of some sort and just wanted to know where. Since I usually have host name lookups on (I'm not getting enough traffic to care about distributing name lookup load elsewhere — as a friend would put it, 'get over with it!') I decided to create a new log temporarily (if possible) and check the IP addresses directly. Apache mod_log_config had what I needed, a formatting argument to access the IP address without turning off HostnameLookups. I created a new format (see below) and added a temporary log file via CustomLog with the ipandhost format in httpd.conf and restarted (sudo apachectl graceful).
LogFormat "%a %h" ipandhost
A few minutes later I had an answer, removed the temporary log entry and restarted again. Seems that someone up in the bay area (close to San Francisco from the traceroute) is my unknown visitor. It might be fun at some point to see if I can do IP based redirection and send a custom feed that helps to spark conversation.
When I added a top level rule to redirect the archived individual entries, I screwed up all the other redirects because I used a blanket redirect. Dang it all.
So now, instead of...
# notice that this redirects everything via the lookup mechanism
RewriteRule ^/blog/archives/(.*)$ ${old-post-mapping:$1} [R=301,L]
I have this.
# just redirect archives/xxxxxx.html stuff
RewriteRule ^/blog/archives/([0-9]+)\.html$ ${old-post-mapping:$1\.html} [R=301,L]
And everybody should be happy now (including all the very confused search engines). My apologies.
You know how it goes. You read something on the web, it leads to something else and eventually you find yourself reading something completely unrelated.
It all started innocently enough. I was reading through the articles on Wireless Unleashed, a cooperative effort between a group of technology and policy pundits on various spectrum related issues. There were some comments by Harold of the Media Access Project that I wanted to follow up on, including a set of articles called 'Tales of the Sausage Factory' on Wetmachine related to FCC actions.
Just meandering, as usual.
So it was that I found myself reading Wedding announcement musings an interesting personal tour of marriage, gay marriage and faith (with a dig at the media tossed in for completeness). The idea of one soul is an interesting view of marriage, one well worth exploring (and far more useful in practice than one man, one woman until divorce do us part). For many reasons it resonates with me and seemed worthwhile to pass along.
The great spring cleanup escapade is about wrapped up now.
The one sticking point had been dealing with legacy entries in the archives directory. I didn't really want a several hundred line .htaccess file. A recent discussion on Ben Hammersley's site: Calling the Apache htaccess masters provided the missing clue.
Using RewriteMap and a small template, I was able to force the mapping for the legacy posts to the new location. The MT template (used to generate a file called archive-link.map) looks like this:
<MTArchiveList> <MTEntries><$MTEntryID pad="1"$>.html /blog/<$MTArchiveDate \ format="%Y/%m/%d/"$><$MTEntryTitle dirify="1"$>.html</MTEntries> </MTArchiveList>
The rewrite rules (which I had to put in httpd.conf instead of an .htaccess file for some reason) look like so:
# remapping archive posts to new locations...
RewriteEngine on
RewriteMap old-post-mapping txt:/full/unix/path/to/archive-link.map
RewriteRule ^/blog/archives/(.*)$ ${old-post-mapping:$1} [R=301,L]
While I was at it, I moved the categories, daily and monthly archives to where I meant to place them the first time around (not down in the archives) and added some new redirects to fix that part of the mess.
Hopefully, that covers it and I haven't broken anything in the process (something might have been missed, but I hit a lot of URL's making sure that the redirects all worked). We shall see!
The category organization in MovableType is interesting, which causes a little pain if you wish to manipulate it by hand (as I did).
The mt_category table holds the category ids and descriptions but the main bits for entry category data are in the mt_placement table (there seem to be some leftovers from previous arrangements in the mt_entry table).
| Column | Value | Description |
|---|---|---|
| placement_entry_id | numeric blog post id | which post? |
| placement_blog_id | numeric blog id | which blog? |
| placement_category_id | numeric category id | id of the category |
| placement_is_primary | 0|1 | primary category? |
Category based rendering would just select based on placement_category_id and iterate over those. When building a list of categories for a particular post, you simply select based on placement_entry_id and placement_blog_id.
Most people aren't going to need to go playing around at the DB level to shovel around categories, but I needed to (because it's always easier to go do it the hard way, right?) and I didn't really see this written down anywhere. Now it is.
An interesting Star article discusses how the Reagan Library came to be where it is: Land offer brought library to Simi.
It closes with this:
It was the last library that Congress allowed to top 70,000 square feet, saying that the taxpayers could no longer afford to pay for maintaining and operating such facilities. Reagan's papers were the first to fall under the Presidential Records Act of 1978. The law made all presidential documents public property but allows a president to restrict access to certain categories for up to 12 years after leaving office.
I may be daft but didn't the Bush administration (the current) one decide this law sucked and revoke it (or rescind it, or something) right before the date that when all the papers would have been released?
If you're coming out this way to see Reagan tomorrow, be prepared for a really long wait. I knew there would be long lines and figured the traffic would be pretty crazy, but even then I under estimated things.
Transportation is a bit difficult in certain areas.
It takes about an hour get from Madera on 118 West to Moorpark College, where they are running the shuttles to the library. Thirty minutes of that is spent on the freeway (at least it was this evening). A typical trip from here to the far end of Madera is less than 15 minutes. Today, even taking Tierra Rejada, it took Sarah a bit more than 45 minutes.
According to reports, the wait to get on the shuttle which takes you to the library was about three hours for most of the afternoon and early evening. I didn't hear anything about the wait time once you arrive at the library but you can probably count on a mob scene up there as well and at least an hour (if not more).
A colleague was running some load tests on an application this weekend (application server based, using JBoss if you must know) and after doing about 24 hours of tests, he'd restarted JBoss for some reason.
When catching up with things today I noticed that the application had been restarted yesterday afternoon and wondered why.
In the end, it boiled down to disbelief.
We typically deploy this application on a 280R (2G, 2x UltraSPARC-III 900MHz), making primary database connections to an equivalent system with more memory (8G) running Oracle (with a fiber connection to a RAID device). For development testing, we normally use an older 220R (2G, 2x UltraSPARC-II 450MHz, it was available a couple years back when we did early application testing) connected to a database which is pretty close to what we use in production. Load testing is normally done running the applications on external systems.
This round of testing is all being done on an Xserve (1G, 2x G4 1.33 Hz); the application under test, an oracle database instance, one additional application in the container, a mysql database instance (storage and queue management for JMS) and the testing client applications along with whatever adhoc tests and scripts are being run. When the results came in, they seemed unlikely (quite a bit higher than expected), resulting in a restart of the application container to make sure things were working as correctly.
When reality confounds expectations, confusion ensues.
We're in the midst of doing some spring cleaning around the house and it seemed like a good idea to get my act together here as well...
First I fixed up all the feeds so they validate. I was serving up RDF as text/plain and that wasn't good. In addition, every single feed was missing the xmlns:content="http://purl.org/rss/1.0/modules/content/" namespace declaration.
Then I dove into getting the monthly and category archives worked out. I still don't have a master category index, but the rest is taken care of. Since no one seemed to be hitting the old ones, I didn't worry about doing redirection there. I did make one change to MT's Util.pm (bin/lib/MT/Util.pm) to change dirify to use dashes instead of underscores when substituting for spaces.
When changing over the monthly pages, I investigated using Mark Pilgrim's monthly calendar template (and still want to do that) but held off for now because I need to do a lot of customization. I also need to figure out how all the macros work and interact. For now, it's still a complete archive of the month and because some search engines had been hitting the monthly pages, I had to delve into redirects. I always get a little lost doing redirects (I think the recursive nature throws me), so these links helped a bit Apache 1.3 URL Rewriting Guide, HTTP/1.1 Status Code Definitions and Apache module mod_rewrite.
# redirect the old monthly archives RewriteRule ^blog/archives/([0-9]+)_([0-9]+)\.html$ blog/archives/$1/$2/ [R=301,L]
While I was at it, I figured I'd set up daily archives. Whoops. Turns out that I was already creating them (I don't recall doing that). I couldn't conclusively decide whether any engines were linking there (they aren't directly linked anywhere, so it's doubtful) but a similar rule takes care of things:
# redirect the old daily archives RewriteRule ^blog/archives/([0-9]+)_([0-9]+)_([0-9]+)\.html$ blog/archives/$1/$2/$3/ [R=301,L]
It's a decent first pass but there is still work to be done. Now I need to turn my attention to the disaster in my physical office.
Figure out how I want the individual entries setup and then determine how to redirect them all in an .htaccess file. I've seen some strategies for this before, just need to go find them. It might be easier to handle it via a special external mechanism (GCI based) just for these files rather than an enormous list. Something to think about.
I also need to finish the category stuff and figure out how I really want to use that area. If I pull in the 200+ entries from Ztuff v1, the current category pages will be even worse than they are now.
With the passing of President Reagan today, I figured I'd put up one of the pictures I took up at the Presidential Library on December 30th of last year. I was out taking pictures of the Simi hillsides (so I can use them next year as a comparison) and ended up at the library where I took a bunch of photos of various things.
The one on the right (click for the full sized image) was taken sitting on a new lawn facing toward the northwest (those are the mountains out near Ojai). The picture doesn't do the view justice, c'est la vie. It was a somewhat cloudy day; on a clear, sunny day the view is spectacular. I didn't take many pictures on the other side of the library where Reagan will be laid to rest because I was chased out... I was in an area that was new and still closed off (I'd ended up coming up the hillside and avoiding all the yellow taped off areas).
I don't usually go to the movies but it happens from time to time as it did last night. Sarah announced that she was going out to see the new Harry Potter flick with the boys. I wasn't interested (I still haven't watched Potter #2) and neither was Adam. A few minutes after they left I went to my office, poked around online and asked Adam if he wanted to go see The Day After Tomorrow. He did. We went.
I'm glad that I hadn't seen anything beyond the previews on television. As it was I thought New York City was covered in sand after some sort of cataclysmic event. A lot of people aren't going to like the rather overt politics in a movie that wasn't too smart to begin with. But what the heck, it's just a movie. Ultimately it's a special effects flick about weather gone mad with a bunch pointless of people tossed in to try to make a story. Unlike Independence Day, the story didn't do anything to make me care about it (ID4's strength for me was that it was so over the top, it made fun of itself and allowed you to laugh at it and with it at the same time).
The whole reason to go see a film like this is the special effects. There are three main groups and they are rather dazzling.
There are lots of great earth from space shots. If you're the type who downloads 80 meg TIFFs of space images and spends time looking at them for detail, you'll be able to appreciate that part of the film. I did anyway.
Then there's the section which can be summed up as super Twister meets Los Angeles. That means about five minutes of let's rip LA to shreds with something different, in this case, some seriously large tornados that attack the city more or less all at once. They hit most of the usual suspects, the sign, downtown, the beaches (they did seem to miss having fun doing a piano effect on the Santa Monica Pier though). There was one shot I'm not familiar with. Early in the LA sequence they show a helicopter flying south, with downtown to the left over what might have been Sepulveda Pass (there is clearly a freeway below which could be the 405) but the perspective didn't quite look right. If this wasn't shot (or CGI'd) there, perhaps it was over the Hollywood Pass (there is a subsequent shot of the sign being eaten). If you know the answer, please do tell.
And finally, the real point of the film is to turn New York City into a popsicle. You make a popsicle by adding liquid and then freezing, and that's more or less what's done; with lots of running screaming people, flying vehicles and the like. Perhaps as a testament to a changed world, buildings are not destroyed wantonly (like the Chrysler Building in Armageddon and others). We won't really get into the wave part of the popsicle treatment, except to say that I don't think the Hudson Canyon would support that behavior (it's the only really deep water of the continental shelf area, the wave should have grown significantly before it did — but it looked cool) and if it hit The Lady the way it was portrayed then that's the weirdest wave I've ever heard of. I don't know why they couldn't turn Philly into a popsicle too (although I guess not too many people would have recognized the statue of William Penn popping out of a snow bank), but we're talking Hollywood here so we had to massacre LA and NY. Philadelphia gets to be a place to have an unfortunate accident that sets up a 100 mile (or thereabout) trek across a hostile landscape in the face of a storm no one has ever encountered, much less survived out in the open.
Oh, there is one more formula item to add. Since we're destroying NY as we know it, we need a black street guy with a dog. Emmerich was the butt of the joke with a similar guy in Armageddon (the little 'Taco Bell' chihuahua which attacks the Godzilla toys), so he gets even? with his own guy (Glenn Plummer).
Hmmm, just read Ebert's review, which was disappointing. He thinks they walked from Washington, which means he caught less of the movie that he's professionally reviewing than I did. OK, maybe that's not fair (time will tell) but its possible that there was a subtle hint I picked up that was easily missed. Flying over South Jersey into Philadelphia a couple weeks back tickled a lot of memories that hadn't exactly been foremost in my mind for most of the last twenty five years.
Stephen took and passed his driving test, the final step in getting his license on the day we learned that his grandmother had passed away (the timing is what it is, I can only wish that it were better). I really wish that I could somehow peer into his mind twenty years down the road to see how those events correlate (and fix it now if need be).
Anyway, I wonder... can I add State Farm as a dependent on my taxes this year?
Baseline (or baselined) is rapidly becoming a dirty word in my world. Is it everywhere or something strange related to our organization only?
Interesting behavior that I wasn't aware of... automatic updates of MySQL timestamp fields. Also see the 4.1 manual.
Any update that changes data and doesn't set the first timestamp column value explicitly will cause it to be updated. The logic is reasonable, but I missed it somehow.